companion_cube changed the topic of #ocaml to: Discussion about the OCaml programming language | http://www.ocaml.org | OCaml 5.0 released(!!1!): https://ocaml.org/releases/5.0.0.html | Try OCaml in your browser: https://try.ocamlpro.com | Public channel logs at https://libera.irclog.whitequark.org/ocaml/
tjammer has quit [Ping timeout: 260 seconds]
Bitwiser has quit [Ping timeout: 260 seconds]
chrisz has quit [Ping timeout: 240 seconds]
chrisz has joined #ocaml
Hammdist has joined #ocaml
Bitwiser has joined #ocaml
bgs has joined #ocaml
bartholin has joined #ocaml
mima has joined #ocaml
Serpent7776 has joined #ocaml
dhil has joined #ocaml
Bitwiser has quit [Ping timeout: 248 seconds]
Anarchos has joined #ocaml
bartholin has quit [Quit: Leaving]
mima has quit [Ping timeout: 252 seconds]
Anarchos has quit [Quit: Vision[]: i've been blurred!]
dnh has joined #ocaml
mima has joined #ocaml
mima has quit [Ping timeout: 246 seconds]
azimut has quit [Ping timeout: 246 seconds]
rgrinberg has joined #ocaml
dnh has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Anarchos has joined #ocaml
dhil has quit [Ping timeout: 252 seconds]
dnh has joined #ocaml
<Anarchos> opam update took 88minutes .... :/
<discocaml> <mseri.> It takes less than a minute on my laptop 🤯
<discocaml> <masterbuilder> same
<Anarchos> i have the debug output if someone want to tell me what goes wrong
Bitwiser has joined #ocaml
dhil has joined #ocaml
rgrinberg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<discocaml> <sim642> WSL causes significant slowdown of opam (and maybe compilation in general?) if the files are in some directory which maps to the Windows filesystem. At least that's what I've noticed from students using WSL for OCaml
<Anarchos> sim642 i am on haiku, a unix like system ; not windows.
rgrinberg has joined #ocaml
* Anarchos appreciates that rgrinberg keeps track of haiku in the compiler.
Bitwiser has quit [Ping timeout: 260 seconds]
rgrinberg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
mima has joined #ocaml
<discocaml> <adel> hey guys, can someone simply explain what's going on please?
cedb has quit [Quit: WeeChat 4.0.3]
<Leonidas> is there a good way to look up the signal number from close_process? I get -8 and then it tells me to look it up in `Sys` but there is not `int -> string` or anything to get a human readable signal, just all kinds of definitions
rgrinberg has joined #ocaml
<discocaml> <JM> assuming ocaml is using the standard unix signal numbers, "man signal" would be the best source
<discocaml> <JM> (on my manchine, that gives me: 8 SIGFPE floating point exception)
<discocaml> <JM> actually no
<discocaml> <JM> just check in utop, -8 is Sys.sigpipe
<discocaml> <JM> not sure if there is a better way than probe the various value in utop 😦
<Leonidas> That's what I ended up using
<Leonidas> The manual has them in the same order as the negative numbers decrease, so it was an ok guess
<discocaml> <barconstruction> what do you mean by this? like all files in wsl are normally stored in a special folder\\wsl$\MyDistro\
<discocaml> <barconstruction> or is there another way to have wsl connect to windows directories
<discocaml> <sim642> I don't use Windows so I don't precisely know. But I guess usually WSL terminal opens at `/mnt/c/...` or something, which directly maps to the Windows filesystem. But if you `cd ~` then that's something different, which isn't mounted directly from Windows I guess. At least I think that's what students have done to get opam to create a switch in sane amount of time
bartholin has joined #ocaml
hannes has joined #ocaml
rgrinberg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<discocaml> <Ada> wsl runs in a virtual machine with its own ext4 disk image, and mounts windows disks over something unholy which i think might be based on network shares but don’t quote me on that
<discocaml> <Ada> does the same thing for accessing wsl installs in file explorer, sets up a network drive that exposes the ext4 file system over something horribly slow
<discocaml> <Ada> appears to be a plan 9 network share
haesbaert has joined #ocaml
John_Ivan has quit [Quit: Disrupting the dragon's slumber one time too often shall eventually bestow upon all an empirical and indiscriminate conflagration that will last for all goddamn eternity.]
Hammdist has quit [Ping timeout: 246 seconds]
<discocaml> <Kali> yes, it uses the p9fs protocol
tjammer_ has quit [Quit: ZNC 1.7.2+deb3 - https://znc.in]
Tuplanolla has joined #ocaml
TrillionEuroNote has quit [Ping timeout: 246 seconds]
TrillionEuroNote has joined #ocaml
Anarchos has quit [Quit: Vision[]: i've been blurred!]
mima has quit [Ping timeout: 240 seconds]
rgrinberg has joined #ocaml
waleee has joined #ocaml
dhil has quit [Ping timeout: 252 seconds]
Groumf has joined #ocaml
azimut has joined #ocaml
bgs has quit [Remote host closed the connection]
mima has joined #ocaml
Anarchos has joined #ocaml
<discocaml> <cemerick> it's become really frustrating that alcotest raises and prints exceptions on test failures. The search for a sweet-spot test framework continues.
<discocaml> <jumpnbrownweasel> Is the stack trace the cause of the frustration, or something else?
<companion_cube> do your own, @cemerick :)
<companion_cube> (not kidding, test frameworks are a place where there's basically no downside to it)
<discocaml> <jumpnbrownweasel> Yeah, I have written my own and it isn't difficult. But I'm raising exceptions to indicate test failures. 🙃 That's why I wondered what problems it caused.
<discocaml> <cemerick> yeah, the same stack trace, all the time, for every failure. It's a bizarre choice.
<discocaml> <andreypopp> dune's cram are good, no?
<discocaml> <cemerick> always unrelated to the actual test ofc
<discocaml> <cemerick> companion_cube: oh, I will; I've written one for almost every lang I've worked in, eventually 🙃
<discocaml> <cemerick> cram tests have very narrow applicability IME
<discocaml> <cemerick> the whole test, check, promote workflow has never sat right with me, nevermind that I almost never want to restrict my test data representation to ~plain text
<discocaml> <jumpnbrownweasel> It's true that the stack trace is often missing the frame you care about. I guess just printing the test name is best.
<discocaml> <jumpnbrownweasel> I had printed both, but I can see how it is annoying.
<discocaml> <cemerick> tbc, I'm talking about simple check failures, not when *my* test raises
<discocaml> <cemerick> so the entire stack trace is useless
<discocaml> <jumpnbrownweasel> Understood.
<discocaml> <cemerick> esp since I always ensure my assertions have good messages / expected/actual printers attached
<discocaml> <cemerick> anyway! </griping>
<discocaml> <jumpnbrownweasel> As I was working on it I kept hoping that I would find a way to get reliable stack traces, but I never did. It seems to almost randomly miss some frames, I assume due to inlining since there are usually no tail calls.
<discocaml> <jumpnbrownweasel>
<discocaml> <jumpnbrownweasel> (You don't need the stack trace anyway for an assertion failure, as you say.)
<discocaml> <jumpnbrownweasel> A test assertion, I mean.
Anarchos has quit [Quit: Vision[]: i've been blurred!]
bartholin has quit [Quit: Leaving]
<discocaml> <cemerick> just noticed "Jane Street have requested that Eio not use objects." https://github.com/ocaml-multicore/eio/pull/553 😆
dnh has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<discocaml> <cemerick> it's always good to know explicitly re: the tail that wags
Anarchos has joined #ocaml
Anarchos has quit [Client Quit]
<discocaml> <andreypopp> I didn't get the motivation behind this request though.
<pgiarrusso> TIL that A: isn't reserved for floppies any more!
oisota has quit [Quit: Ping timeout (120 seconds)]
oisota has joined #ocaml
<discocaml> <Et7f3 (@me on reply)> I think it is just the default name like E: for first usb stick if you have two disk
<discocaml> <Et7f3 (@me on reply)> Even C: we can change but at your own risk since it is hardcoded in many place
Bitwiser has joined #ocaml
Serpent7776 has quit [Ping timeout: 245 seconds]
rgrinberg has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<discocaml> <JM> I'll wait to see what the new API feels like, but I won't miss these object type signatures...
<discocaml> <cemerick> That's the amusing part; absent further comment, all we can conclude (slightly ungenerously I suppose) is "JS says so"
<discocaml> <cemerick> One can fret about notation ofc, but row-level polymorphism is great
<discocaml> <deepspacejohn> I vaguely remember other people unhappy about it using objects before, but I admit I haven’t followed it closely. It would have been nice to see the rationale either way though.
Bitwiser has quit [Ping timeout: 252 seconds]
<discocaml> <JM> OCaml structural typing makes exploring new API difficult for me. All the sudden instead of Merlin/LSP telling me that method x expect an argument of type foo, I'm welcomed by a long list of methods the object passed in must implement.
<discocaml> <JM> But I keep an open mind, I'll reimplement the 2/3 programs I have written with eio, and maybe I'll be regretting the object based API
Bitwiser has joined #ocaml
<discocaml> <cemerick> That's fair, the editor tooling isn't tuned for objects as well as for other modalities
Groumf has quit [Ping timeout: 246 seconds]
Groumf has joined #ocaml
<discocaml> <JM> From what I remember the main points were:
<discocaml> <JM> * in current OCaml calling methods on objects is slower than an equivalent functional implementation, and nobody is seriously considering improving that. (it's the kind of micro optimisation that might matter to JS)
<discocaml> <JM> * objects are globally foreign to the usual OCaml dev, most library designers don't use them, most people in the compiler team haven't worked on that part of the compiler, you won't find many resources on how to use them (e.g. even in teaching material, there is an object chapter for completeness, but the focus is elsewhere) so it's weird for a foundational library to switch to objects.
<discocaml> <regularspatula> Are you talking about cram or expect tests?
<discocaml> <regularspatula> I use both frequently, so I was curious about this