adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | Current MOOC: https://huit.re/ocamlmooc | OCaml 4.04.0 release notes: http://ocaml.org/releases/4.04.html | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
MercurialAlchemi has quit [Ping timeout: 256 seconds]
pierpa has quit [Ping timeout: 248 seconds]
zirman has joined #ocaml
zirman has joined #ocaml
zirman has quit [Changing host]
lmaocaml has joined #ocaml
<lmaocaml> what lexer people use for utf-8 inputs?
cheater has quit [Ping timeout: 252 seconds]
<lmaocaml> i have found ulex and sedlex not sure which is "maintained"?
<companion_cube> bunzli libs are nice
<companion_cube> uutf, I think, for basic decoding
nomicflux has joined #ocaml
d0nn1e has quit [Ping timeout: 250 seconds]
d0nn1e has joined #ocaml
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
zpe has quit [Ping timeout: 258 seconds]
silver has quit [Read error: Connection reset by peer]
BitPuffin|osx has quit [Read error: Connection reset by peer]
lmaocaml has quit [Quit: Page closed]
rgrinberg has quit [Remote host closed the connection]
okuu has quit [Quit: Unyu~? Emacs sucks, goddammit.]
pyon has joined #ocaml
fraggle_ has quit [Ping timeout: 246 seconds]
rgrinberg has joined #ocaml
fraggle_ has joined #ocaml
Madars has quit [Ping timeout: 258 seconds]
TarVanimelde has quit [Quit: TarVanimelde]
TarVanimelde has joined #ocaml
TarVanimelde has quit [Client Quit]
TarVanimelde has joined #ocaml
mfp has quit [Ping timeout: 260 seconds]
Madars has joined #ocaml
noddy has joined #ocaml
jao has quit [Ping timeout: 260 seconds]
TarVanimelde has quit [Read error: Connection reset by peer]
TarVanimelde has joined #ocaml
jao has joined #ocaml
zirman has quit [Remote host closed the connection]
jao has quit [Remote host closed the connection]
FreeBirdLjj has quit [Remote host closed the connection]
TarVanimelde has quit [Quit: TarVanimelde]
TarVanimelde has joined #ocaml
zirman has joined #ocaml
zirman has quit [Ping timeout: 256 seconds]
sigjuice has quit [Ping timeout: 260 seconds]
srcerer_ has joined #ocaml
sigjuice has joined #ocaml
srcerer has quit [Ping timeout: 250 seconds]
TarVanimelde has quit [Quit: TarVanimelde]
FreeBirdLjj has joined #ocaml
cheater has joined #ocaml
copy` has quit [Quit: Connection closed for inactivity]
Madars has quit [Ping timeout: 250 seconds]
Madars has joined #ocaml
FreeBirdLjj has quit [Remote host closed the connection]
nomicflux has quit [Quit: nomicflux]
FreeBirdLjj has joined #ocaml
ygrek has quit [Ping timeout: 250 seconds]
FreeBirdLjj has quit [Ping timeout: 246 seconds]
rgrinberg has quit [Ping timeout: 268 seconds]
rgrinberg has joined #ocaml
slash^ has joined #ocaml
jonasen has joined #ocaml
AlexDenisov has joined #ocaml
gjaldon has joined #ocaml
tmtwd has joined #ocaml
<gjaldon> anyone here using ocaml on bash on windows? I'm replacing my mac with a windows laptop and just wondering if I could develop ocaml programs in bash on windows. Would like to avoid dual-booting.
TarVanimelde has joined #ocaml
TarVanimelde has quit [Quit: TarVanimelde]
TarVanimelde has joined #ocaml
tmtwd has quit [Ping timeout: 246 seconds]
MercurialAlchemi has joined #ocaml
rgrinberg has quit [Ping timeout: 265 seconds]
alexelcu has joined #ocaml
jonasen has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Mohan has joined #ocaml
Mohan is now known as Guest28939
zirman has joined #ocaml
zirman has quit [Ping timeout: 252 seconds]
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 240 seconds]
gjaldon has quit [Remote host closed the connection]
elfring has joined #ocaml
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 245 seconds]
maattdd has joined #ocaml
maattdd has quit [Ping timeout: 258 seconds]
AlexDeni_ has joined #ocaml
AlexDenisov has quit [Ping timeout: 250 seconds]
TarVanimelde has quit [Ping timeout: 258 seconds]
TarVanimelde has joined #ocaml
shinnya has joined #ocaml
fre has joined #ocaml
average has quit [Ping timeout: 260 seconds]
average has joined #ocaml
malina has joined #ocaml
noddy has quit [Ping timeout: 260 seconds]
mfp has joined #ocaml
SIGILL has quit [Read error: Connection reset by peer]
SIGILL has joined #ocaml
noddy has joined #ocaml
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 248 seconds]
maattdd has joined #ocaml
Guest28939 has quit [Ping timeout: 260 seconds]
fre has quit [Ping timeout: 256 seconds]
alexelcu has quit [Quit: Leaving.]
alexelcu has joined #ocaml
alexelcu has quit [Client Quit]
jonasen has joined #ocaml
TarVanimelde has quit [Ping timeout: 258 seconds]
TarV has joined #ocaml
TarVanimelde has joined #ocaml
TarV has quit [Ping timeout: 244 seconds]
TarV has joined #ocaml
TarVanimelde has quit [Ping timeout: 244 seconds]
gjaldon has joined #ocaml
TarV has quit [Quit: Leaving]
TarVanimelde has joined #ocaml
jonasen has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jnavila has joined #ocaml
malina has quit [Remote host closed the connection]
TarVanimelde has quit [Quit: Leaving]
silver has joined #ocaml
TarVanimelde has joined #ocaml
gjaldon has quit []
zpe has joined #ocaml
zirman has joined #ocaml
zirman has quit [Changing host]
zirman has joined #ocaml
pierpa has joined #ocaml
jonasen has joined #ocaml
shinnya has quit [Ping timeout: 268 seconds]
copy` has joined #ocaml
_whitelogger has joined #ocaml
fre has joined #ocaml
cheater has quit [Ping timeout: 260 seconds]
cheater has joined #ocaml
TarVanim_ has joined #ocaml
TarVanimelde has quit [Ping timeout: 260 seconds]
slash^ has quit [Quit: Leaving]
slash^ has joined #ocaml
AlexDenisov has joined #ocaml
AlexDeni_ has quit [Ping timeout: 246 seconds]
TarVanim_ has quit [Quit: TarVanim_]
TarVanimelde has joined #ocaml
malc_ has joined #ocaml
cheater has quit [Remote host closed the connection]
cheater has joined #ocaml
kamog has joined #ocaml
d0nn1e has quit [Ping timeout: 246 seconds]
d0nn1e has joined #ocaml
fre has quit [Ping timeout: 260 seconds]
zirman has quit [Remote host closed the connection]
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
zpe has quit [Ping timeout: 260 seconds]
zirman has joined #ocaml
zirman has joined #ocaml
zirman has quit [Changing host]
zirman has quit [Ping timeout: 246 seconds]
chris2 has quit [Ping timeout: 256 seconds]
TarVanimelde has quit [Ping timeout: 252 seconds]
TarVanim_ has joined #ocaml
TarVanim_ is now known as TarVanimelde
cheater has quit [Ping timeout: 246 seconds]
chris2 has joined #ocaml
pyon has quit [Remote host closed the connection]
pyon has joined #ocaml
cheater has joined #ocaml
octachron has joined #ocaml
tane has joined #ocaml
tane has quit [Client Quit]
cheater has quit [Ping timeout: 260 seconds]
cheater has joined #ocaml
zirman has joined #ocaml
zirman has joined #ocaml
zirman has quit [Changing host]
nomicflux has joined #ocaml
zirman has quit [Ping timeout: 250 seconds]
slash^1 has joined #ocaml
slash^1 has left #ocaml [#ocaml]
kamog` has joined #ocaml
BitPuffin|osx has joined #ocaml
kamog has quit [Ping timeout: 250 seconds]
nomicflux has quit [Quit: nomicflux]
FreeBirdLjj has joined #ocaml
nomicflux has joined #ocaml
rgrinberg has joined #ocaml
kamog` is now known as kamog
FreeBirdLjj has quit [Ping timeout: 256 seconds]
zirman has joined #ocaml
zirman has joined #ocaml
zirman has quit [Changing host]
chris2 has quit [Ping timeout: 260 seconds]
nomicflux has quit [Quit: nomicflux]
TarVanim_ has joined #ocaml
TarVanimelde has quit [Ping timeout: 248 seconds]
chris2 has joined #ocaml
TarVanim_ is now known as TarVanimelde
cheater has quit [Remote host closed the connection]
slash_ has joined #ocaml
cheater has joined #ocaml
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 245 seconds]
kamog has quit [Remote host closed the connection]
dxtr has quit [Ping timeout: 260 seconds]
dxtr has joined #ocaml
kamog has joined #ocaml
nomicflux has joined #ocaml
rgrinberg has quit [Remote host closed the connection]
FreeBirdLjj has joined #ocaml
rgrinberg has joined #ocaml
agarwal1975 has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 256 seconds]
copy` has quit [Quit: Connection closed for inactivity]
tane has joined #ocaml
<Leonidas> companion_cube: how do I turn an int into an Int.t?
<companion_cube> hu? it's the same type
infinity0 has quit [Remote host closed the connection]
<Leonidas> companion_cube: I have a Map.Make(Int) in a type and now I am trying to access a value using get but it said Error: This expression has type int but an expression was expected of type Reklama.Ad.DataBase.key
infinity0 has joined #ocaml
<companion_cube> well maybe some functor instantiation hides the type
<Leonidas> It's also possible that I have made the type too abstract
<Leonidas> In my module sig I have module DataBase : Map.S
<companion_cube> there
<companion_cube> you need `with type key = int`
rgrinberg has quit [Ping timeout: 260 seconds]
<Leonidas> now it says that it can't match type t = int with type +'a t
<Leonidas> oh, wait wrong type
<Leonidas> I shouldn't try to redefine t :)
<companion_cube> heh
FreeBirdLjj has joined #ocaml
jnavila has quit [Ping timeout: 260 seconds]
zpe has joined #ocaml
zpe has quit [Ping timeout: 268 seconds]
jnavila has joined #ocaml
nomicflux has quit [Quit: nomicflux]
AlexRussia has quit [Ping timeout: 240 seconds]
govg has quit [Ping timeout: 260 seconds]
agarwal1975 has quit [Quit: agarwal1975]
stux|RC-only has quit [Ping timeout: 256 seconds]
slash_ has quit [Read error: Connection reset by peer]
slash^ has quit [Read error: Connection reset by peer]
stux|RC-only has joined #ocaml
jerith has quit [Quit: Reconnecting]
jerith has joined #ocaml
AlexRussia has joined #ocaml
jnavila has quit [Ping timeout: 258 seconds]
jonasen has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
sillyotter has joined #ocaml
govg has joined #ocaml
sillyotter has quit [Client Quit]
malc_ has quit [Remote host closed the connection]
ygrek has joined #ocaml
kakadu has joined #ocaml
govg has quit [Quit: leaving]
jnavila has joined #ocaml
zpe has joined #ocaml
copy` has joined #ocaml
kamog has quit [Remote host closed the connection]
lopex has joined #ocaml
cheater has quit [Ping timeout: 256 seconds]
FreeBirdLjj has quit [Remote host closed the connection]
cheater has joined #ocaml
ygrek has quit [Remote host closed the connection]
orbifx has joined #ocaml
pyon has quit [Quit: Goddammit, Emacs!]
<orbifx> how do I select which files are installed from my package during installation?
pyon has joined #ocaml
<octachron> orbifx, which tools are you using?
sh0t has joined #ocaml
chris2 has quit [Ping timeout: 246 seconds]
<orbifx> ocamlbuild
<orbifx> make
ygrek has joined #ocaml
<orbifx> octachron: do I specify the files in a list, put them in a folder?
<octachron> in this case, you have to write your "make install" or ".install" file yourself.
<orbifx> and install in what dirs? I pressume opam exports an environmental variable?
<orbifx> Is there a doc somewhere from this approach?
<octachron> For simple case, I believe that writing manually a "package_name.install" file is fine
<orbifx> thanks octachron, will check it out
chris2 has joined #ocaml
infinity0 has quit [Remote host closed the connection]
infinity0 has joined #ocaml
jnavila has quit [Ping timeout: 240 seconds]
pyon has quit [Quit: Fix config.]
FreeBirdLjj has joined #ocaml
orbifx has quit [Ping timeout: 258 seconds]
petroav has joined #ocaml
<petroav> Hey everyone, I'm working on the OCaml MOOC and had a question. I don't understand the last line of this pastebin, given the two above http://pastebin.com/HuSE3Qqf
<petroav> Is the last line a function? If so why is the first argument being completely ignored? For background, these types are being defined in the context of solving a 2-d board puzzle with pieces etc.
<octachron> petroav, "_" is the wild card pattern, it can match anything but is not bound to anything
<petroav> octachron, OK so the last line is a function that takes two arguments, the first one which it ignores and the second on which is of type move?
<octachron> yes
<octachron> function argument are patterns in ocaml, it can be pretty useful with tuples or record arguments for instance
<petroav> I see. Yea, I don't think I had seen wildcard patterns as arguments to functions which I think is why I got confused
<octachron> e.g, "let f (x,y) = … " rather than "let f tuple = let (x,y) = tuple in … "
<petroav> good to know, thanks for the help, much appreciated :)
<octachron> petroav, personally I would problaby write "let move _arg (Move (_, _, b)) = b" rather than use a wildcard pattern directly
<octachron> in order to make easier to remember what the first argument of move is supposed to be
<petroav> octachron, yep I agree, or even something like "let move _ignored (Move (_, _, b)) = b"
<petroav> but it is possible that _ is suffiently clear semantically for someone who has read enough OCaml code
<flux> it's nice sometimes to use such labels to just remind what is being ignored there
<flux> and compiler even has support for it, in the form of not complaining that such bindings are not used
johnelse has quit [Ping timeout: 245 seconds]
Jarth has joined #ocaml
<Jarth> Hello
<Jarth> I'm stuck with building ocaml and related software on alpine linux, ocaml builds eventually but for some reason throws segmentation faults. Alpine linux is using musl instead of glibc.
AlexDenisov has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nomicflux has joined #ocaml
tane has quit [Quit: Leaving]
elfring has quit [Quit: Konversation terminated!]
<Leonidas> Jarth: yeah, I had the same experience
<Leonidas> (was using alpine on arm, so I wasn't sure whether it was due to alpine or arm)
<Jarth> Leonidas my bet is musl
<Jarth> also using alpine on arm
zirman has quit [Remote host closed the connection]
<Leonidas> Jarth: you can also use glibc on alpine, that's how we run openjdk at work.
<Jarth> Leonidas i looked for it but could not find it in the repo
<Jarth> personally i'd prefer not
<Leonidas> you could try it and see if it fixes the issue and then revisit why it is failing with musl
<Leonidas> (maybe something to do with static linking)
<Jarth> Leonidas i don't get it anymore, after make install, ocamlc throws a segmentation fault, BUT, copy the binaries in the / of the source tree over the binaries installed in /usr/local ... works fine
<Leonidas> for me compilation was fine, but couldn't compile opam
<Jarth> when make lib-ext cppo fails with segmentation fault on one version, on other version cppo recipe failed, BUT recompile and different results for a single version
<Jarth> ocaml compiled eventually
<Jarth> opam, ocamlbuild, camlp4o, ocamlfind, all fail
petroav has quit [Ping timeout: 256 seconds]
zirman has joined #ocaml
zirman has joined #ocaml
zirman has quit [Changing host]
cpdean has joined #ocaml
<cpdean> i'm working through the the ocaml mooc right now, and I just got done with the homework on implementing a Trie. Managed to finish it finally, but was wondering if someone could give me advice for how to make this look more idiomatic or be closer to the correct codestyle for ocaml: https://gist.github.com/cpdean/ca15cec2b23089e1c2ad2e545108dd0a
zpe has quit [Remote host closed the connection]
kakadu has quit [Remote host closed the connection]
chris2 has quit [Ping timeout: 260 seconds]
<octachron> cpdean, catching all exceptions in "try … with exn -> None" may be hazardous
<cpdean> totally agree
<cpdean> what does list.assoc throw though?
<cpdean> in utop its just like 'Exception: …"
MercurialAlchemi has quit [Ping timeout: 256 seconds]
chris2 has joined #ocaml
<cpdean> nice
<cpdean> octachron: what about how i've written insert? something feels heavy about this. i probably shouldn't be nesting match expressions right? https://gist.github.com/cpdean/ca15cec2b23089e1c2ad2e545108dd0a#file-trie-ml-L102-L108
<octachron> cpdean, you could factorize more in the second match: since the two branch differs only by the value of x in "Trie (old_v, update_children childrens k <x>)"
<octachron> but nested matches are fine by themselves
sh0t has quit [Ping timeout: 248 seconds]