adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml MOOC http://1149.fr/ocaml-mooc | OCaml 4.02.3 announced http://ocaml.org/releases/4.02.html | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
seangrove has quit [Remote host closed the connection]
seangrove has joined #ocaml
seangrove has quit [Remote host closed the connection]
Kakadu has quit [Remote host closed the connection]
Vintila has joined #ocaml
silver has quit [Read error: Connection reset by peer]
Maelan has quit [Ping timeout: 240 seconds]
Maelan has joined #ocaml
Simn has quit [Quit: Leaving]
hxegon is now known as hxegon_AFK
malina has quit [Ping timeout: 248 seconds]
ygrek_ has joined #ocaml
ygrek has quit [Ping timeout: 260 seconds]
Muzer has quit [Ping timeout: 244 seconds]
chris2 has quit [Ping timeout: 268 seconds]
hxegon_AFK is now known as hxegon
chris2 has joined #ocaml
yegods has quit [Remote host closed the connection]
aantron has quit [Remote host closed the connection]
aantron has joined #ocaml
yegods has joined #ocaml
Haudegen has quit [Ping timeout: 268 seconds]
aantron_ has joined #ocaml
aantron has quit [Ping timeout: 244 seconds]
hxegon has quit [Ping timeout: 244 seconds]
estokes has joined #ocaml
estokes has left #ocaml [#ocaml]
letaris has joined #ocaml
Haudegen has joined #ocaml
yegods has quit [Remote host closed the connection]
yegods has joined #ocaml
letaris has quit [Read error: Connection timed out]
pyon has quit [Quit: fix config]
pyon has joined #ocaml
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
badon has quit [Ping timeout: 250 seconds]
badon has joined #ocaml
Haudegen has quit [Ping timeout: 268 seconds]
yegods has quit [Remote host closed the connection]
yegods has joined #ocaml
Haudegen has joined #ocaml
nicholasf has quit [Remote host closed the connection]
idegen has quit [Quit: Leaving.]
anoisz has joined #ocaml
NingaLeaf has joined #ocaml
NingaLeaf has left #ocaml [#ocaml]
aantron_ has quit [Remote host closed the connection]
aantron has joined #ocaml
teknozulu has quit [Ping timeout: 244 seconds]
nicholasf has joined #ocaml
struk|desk|away is now known as struk|desk
ygrek_ has quit [Ping timeout: 244 seconds]
ggole has joined #ocaml
noddy has joined #ocaml
badon has quit [Disconnected by services]
badon_ has joined #ocaml
badon_ is now known as badon
wiredsister has quit [Ping timeout: 268 seconds]
wiredsister has joined #ocaml
slash^ has joined #ocaml
struk|desk is now known as struk|desk|away
wiredsister has quit [Ping timeout: 250 seconds]
yegods has quit [Remote host closed the connection]
wiredsister has joined #ocaml
JacobEdelman_ has joined #ocaml
wiredsister has quit [Ping timeout: 246 seconds]
ygrek_ has joined #ocaml
copy` has quit [Quit: Connection closed for inactivity]
noddy has quit [Ping timeout: 252 seconds]
Muzer has joined #ocaml
wiredsister has joined #ocaml
ibor1 has quit [Ping timeout: 264 seconds]
Vintila has quit [Ping timeout: 252 seconds]
MercurialAlchemi has joined #ocaml
wiredsister has quit [Ping timeout: 264 seconds]
anoisz has quit [Read error: Connection reset by peer]
wiredsister has joined #ocaml
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
wiredsister has quit [Ping timeout: 260 seconds]
Kakadu has joined #ocaml
manizzle has quit [Remote host closed the connection]
JacobEdelman_ has quit [Quit: Connection closed for inactivity]
wiredsister has joined #ocaml
orbifx2 has joined #ocaml
orbifx has quit [Ping timeout: 246 seconds]
ygrek_ has quit [Ping timeout: 252 seconds]
wiredsister has quit [Ping timeout: 244 seconds]
Simn has joined #ocaml
Sorella has quit [Quit: Connection closed for inactivity]
wiredsister has joined #ocaml
schive has joined #ocaml
wiredsister has quit [Remote host closed the connection]
wiredsister has joined #ocaml
orbifx has joined #ocaml
Vintila has joined #ocaml
orbifx2 has quit [Ping timeout: 250 seconds]
wiredsister has quit [Ping timeout: 268 seconds]
nicholasf has quit [Remote host closed the connection]
badon has quit [Quit: Leaving]
badon has joined #ocaml
nicholasf has joined #ocaml
malina has joined #ocaml
Haudegen has quit [Ping timeout: 260 seconds]
silver has joined #ocaml
malina has quit [Ping timeout: 244 seconds]
wiredsister has joined #ocaml
rand__ has joined #ocaml
Haudegen has joined #ocaml
wiredsister has quit [Remote host closed the connection]
wiredsister has joined #ocaml
wiredsister has quit [Remote host closed the connection]
wiredsister has joined #ocaml
malina has joined #ocaml
wiredsister has quit [Ping timeout: 250 seconds]
<companion_cube> edwin, Leonidas: release in a few days, new qtest will rock ;-)
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
badon has quit [Disconnected by services]
badon_ has joined #ocaml
badon_ is now known as badon
yegods has joined #ocaml
yegods has quit [Remote host closed the connection]
orbifx2 has joined #ocaml
orbifx has quit [Ping timeout: 248 seconds]
<Leonidas> companion_cube: awesome! will test as soon as I get my new laptop
<companion_cube> \o/
butts_butts has joined #ocaml
ibor has joined #ocaml
anoisz has joined #ocaml
wiredsister has joined #ocaml
ibor has quit [Ping timeout: 260 seconds]
rand__ has quit [Quit: leaving]
<companion_cube> wtf, cohttp depends on camlp4 again?!
<orbitz> Is there suggested reading on GADTs for Ocaml? Seems like I'm just stumbling upon nice usages of them rather than understanding how to directly use them.
<companion_cube> pa_fields_conv, pa_sexp_conv
<orbitz> I just learned about: https://bitbucket.org/snippets/orbitz/XKbR8
<orbitz> Which is pretty cool, I thinks.
<companion_cube> it's not hard to use, just learn hwo to manually specify the type of a recursive function
<companion_cube> because you will need to :p
<orbitz> It's not that they are hard to use, but I just don't grok them well enough to know when a situation is best solved with them.
wiredsister has quit [Ping timeout: 240 seconds]
zarul has quit [Ping timeout: 248 seconds]
Kakadu has quit [Ping timeout: 248 seconds]
shinnya has joined #ocaml
wiredsister has joined #ocaml
wiredsister has quit [Ping timeout: 260 seconds]
darkf has quit [Quit: Leaving]
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
<fds> orbitz: You might find this interesting: http://www.cl.cam.ac.uk/teaching/1415/L28/gadts.pdf
<orbitz> Thanks
leyyin has joined #ocaml
xapantu has joined #ocaml
Riviera has quit [Remote host closed the connection]
Kakadu has joined #ocaml
wiredsister has joined #ocaml
wiredsister has quit [Ping timeout: 260 seconds]
<mrvn> I hate that type inference totaly breaks down with GADTs.
<malina> I hate when nickers mismatch the colour of bra's in the morning but ok
<malina> ymmv
<ggole> I miss or-patterns as much.
<ggole> (As inference.)
wiredsister has joined #ocaml
idegen has joined #ocaml
yegods has joined #ocaml
anoisz has quit [Read error: Connection reset by peer]
wiredsister has quit [Ping timeout: 264 seconds]
MercurialAlchemi has quit [Ping timeout: 244 seconds]
nicholasf has quit [Remote host closed the connection]
butts_butts has quit [Read error: Connection reset by peer]
wiredsister has joined #ocaml
wiredsister has quit [Ping timeout: 244 seconds]
wiredsister has joined #ocaml
yegods has quit [Remote host closed the connection]
wiredsister has quit [Ping timeout: 248 seconds]
Kakadu has quit [Quit: Konversation terminated!]
ansiwen has joined #ocaml
idegen has quit [Quit: Leaving.]
<ansiwen> how can I match against a record with an identical label as another record in the same scope without raising warning 42: "this use of X required disambiguation."?
<zozozo> ansiwen: try matching on a different label of the same record first ?
<ansiwen> zozozo: unfortunately all labels of record A are also in record B
<zozozo> or specify the type of the argument
<zozozo> ansiwen: then may I ask why you have two types which are basically equal ?
<ansiwen> it's not my type, see above
<zozozo> ah, ok
<zozozo> well then add some type annotations
<ansiwen> zozozo: that's what I tried, but it doesn't make the warning disappear
<zozozo> like match (x : Rsa.pub) with ...
<ansiwen> oh, in the match line, not in the pattern line?
leowzukw has joined #ocaml
<zozozo> yup, basically tell the compiler the type of the value that you match on
<flux> hmm, can you really get rid of the warning without explicitly indicating the constructor's full path?
<flux> ..other than by simply disabling the warning
<flux> which I believe many do
<ansiwen> flux: the warning has been enabled in the mirage project by default now
<flux> so if you have a match for a record to avoid the warning you need to instead of: match foo with { x = 42 } -> .. you do match foo with { Rsa.Pub.x = 42 } ..
<flux> unless the trick zozozo mentioned works of course :)
<ansiwen> zozozo: in the match line I don't know yet, if it is that key type, so I would need to add another level of matching... doesn't look nice...
<zozozo> ermm.. how can you not know the type of the value you match on ?
<ansiwen> zozozo: it's the type of a variant
<zozozo> can you show some code ?
<ansiwen> zozozo: yes... wait
Sorella has joined #ocaml
yegods has joined #ocaml
orbifx2 has quit [Ping timeout: 244 seconds]
<Drup> ansiwen: you can still disable it, even if it's enabled by default
<Drup> your project, you choose your warning :)
<ansiwen> Drup: sure, with a Makefile.user I can disable it. but since it's my first ocaml project, I wanted to take that as a learning exercise...
<zozozo> ansiwen: what's the type of data ?
<Drup> ansiwen: I personally disable this warning
<flux> I think it's nice that you need to disable the warning. if the default were otherwise, the error message might turn out to be even more baffling if one isn't aware that it's just a 'shortcut' the compiler provides, and it needs some help from the user :)
<zozozo> well, I find it strange then, and I'd disable the warning as Drup suggests
wiredsister has joined #ocaml
<ansiwen> zozozo: ok... I see
wiredsister has quit [Ping timeout: 276 seconds]
<ansiwen> zozozo: even with this expression the warning appears: `(pub:Nocrypto.Rsa.pub).Nocrypto.Rsa.n`
<ansiwen> so it seems like you can't get rid of the warning if there is label shadowing
wiredsister has joined #ocaml
Haudegen has quit [Ping timeout: 276 seconds]
<Drup> Well, this warning is kinda made for that ...
wiredsis` has joined #ocaml
octachron has joined #ocaml
wiredsister has quit [Ping timeout: 252 seconds]
wiredsis` has quit [Ping timeout: 252 seconds]
MercurialAlchemi has joined #ocaml
wiredsis` has joined #ocaml
letaris has joined #ocaml
Haudegen has joined #ocaml
Enjolras has quit [Quit: Lost terminal]
hxegon has joined #ocaml
GeorgeHahn has joined #ocaml
yegods has quit []
jgjl has joined #ocaml
jgjl has quit [Client Quit]
wiredsis` has quit [Ping timeout: 252 seconds]
larhat has quit [Quit: Leaving.]
<flux> mirage sure likes warnings.
dwillems has joined #ocaml
<flux> so doesn't the warning 42 basically mean that compilers that didn't yet have the disambiguation feature are not able to compile it?
<flux> yet to me it seems like Pub.Rsa { Nocrypto.Rsa.e; n} is completely non-ambiguous?-o
<flux> or does the Nocrypto.Rsa module expose two records withh the field e.. right?
wiredsis` has joined #ocaml
<flux> ah right, that's the issue
wiredsis` has quit [Ping timeout: 246 seconds]
<flux> and there's really no way to refer to the pub's field e or n without activating that warning
dwillems has quit [Ping timeout: 244 seconds]
<flux> ansiwen, btw, there is also this, if you still want to (for whatever reason) to keep the warning enabled for the rest of the file: begin [@ocaml.warning "-42"] match ... end
<companion_cube> [@@@ocaml.warning "-42"] at toplevel, simpler
<flux> well I of course meant that to be used inside the function for only local effect
<flux> but if one wants to use it for the file, then that's probably the easy way to go
<octachron> flux, "match[@warning]" also works
Algebr` has joined #ocaml
<flux> octachron, oh, nice
<Drup> only since 4.03, no ?
<Drup> Ah no, this one was already there
hxegon has quit [Quit: BRB]
Vintila has quit [Ping timeout: 246 seconds]
hydan has quit [Ping timeout: 252 seconds]
letaris has quit [Read error: Connection timed out]
<mrvn> I would write: Nocrypto.Rsa.{e; n}
<companion_cube> but this is only 4.03 :)
<companion_cube> at least I think?
<mrvn> Nocrypto.Rsa.({e; n})
jackweirdy has joined #ocaml
d0nn1e has quit [Ping timeout: 244 seconds]
<flux> mrvn, the problem is that the module e and n are part of two records inside the Nocrypto.Rsa
<flux> or perhaps you didn't mean that as a solution at all :)
d0nn1e has joined #ocaml
<mrvn> yeah, don't do that.
<ggole> Nocrypto.Rsa.{e; n} isn't a valid pattern
<companion_cube> it will be
<mrvn> ggole: whatr version?
<ggole> 4.02... does 4.03 change it?
<octachron> ggole, not in 4.03, the change is still awaiting for review
<ggole> Seems like a sensible change.
<Drup> Algebr`: a presentation with suddent, loud sound, urrrk
<Drup> kill it with fire
pyon has quit [Quit: cleanup]
<Algebr`> i didn't have sound on, sorry
<Algebr`> but go through it, its amazing
jgjl has joined #ocaml
pyon has joined #ocaml
dwillems has joined #ocaml
hxegon has joined #ocaml
samae has joined #ocaml
<samae> Hi. Is there a tool to extract the modular layout of an OCaml program?
<companion_cube> you mean module dependencies?
<companion_cube> ocamldoc can do it
<samae> at least
* samae go looky
<companion_cube> I'm not sure there is a way to obtain the full call graph right now
<companion_cube> ocamldoc -dot can print module dependencies
<samae> thx!
martintrojer has quit [Ping timeout: 248 seconds]
martintrojer has joined #ocaml
zarul has joined #ocaml
leowzukw has quit [Quit: leaving]
anoisz has joined #ocaml
rom15044 has joined #ocaml
zarul has quit [Quit: Leaving]
zarul has joined #ocaml
dhil has joined #ocaml
groovy2shoes has quit [Quit: Leaving]
zarul has quit [Changing host]
zarul has joined #ocaml
<flux> hmm, lemonade doesn't install because of lacking generic.project.mk. I suppose it should come with the build system bmake..?
demonimin has joined #ocaml
<flux> curiously though I did have lemonade.0.4.0 installed, but now that either doesn't install..
<flux> checking my backups if I ever had such a file :)
<flux> oh, and I still do, it comes with the bsdowl package. for some reason it just doesn't find it.
chindy has joined #ocaml
seangrove has joined #ocaml
malc_ has joined #ocaml
<flux> I wouldn't mind if there was some kind of CI for promoting opam versions into the 'confirmed compliation' stage ;-)
jackweirdy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<flux> maybe it could even be distributed among the opam clients, slightly similar to debian's popularity contest
<flux> "in this operating system version on this platform with these opam packages this package compiled yes/no"
shinnya has quit [Ping timeout: 260 seconds]
struk|desk|away is now known as struk|desk
hydan has joined #ocaml
hxegon has quit [Quit: BRB]
Haudegen has quit [Ping timeout: 260 seconds]
djellemah_ has joined #ocaml
djellemah has quit [Ping timeout: 276 seconds]
noddy has joined #ocaml
seangrove has quit [Ping timeout: 248 seconds]
jackweirdy has joined #ocaml
seangrove has joined #ocaml
manizzle has joined #ocaml
Algebr` has quit [Ping timeout: 248 seconds]
octachron has quit [Read error: Connection reset by peer]
pierpa has joined #ocaml
dwillems has quit [Ping timeout: 244 seconds]
Haudegen has joined #ocaml
Algebr` has joined #ocaml
octachron has joined #ocaml
jgjl has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
badon has quit [Disconnected by services]
badon_ has joined #ocaml
badon_ is now known as badon
dhil has quit [Quit: Leaving]
idegen has joined #ocaml
badon has quit [Disconnected by services]
badon_ has joined #ocaml
badon_ is now known as badon
hxegon has joined #ocaml
Kakadu has joined #ocaml
jackweirdy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
struk|desk is now known as struk|desk|away
t4nk533 has joined #ocaml
slash^ has quit [Read error: Connection reset by peer]
ggole has quit []
t4nk533 has quit [Ping timeout: 250 seconds]
chindy has quit [Remote host closed the connection]
nicholasf has joined #ocaml
letaris has joined #ocaml
hxegon has quit [Quit: BRB]
malina is now known as hoohoo
hoohoo is now known as micca
noddy has quit [Ping timeout: 240 seconds]
micca is now known as malina
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
nuuit has quit [Quit: Yaaic - Yet another Android IRC client - http://www.yaaic.org]
atsampson has quit [Ping timeout: 264 seconds]
malina has quit [Changing host]
malina has joined #ocaml
malina has quit [Quit: Throwing apples of Montserrat]
malina has joined #ocaml
natimic has joined #ocaml
jgjl has joined #ocaml
manizzle has quit [Read error: Connection reset by peer]
<orbitz> What is "open!", I cannot find it in the Ocaml INRIA documentation
<companion_cube> it's like open, but it silents the shadowing warnings
<Algebr`> same thing for method!
<companion_cube> say, what is the usual "'a or_error" type?
<companion_cube> is it ('a, string) result, or ('a, exn) result?
<companion_cube> I'm using the first one, but am considering using the second one in place, for it is more flexible
<Algebr`> meh
zozozo has quit [Quit: WeeChat 1.4]
zozozo has joined #ocaml
mettekou has joined #ocaml
<orbitz> companion_cube: exn i think
<orbitz> strings as errors are the devil's work
<companion_cube> heh
darkf has joined #ocaml
<companion_cube> it's more natural, also
<Drup> I vote exn too
<orbitz> Go does the string thing in many cases and I've never met anyone that didn't hate it.
<orbitz> Turning error handling into a parsing problem is less tha nideal :)
<Algebr`> I think JS did a blog post about some performance things done to avoid the string for error
<Drup> It's amusing to consider that as a performance problem
<Algebr`> I think they wanted to avoid the allocation?
<Drup> Note that it's wrong, but that's clearly not what would be my primary issue ^^
<Algebr`> ?
<malc_> it took me a whole 5 second of laborious brain work to discern javascript from jane street, thanks Algebr`
<Algebr`> lol
<orbitz> haha indeed. If a prper error type were too slow I wouldn't switch to strings, I'd try to fix the slowness :)
hxegon has joined #ocaml
<orbitz> I've been trying ot read a bunch of Jane St code lately. I find it very difficult.
hydan has quit [Quit: hydan]
hydan has joined #ocaml
hxegon has quit [Quit: PEACE OUT]
<companion_cube> exn it is then
<flux> ocaml does also string errors, who hasn't matched on Failure "int_of_string" ;-)
<flux> it'd be neat if there was a nice exception analysis system for ocaml, but I guess that's not an issue for Jane Street :)
jgjl has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<companion_cube> I don't match on those failures
<companion_cube> it's a bad idea :p
mettekou has quit [Read error: Connection reset by peer]
<flux> even the standard library does it!
<flux> and ocamlgraph, ocamldap, labltk, ocollection, batteries, ..
<companion_cube> lulz
<companion_cube> ocollection? didn't know that one
<flux> src/batList.ml: with Failure "hd" -> None
<flux> I suppose it'd be somehow better to just catch with _ -> None. but on the other hand, it'd be somehow worse.
<companion_cube> nah
<companion_cube> it's better
<companion_cube> just make the try/with as narrow as possible
<Drup> flux: there is a new warning for this kind of code
<companion_cube> I mean, how many exceptions can you have in List.hd or float_of_string?
<flux> wish the audio quality of those videos were better..
<flux> companion_cube, well, that's realistically what I do as well. but sometimes it's nice to do multiple things instead of wrapping each and every thing with a try/with.
<flux> I suppose this doesn't work yet: match int_of_string a, int_of_string b with exception _, exception _ -> ..
<companion_cube> oh
<companion_cube> that would be interesting
<mrvn> flux: why should it execute the other if the first one fails?
<flux> mrvn, which one is the first one anyway?
<flux> you didn't except an evaluation order for tuples did you :P
<mrvn> flux: no, first one is indetermine and actually changes between bytecode and native. :)
<flux> so best to do both!
<flux> though it wouldn't really be a tuple anymore
Anarchos has joined #ocaml
letaris has quit [Read error: Connection timed out]
badon has quit [Disconnected by services]
badon_ has joined #ocaml
badon_ is now known as badon
silver has quit [Quit: rakede]
julien_t has joined #ocaml
nicholasf has quit [Remote host closed the connection]
schive has quit [Quit: Leaving]
nicholasf has joined #ocaml
<flux> hmm, ppx_curried_constr, I wonder if I'll even start using that
<flux> maybe the next time I find myself manually currying constructors I'll just instead put the ppx in
<flux> didn't work in the toplevel for just-defined constructor though :)
<flux> (in fact, the constructor doesn't work at all now)
leyyin has quit [Ping timeout: 244 seconds]
yegods has joined #ocaml
<flux> maybe their approach is somehow broken in 4.02.3, ppx_implicits doesn't work for the basic example
<flux> the ability to do typed things in ppx extensions sounds pretty cool.. and potentially awful :).
mettekou has joined #ocaml
julien_t has quit [Ping timeout: 240 seconds]
<flux> let add = [%stackoverflow "add two integers"] 2 3 <- use string as a search expression to find a function of form int -> int -> _ ;-)
badon has quit [Disconnected by services]
badon_ has joined #ocaml
badon_ is now known as badon
Anarchos has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
malc_ has quit [Quit: ERC (IRC client for Emacs 25.0.50.2)]
ibor has joined #ocaml
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
nicholasf has quit [Remote host closed the connection]
nicholasf has joined #ocaml
MercurialAlchemi has quit [Ping timeout: 248 seconds]
teknozulu has joined #ocaml
<edwin> o.O google thinks forge.ocamlcore.org is dangerous https://www.google.com/transparencyreport/safebrowsing/diagnostic/index.html?hl=en-US#url=http://forge.ocamlcore.org/frs/download.php/1258/ounit-2.0.0.tar.gz
badon has quit [Quit: Leaving]
yegods has quit []
octachron has quit [Ping timeout: 244 seconds]
yegods has joined #ocaml
Kakadu has quit [Remote host closed the connection]
yegods has quit [Remote host closed the connection]
yegods has joined #ocaml
ygrek has joined #ocaml
mettekou has quit [Read error: Connection reset by peer]
ygrek has quit [Ping timeout: 264 seconds]
mettekou has joined #ocaml