adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml 4.09 release notes: https://caml.inria.fr/pub/distrib/ocaml-4.09/notes/Changes | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
Haudegen has quit [Ping timeout: 264 seconds]
amiloradovsky has quit [Ping timeout: 252 seconds]
<sagax> hi all!
<sagax> how to use `match` with expression?
<sagax> don't understand it
<sagax> how to make this better? https://susepaste.org/46120107
ygrek has quit [Ping timeout: 256 seconds]
mfp has quit [Ping timeout: 240 seconds]
<companion_cube> seems pretty alright
clockish has quit [Quit: bye]
clockish has joined #ocaml
themsay has quit [Ping timeout: 265 seconds]
sz0 has quit []
sz0 has joined #ocaml
dborisog has joined #ocaml
spew has quit [Quit: Connection closed for inactivity]
<towel> hi folks, I'm interested in making a fairly basic website with OCaml. Is this something that is commonly done? Something with a registration, authentication, a DB (sqlite), and and API. Are there common webframeworks that you all would recommend?
<towel> Any other good resources for this in the OCaml space would be appreciated as well
<dash> towel: there's various things, i haven't used ocaml on the backend yet but there's ocsigen, opium, webmachine, etc
<dash> i've used reasonml with bucklescript to do frontend stuff
<sonologico> I have used opium for a very simple internal website and it went well
<towel> Thanks dash, sonologico . I'm looking into Opium now -- please continue to send your opinions and recommendations if something hasn't been said :)
<towel> sonologico, how was the performance with Opium?
<dash> towel: when i have these questions i look at https://github.com/ocaml-community/awesome-ocaml
narimiran has joined #ocaml
<sonologico> towel, it was fast enough for my use case, but it was an internal thing for a small group of people
octachron has quit [Quit: ZNC 1.7.5 - https://znc.in]
octachron has joined #ocaml
CcxWrk has quit [Quit: ZNC 1.7.4 - https://znc.in]
CcxWrk has joined #ocaml
tane has joined #ocaml
dump has joined #ocaml
chripell has joined #ocaml
mbuf has joined #ocaml
valtr has quit [Changing host]
valtr has joined #ocaml
ggole has joined #ocaml
Athas has joined #ocaml
<Athas> I'm trying out Multicore OCaml and I want to do some benchmarking. Unfortunately, the Unix module with its 'gettimeofday' is not available, and Sys.time measures total processor time. Any suggestions for what I should do instead?
<Athas> I guess I could FFI to the actual gettimeofday system call, but my OCaml-fu is insufficiently strong.
Haudegen has joined #ocaml
amiloradovsky has joined #ocaml
<mbuf> Athas, please take a look at https://github.com/ocaml-bench/sandmark
jaar has joined #ocaml
vicfred_ has joined #ocaml
vicfred has quit [Ping timeout: 256 seconds]
orbifx has joined #ocaml
themsay has joined #ocaml
<reynir> Is it possible to mute warning 11 (unused match case) for only one match case?
<octachron> No
<theblatte> :(
<theblatte> you can match[@warning "-11"] but that's probably not what you wanted
<reynir> It's for let%if https://github.com/reynir/let-if/
<reynir> It generates a case [| _ -> ()] and I previously muted warning 11, but I decided against that. Now, you get a somewhat confusing warning if you write [let%if x = 42 in ()] :/
mfp has joined #ocaml
themsay has quit [Ping timeout: 240 seconds]
nullcone has quit [Quit: Connection closed for inactivity]
<Athas> mbuf: I couldn't figure out how they perform the timing. I ended up writing my own function in C to wrap gettimeofday(). Unfortunately, Multicore OCaml still looks pretty slow...
nopf has quit [Remote host closed the connection]
narimiran has quit [Ping timeout: 260 seconds]
dhil has joined #ocaml
kleisli_ has joined #ocaml
kleisli has quit [Ping timeout: 256 seconds]
sonologico has quit [Ping timeout: 246 seconds]
<mbuf> Athas, which branch or version are you using?
sonologico has joined #ocaml
narimiran has joined #ocaml
Serpent7776 has quit [Read error: Connection reset by peer]
Serpent7776 has joined #ocaml
<Leonidas> if I have a module type X, how do I specify the signature of a tuple of a module of that type and a value that matches that module?
<Leonidas> type processing_result = ((module PROCESSED) * (module PROCESSED).t)
<Leonidas> that's not valid syntax
<Athas> mbuf: whatever I get with these instructions: https://github.com/ocaml-multicore/multicore-opam
<octachron> Leonidas, type t = For_the_existential_quantification: { vtable: (module PROCESSED with type t = 'a); this:'a} -> t
<Leonidas> octachron: I was partly already assuming this was a bad idea, thanks :-)
<Leonidas> octachron: can you point me at a place to read up more about this?
<octachron> It is not necessarily a bad idea, the field names are more tongue-in-cheek than anything.
<octachron> It just that you can end up with something that is quite close to a hand-crafted object system.
<Leonidas> octachron: I was trying to simplify my code to remove some boilerplate, though adding somewhat advanced type trickery might've been the wrong call :-)
<Leonidas> yeah, you're right, what I am doing is basically trying to emulate ocaml objects using first-class modules
<octachron> Indeed sometimes, as scandalous at it may sound, the object system is useful.
<octachron> I think that there was a thread on discuss on this subject some times (years?) ago.
<Leonidas> it's just that I already have these modules, because they're autogenerated from Protobuf and hoped I can somehow abstract over them a bit better
spew has joined #ocaml
<octachron> If you already have the first-class modules, it may make sense to use them directly.
FreeBirdLjj has joined #ocaml
amiloradovsky has quit [Ping timeout: 256 seconds]
FreeBirdLjj has quit [Ping timeout: 260 seconds]
Haudegen has quit [Quit: Bin weg.]
ygrek has joined #ocaml
amiloradovsky has joined #ocaml
ygrek has quit [Ping timeout: 264 seconds]
Haudegen has joined #ocaml
<mbuf> Athas, if you can add in issue to the Sandmark repo with your benchmark code, it will be useful to check the same
<mbuf> s/in/an/
TheLemonMan has joined #ocaml
cheater has quit [Ping timeout: 252 seconds]
cheater has joined #ocaml
<companion_cube> anyone knows how to bind a C++ constructor with 0 arguments with ctypes stubs?
h11 has quit [Read error: Connection reset by peer]
h11 has joined #ocaml
infinity0 has quit [Ping timeout: 256 seconds]
infinity0 has joined #ocaml
nullcone has joined #ocaml
cheater has quit [Ping timeout: 258 seconds]
<orbifx> companion_cube: wrap it in a C function?
<companion_cube> I'd like to stick to ctypes and not write C, not sure if it's possible :s
<orbifx> got any code samples companion_cube?
<companion_cube> not right now
<companion_cube> but I just want to bind a default constructor, is all 🤷
<companion_cube> maybe `let f () = foreign "Foo" (returning foo)`?
<ggole> I don't think things like constructor names are reliable unless you assume a particular implementation
<companion_cube> it's unmangled
cheater has joined #ocaml
Haudegen has quit [Quit: Bin weg.]
Fardale has quit [*.net *.split]
gargawel has quit [*.net *.split]
Fardale has joined #ocaml
chripell has quit [Ping timeout: 250 seconds]
landonf has quit [Excess Flood]
ygrek has joined #ocaml
landonf has joined #ocaml
dhil has quit [Quit: Leaving]
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
mbuf has quit [Quit: Leaving]
Jesin has quit [Quit: Leaving]
ygrek has quit [Ping timeout: 256 seconds]
ygrek has joined #ocaml
Serpent7776 has quit [Quit: Lost terminal]
Serpent7776 has joined #ocaml
sonologico__ has joined #ocaml
themsay has joined #ocaml
Jesin has joined #ocaml
sonologico has quit [Ping timeout: 246 seconds]
ygrek has quit [Quit: ygrek]
ygrek has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
sonologico__ has joined #ocaml
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
sonologico__ has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
sonologico__ has joined #ocaml
ygrek_ has joined #ocaml
ygrek has quit [Remote host closed the connection]
Haudegen has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
sonologico__ has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
amiloradovsky has quit [Remote host closed the connection]
amiloradovsky has joined #ocaml
nullcone has quit [Quit: Connection closed for inactivity]
dump has quit [Ping timeout: 272 seconds]
Jesin has quit [Quit: Leaving]
dump has joined #ocaml
dump has joined #ocaml
dump has quit [Changing host]
<Serpent7776> I have some issues using assertions package. I compile trivial script with `ocamlfind ocamlc -linkpkg -package assertions unix.cma test.ml` and I get "Error: Required module `Unix' is unavailable". Using Unix package directly works fine. Maybe there's an issue with assertions package? It doesn't list Unix as dependency.
orbifx has quit [Ping timeout: 258 seconds]
sonologico has joined #ocaml
ygrek has joined #ocaml
ygrek_ has quit [Remote host closed the connection]
TheLemonMan has quit [Quit: "It's now safe to turn off your computer."]
sonologico__ has joined #ocaml
sonologico has quit [Ping timeout: 272 seconds]
ygrek_ has joined #ocaml
Jesin has joined #ocaml
ygrek has quit [Ping timeout: 265 seconds]
sonologico has joined #ocaml
Jesin has quit [Quit: Leaving]
dborisog has quit [Ping timeout: 264 seconds]
Jesin has joined #ocaml
sonologico___ has joined #ocaml
ygrek_ has quit [Ping timeout: 256 seconds]
sonologico has quit [Ping timeout: 265 seconds]
dump has quit [Quit: Leaving]
jao has joined #ocaml
ggole has quit [Quit: Leaving]
ygrek_ has joined #ocaml
muskan has joined #ocaml
narimiran has quit [Quit: leaving]
orbifx has joined #ocaml
kleisli has joined #ocaml
kleisli_ has quit [Ping timeout: 264 seconds]
sonologico___ has quit [Remote host closed the connection]
sonologico___ has joined #ocaml
sonologico___ has quit [Remote host closed the connection]
sonologico___ has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
sonologico__ has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
sonologico__ has joined #ocaml
sonologico___ has quit [Ping timeout: 265 seconds]
sonologico__ has quit [Remote host closed the connection]
sonologico__ has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
vicfred_ has quit [Quit: Leaving]
vicfred has joined #ocaml
themsay has quit [Remote host closed the connection]
themsay has joined #ocaml
themsay has quit [Remote host closed the connection]
themsay has joined #ocaml
themsay has quit [Remote host closed the connection]
amiloradovsky has quit [Remote host closed the connection]
orbifx has quit [Ping timeout: 265 seconds]
nullcone has joined #ocaml
sonologico has joined #ocaml
sonologico__ has joined #ocaml
spew has quit [Quit: Connection closed for inactivity]
sonologico has quit [Ping timeout: 272 seconds]
tane has quit [Quit: Leaving]
amiloradovsky has joined #ocaml
sonologico__ has quit [Remote host closed the connection]
sonologico has joined #ocaml
sonologico has quit [Remote host closed the connection]
sonologico has joined #ocaml
sonologico has quit [Remote host closed the connection]
sonologico has joined #ocaml
jaar has quit [Ping timeout: 258 seconds]
sonologico has quit [Remote host closed the connection]
vicfred has quit [Remote host closed the connection]
vicfred has joined #ocaml