adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml 4.07.0 release notes: https://caml.inria.fr/pub/distrib/ocaml-4.07/notes/Changes | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml | Due to ongoing spam, you must register your nickname to talk on the channel
mfp has quit [Ping timeout: 240 seconds]
kvda has joined #ocaml
theaspiringhacke has left #ocaml [#ocaml]
dmiles has quit [Read error: Connection reset by peer]
silver has quit [Read error: Connection reset by peer]
logicmoo has joined #ocaml
tormen_ has joined #ocaml
tormen has quit [Ping timeout: 252 seconds]
keep_learning has quit [Ping timeout: 246 seconds]
neatonk has quit [Quit: neatonk]
neatonk has joined #ocaml
neatonk has quit [Ping timeout: 252 seconds]
neatonk has joined #ocaml
keep_learning has joined #ocaml
jao has quit [Ping timeout: 252 seconds]
_whitelogger has joined #ocaml
neatonk has quit [Ping timeout: 244 seconds]
neatonk has joined #ocaml
jbrown has quit [Ping timeout: 246 seconds]
pierpa has quit [Quit: Page closed]
al-damiri has quit [Quit: Connection closed for inactivity]
neatonk has quit [Ping timeout: 246 seconds]
pierpal has quit [Quit: Poof]
pierpal has joined #ocaml
erkin has joined #ocaml
neatonk has joined #ocaml
caltelt has quit [Ping timeout: 245 seconds]
kvda has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
kvda has joined #ocaml
bramford has joined #ocaml
<sshine> is there a Base function for (fun x xs -> (x,xs)) ?
thomas_scrace has joined #ocaml
thomas_scrace has quit [Ping timeout: 252 seconds]
<discord> <rgrinberg> Is there really a need for such a function? :)
yaewa has joined #ocaml
moei has quit [Ping timeout: 244 seconds]
<xvilka> Hi! Experimenting with ppx/ast rewriting in utop, written this line:
<xvilka> let qwe = Mod.mk (Pmod_ident ({txt = (Longident.Lident "qwe"); loc = Location.none; }));;
<xvilka> it gives me an error "Error: Reference to undefined global `Location'
<xvilka> but the Location module is loaded in the scope and "#show Location;;" lists the module methods successfully
<xvilka> what can be the cause of it?
bartholin has joined #ocaml
<discord> <rgrinberg> Probably an expunging issue. Try running this in utop-full
pierpal has quit [Ping timeout: 246 seconds]
<xvilka> @rgrinberg: yeah, this seems to work, thx
<xvilka> (it is so nice not to have a documentation for Ast_helper.Mod
<xvilka> or for many other parts of it
yaewa has quit [Quit: Leaving...]
moei has joined #ocaml
kvda has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
orbifx has joined #ocaml
AltGr has joined #ocaml
sagotch has joined #ocaml
<xvilka> uh, even names are inconsistent
<xvilka> Ast_helper and Ast_mapper vs Asttypes
freyr69 has joined #ocaml
TheLemonMan has joined #ocaml
pierpal has joined #ocaml
orbifx has quit [Ping timeout: 252 seconds]
sagotch has quit [Quit: Leaving.]
sagotch has joined #ocaml
Haudegen has joined #ocaml
bartholin has quit [Remote host closed the connection]
m_v_m has joined #ocaml
steenuil has quit [Remote host closed the connection]
m_v_m has quit [Read error: Connection reset by peer]
Bronsa has joined #ocaml
thomas_scrace has joined #ocaml
mfp has joined #ocaml
steenuil has joined #ocaml
dinosaure has joined #ocaml
amcorvi has quit [Ping timeout: 252 seconds]
johnelse is now known as johnel_away
johnel_away is now known as johnelse
jaar has joined #ocaml
<Leonidas> is there a way to specify in opam subpackages that they should depend on the exact same version as the base package?
<Leonidas> otherwise I'll have to make sure to always match the versions
amcorvi has joined #ocaml
bytesighs has joined #ocaml
sagotch has quit [Quit: Leaving.]
logicmoo has quit [Ping timeout: 240 seconds]
dmiles has joined #ocaml
amcorvi has quit [Remote host closed the connection]
amcorvi has joined #ocaml
pierpal has quit [Ping timeout: 250 seconds]
Haudegen has quit [Remote host closed the connection]
thomas_scrace has quit [Ping timeout: 244 seconds]
pierpal has joined #ocaml
ziyourenxiang has joined #ocaml
sagotch has joined #ocaml
thomas_scrace has joined #ocaml
thomas_scrace has quit [Ping timeout: 252 seconds]
Haudegen has joined #ocaml
thomas_scrace has joined #ocaml
silver has joined #ocaml
thomas_scrace has quit [Ping timeout: 252 seconds]
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 252 seconds]
thomas_scrace has joined #ocaml
amcorvi has quit [Ping timeout: 245 seconds]
thomas_scrace has quit [Ping timeout: 240 seconds]
Guest62383 has joined #ocaml
thomas_scrace has joined #ocaml
thomas_scrace has quit [Ping timeout: 272 seconds]
thomas_scrace has joined #ocaml
gareppa has joined #ocaml
gareppa has quit [Max SendQ exceeded]
gareppa has joined #ocaml
sh0t has joined #ocaml
<companion_cube> rgrinberg it's pretty useful sometimes :P
<discord> <rgrinberg> @companion_cube sure, but if it's definition is just (fun x y -> x, y), it doesn't really need a name
<companion_cube> Pair.make
<companion_cube> o/
gareppa has quit [Quit: Leaving]
jbrown has joined #ocaml
Haudegen has quit [Remote host closed the connection]
Guest62383 has quit [Ping timeout: 245 seconds]
amcorvi has joined #ocaml
FreeBirdLjj has joined #ocaml
thomas_scrace has quit [Ping timeout: 252 seconds]
Haudegen has joined #ocaml
thomas_scrace has joined #ocaml
spew has joined #ocaml
wilfredh has joined #ocaml
<wilfredh> hi all
<wilfredh> what's the difference between let and val in ocaml?
<companion_cube> val is used in signatures (typically .mli files)
<wilfredh> google is failing me as val is a common output when using ocaml interactively
<companion_cube> let is used to actually define something
<companion_cube> `val foo : int -> string` just declares that there is a foo of the given type
<companion_cube> let foo x = … actually defines foo
<wilfredh> aha, OK, so val is let without an associated value?
<companion_cube> hmm not really? they're just two different things?
<wilfredh> if I write `let x = 1;;` in an ocaml shell I get `val x : int = 1`
<octachron> `val name:typ` is a description of a value defined inside a module, or in the case of the toplevel, a value defined by a phrase
<wilfredh> so I should read that as 'the signature of x in int, and it has a value of 1'
<companion_cube> because the shell prints the declaration of what you just typed
<ZirconiumX> Welcome to currying
<companion_cube> it doesn't print valid OCaml :s
<wilfredh> yep, just discovered that :)
<ZirconiumX> Should it?
* wilfredh doesn't have an opinion.
Haudegen has quit [Remote host closed the connection]
<wilfredh> groovy, that's really helpful for my toying with modules
<wilfredh> is it possible to define function that takes a generic module (functor?) ?
<wilfredh> this complains 'Unbound module HasLength'
<companion_cube> you should use a functor, not a function
<octachron> or first-class modules; but starting with functor is a good idea
<companion_cube> module IncLen(X: HasLength) = struct let new_my_length x = 1 + X.my_length x end
<companion_cube> octachron: yeah, first-class modules are just going to confuse a beginner
<wilfredh> neat, that works. Thank you :)
sagotch has quit [Quit: Leaving.]
bartholin has joined #ocaml
freyr69 has quit [Remote host closed the connection]
sagotch has joined #ocaml
dinosaure has quit [Ping timeout: 252 seconds]
sagotch has quit [Quit: Leaving.]
Jesin has quit [Quit: Leaving]
thomas_scrace has quit [Ping timeout: 245 seconds]
Jesin has joined #ocaml
FreeBirdLjj has quit [Remote host closed the connection]
thomas_scrace has joined #ocaml
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 240 seconds]
wilfredh has quit [Ping timeout: 264 seconds]
thomas_scrace has quit [Ping timeout: 245 seconds]
al-damiri has joined #ocaml
thomas_scrace has joined #ocaml
AltGr has quit [Remote host closed the connection]
jao has joined #ocaml
Haudegen has joined #ocaml
jaar has quit [Quit: Leaving]
jao has quit [Ping timeout: 272 seconds]
malina has joined #ocaml
<ZirconiumX> Can somebody explain to me how to use the Foo__X -> Foo.X change? For example, if I name a file r5900__decode.ml and then add that to the module search path, will it be imported as R5900.Decode?
<ZirconiumX> I'm thinking about making a subdirectory called r5900, so I'm wondering if the naming has to be specific like that
Bronsa has quit [Ping timeout: 245 seconds]
jao has joined #ocaml
pierpal has quit [Read error: Connection reset by peer]
<octachron> This requires an atlas module (`R5900`) that reexport the submodules with module aliases with `module Decode = R5900__decode`. Dune can do all the plumbing work for you and does not require you to prefix the modules by hand.
pierpal has joined #ocaml
<ZirconiumX> octachron: Good thing I'm using Dune, then
<octachron> then just creating a library with a dune file inside the subfolder should work
malina has quit [Remote host closed the connection]
jack5638 has quit [Ping timeout: 272 seconds]
thomas_scrace has quit [Ping timeout: 244 seconds]
jack5638 has joined #ocaml
Jesin has quit [Quit: Leaving]
jnavila has joined #ocaml
Jesin has joined #ocaml
erkin has quit [Ping timeout: 244 seconds]
malina has joined #ocaml
erkin has joined #ocaml
amcorvi has quit [Ping timeout: 264 seconds]
amcorvi has joined #ocaml
glass has joined #ocaml
theglass has quit [Ping timeout: 252 seconds]
thomas_scrace has joined #ocaml
jnavila has quit [Ping timeout: 240 seconds]
amcorvi has quit [Ping timeout: 240 seconds]
jnavila has joined #ocaml
pierpa has joined #ocaml
steck has joined #ocaml
thomas_scrace has quit [Ping timeout: 240 seconds]
<steck> I have a funny issue with Lwt.async_exception_hook
<steck> I assign to it in the main module of my application, yet the default hook seems to be called on errors
jao has quit [Ping timeout: 240 seconds]
jao has joined #ocaml
gpietro has joined #ocaml
sh0t has quit [Ping timeout: 250 seconds]
TheLemonMan has quit [Quit: "It's now safe to turn off your computer."]
jnavila has quit [Remote host closed the connection]
dinosaure has joined #ocaml
dinosaure has quit [Quit: WeeChat 1.4]
dinosaure has joined #ocaml
spew has quit [Quit: running away home]
silver has quit [Ping timeout: 244 seconds]
silver has joined #ocaml
malina has quit [Remote host closed the connection]
jack5638 has quit [Ping timeout: 240 seconds]
jack5638 has joined #ocaml
pierpal has quit [Ping timeout: 240 seconds]
silver has quit [Read error: Connection reset by peer]
silver has joined #ocaml
dinosaure has quit [Ping timeout: 252 seconds]
caltelt has joined #ocaml
bartholin has quit [Remote host closed the connection]
Haudegen has quit [Remote host closed the connection]
steck has quit [Quit: Page closed]
gpietro has quit [Remote host closed the connection]
silver has quit [Read error: Connection reset by peer]
silver has joined #ocaml
silver has quit [Read error: Connection reset by peer]
silver has joined #ocaml
Jesin has quit [Quit: Leaving]
Jesin has joined #ocaml