companion_cube changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml 4.05.0 release notes: https://caml.inria.fr/pub/distrib/ocaml-4.05/notes/Changes | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
nomicflux has quit [Client Quit]
shinnya has quit [Ping timeout: 264 seconds]
VermillionAzure has joined #ocaml
nomicflux has joined #ocaml
VermillionAzure has quit [Ping timeout: 248 seconds]
jimt_ is now known as jimt
SpiceGuid has quit [Quit: ChatZilla 0.9.93 [SeaMonkey 2.48/20170707010522]]
nomicflux has quit [Quit: nomicflux]
lgd__ has quit [Read error: Connection reset by peer]
lgd_ has joined #ocaml
mnemem has joined #ocaml
VermillionAzure has joined #ocaml
mnemem has quit [Ping timeout: 248 seconds]
nomicflux has joined #ocaml
VermillionAzure has quit [Read error: Connection reset by peer]
nomicflux has quit [Quit: nomicflux]
enterprisey has joined #ocaml
sh0t has quit [Remote host closed the connection]
mengu has joined #ocaml
mengu has quit [Ping timeout: 255 seconds]
mfp has quit [Ping timeout: 240 seconds]
nomicflux has joined #ocaml
FreeBirdLjj has joined #ocaml
nomicflux has quit [Quit: nomicflux]
FreeBirdLjj has quit [Ping timeout: 248 seconds]
cobreadmonster has joined #ocaml
mnemem has joined #ocaml
samrat has joined #ocaml
mnemem has quit [Ping timeout: 260 seconds]
enterprisey has quit [Ping timeout: 264 seconds]
enterprisey has joined #ocaml
Soni has quit [Ping timeout: 246 seconds]
Soni has joined #ocaml
lgd__ has joined #ocaml
lgd_ has quit [Remote host closed the connection]
zmt01 has joined #ocaml
ayxih has quit [Remote host closed the connection]
ayxih has joined #ocaml
zmt00 has quit [Ping timeout: 260 seconds]
pierpa has quit [Quit: Page closed]
Orion3k has quit [Ping timeout: 260 seconds]
Orion3k has joined #ocaml
govg has joined #ocaml
kerrhau has quit [Ping timeout: 260 seconds]
zmt01 has quit [Quit: Leaving]
kerrhau has joined #ocaml
kerrhau has quit [Changing host]
kerrhau has joined #ocaml
jao has quit [Ping timeout: 240 seconds]
jbrown has quit [Ping timeout: 240 seconds]
enterprisey has quit [Remote host closed the connection]
enterprisey has joined #ocaml
cobreadmonster has quit [Quit: Connection closed for inactivity]
mbuf has joined #ocaml
kerrhau has quit [Ping timeout: 240 seconds]
mnemem has joined #ocaml
cbot has quit [Quit: Leaving]
lgd__ has quit [Read error: Connection reset by peer]
lgd__ has joined #ocaml
infinity0_ has joined #ocaml
infinity0 has quit [Killed (kornbluth.freenode.net (Nickname regained by services))]
infinity0_ is now known as infinity0
infinity0 has joined #ocaml
infinity0 has quit [Changing host]
rostero has quit [Quit: Connection closed for inactivity]
slash^ has joined #ocaml
MercurialAlchemi has joined #ocaml
enterprisey has quit [Ping timeout: 240 seconds]
enterprisey has joined #ocaml
enterprisey has quit [Remote host closed the connection]
igmp has quit [Ping timeout: 240 seconds]
nore has quit [Ping timeout: 240 seconds]
Fistine has quit [Ping timeout: 258 seconds]
igmp has joined #ocaml
Fistine has joined #ocaml
jcelerier1 has quit [Ping timeout: 258 seconds]
nore has joined #ocaml
jcelerier1 has joined #ocaml
JeanMax has joined #ocaml
enterprisey has joined #ocaml
TheLemonMan has joined #ocaml
shiyaz has joined #ocaml
samrat has quit [Ping timeout: 248 seconds]
<jcelerier1> hi
<jcelerier1> I have a list of functions : [ f, g, h ], all of type "foo -> foo". How can I get the function "foo -> foo" that does (f (g (h a_foo))) ?
<jcelerier1> I tried this: https://paste.ofcode.org/xQun8m9vwCHmfE5DMJpitB but it does not work
<TheLemonMan> that's some kind of fold
samrat has joined #ocaml
<jcelerier1> TheLemonMan: like this ? "List.fold_left (fun x y -> x y) (fun x -> x) lst"
<Armael> you probably want fold_right instead
<Armael> let composel lst = List.fold_right (fun f acc -> (fun x -> f (acc x))) lst (fun x -> x);;
<Armael> (it didn't work because in the body of the fold, you were trying to apply the accumulator (of type foo -> foo) to a function of the list (also of type foo -> foo))
<jcelerier1> ah, yes, we have to return an actual function
<jcelerier1> I understand, thanks Armael & TheLemonMan !
<Armael> (instead you want to compose them, ie (fun x -> f (acc x))
enterprisey has quit [Remote host closed the connection]
mnemem has quit [Ping timeout: 240 seconds]
mnemem has joined #ocaml
<reynir> Leonidas: what ocaml version?
jimt has quit [Quit: leaving]
JeanMax has quit [Remote host closed the connection]
JeanMax has joined #ocaml
jimt has joined #ocaml
TheLemonMan has quit [Quit: "It's now safe to turn off your computer."]
samrat has quit [Ping timeout: 260 seconds]
ygrek_ has joined #ocaml
samrat_ has joined #ocaml
mfp has joined #ocaml
samrat_ has quit [Ping timeout: 240 seconds]
argent_smith has joined #ocaml
dhil has joined #ocaml
fraya has joined #ocaml
hannes` has joined #ocaml
<jcelerier1> is there a way to print any statement in the course of a function execution ?
<jcelerier1> (without using the print_ whatever functions)
hannes has quit [Disconnected by services]
hannes` is now known as hannes
<jcelerier1> just get the content of a value to display on the standard out
relrod_ has joined #ocaml
relrod_ has quit [Changing host]
relrod_ has joined #ocaml
ocabot_ has quit [Ping timeout: 248 seconds]
relrod has quit [Ping timeout: 248 seconds]
cross has quit [Ping timeout: 248 seconds]
Murmus has quit [Ping timeout: 248 seconds]
cross has joined #ocaml
JeanMax has quit [Remote host closed the connection]
ocabot_ has joined #ocaml
Murmus has joined #ocaml
relrod_ is now known as relrod
Exagone313 has quit [Ping timeout: 260 seconds]
<Fardale> jcelerier1: how would you print something without a print function ?
Exagone313 has joined #ocaml
ziyourenxiang has joined #ocaml
samrat_ has joined #ocaml
ia0 has quit [Quit: reboot]
freyr has joined #ocaml
ia0 has joined #ocaml
samrat_ has quit [Ping timeout: 248 seconds]
KongWubba has joined #ocaml
<jcelerier1> Fardale: well, I don't know but when I run in the interpreter it certainly prints out whatever I type in
<Fardale> because the interpreter call a print function to print the result
<Fardale> There no magic if you want to print something you have to call a print function
mengu has joined #ocaml
kakadu has joined #ocaml
lgd__ has quit [Remote host closed the connection]
lgd__ has joined #ocaml
<Drup> The interpreter does a big of magic for printing that is not accessible to regular programs
<jcelerier1> Drup: that's what I feared :(
mbuf has quit [Quit: Leaving]
mengu has quit [Remote host closed the connection]
mengu has joined #ocaml
nomicflux has joined #ocaml
freyr has quit [Remote host closed the connection]
KeyJoo has joined #ocaml
dtornabene has joined #ocaml
<Leonidas> reynir: 4.04.2. Because 4.05 does not work for us.
<Leonidas> jcelerier1: you can use ppx_deriving.show to generate show functions for you
<Leonidas> jcelerier1: or use companion_cube's containers, which has a library to compose printers which is sort of neat
<Leonidas> (sort of neat as in "boy I wish we just had the Show typeclass, but this is the next best thing")
Denommus has joined #ocaml
nomicflux has quit [Quit: nomicflux]
samrat_ has joined #ocaml
samrat_ has quit [Ping timeout: 248 seconds]
mnemem has quit [Read error: Connection reset by peer]
mnemem has joined #ocaml
mengu has quit [Remote host closed the connection]
samrat_ has joined #ocaml
nomicflux has joined #ocaml
nomicflux has quit [Client Quit]
mengu has joined #ocaml
sh0t has joined #ocaml
mengu has quit [Remote host closed the connection]
mengu has joined #ocaml
xuanrui has joined #ocaml
jbrown has joined #ocaml
xuanrui has quit [Quit: Leaving]
fraya has quit [Quit: Leaving]
nicoo has quit [Remote host closed the connection]
nicoo has joined #ocaml
mengu has quit [Remote host closed the connection]
mnemem has quit [Ping timeout: 248 seconds]
mnemem has joined #ocaml
mengu has joined #ocaml
shinnya has joined #ocaml
AltGr has joined #ocaml
MercurialAlchemi has quit [Ping timeout: 246 seconds]
KongWubba has quit [Ping timeout: 248 seconds]
al-damiri has joined #ocaml
FreeBirdLjj has joined #ocaml
theglass has joined #ocaml
theglass has quit [Changing host]
theglass has joined #ocaml
bbc_ is now known as bbc
ygrek_ has quit [Ping timeout: 258 seconds]
mengu has quit [Remote host closed the connection]
shinnya has quit [Ping timeout: 240 seconds]
TheLemonMan has joined #ocaml
nicoo has quit [Write error: Connection reset by peer]
nicoo has joined #ocaml
theglass has quit [Max SendQ exceeded]
theglass has joined #ocaml
theglass has quit [Changing host]
theglass has joined #ocaml
lgd__ has quit [Remote host closed the connection]
lgd__ has joined #ocaml
dtornabene has quit [Read error: Connection reset by peer]
dtornabene has joined #ocaml
KeyJoo has quit [Remote host closed the connection]
zolk3ri has joined #ocaml
KongWubba has joined #ocaml
JeanMax has joined #ocaml
lgd__ has quit [Read error: Connection reset by peer]
lgd__ has joined #ocaml
freusque has quit [Quit: WeeChat 1.7.1]
freusque has joined #ocaml
AltGr has left #ocaml [#ocaml]
mbuf has joined #ocaml
KongWubba has quit [Quit: Yaaic - Yet another Android IRC client - http://www.yaaic.org]
freusque has quit [Quit: WeeChat 1.7.1]
pzp has joined #ocaml
freusque has joined #ocaml
zmt00 has joined #ocaml
mbuf has quit [Remote host closed the connection]
mbuf has joined #ocaml
slash^ has quit [Read error: Connection reset by peer]
noddy has joined #ocaml
FreeBirdLjj has quit [Remote host closed the connection]
mbuf has quit [Remote host closed the connection]
mbuf has joined #ocaml
ziyourenxiang has quit [Ping timeout: 252 seconds]
argent_smith has quit [Quit: Leaving.]
sh0t has quit [Ping timeout: 248 seconds]
mbuf has quit [Remote host closed the connection]
mbuf has joined #ocaml
mbuf has quit [Quit: Leaving]
dtornabene has quit [Read error: Connection reset by peer]
JeanMax` has joined #ocaml
dtornabene has joined #ocaml
JeanMax has quit [Ping timeout: 258 seconds]
dtornabene_ has joined #ocaml
dtornabene has quit [Read error: Connection reset by peer]
Anarchos has joined #ocaml
andreas__ has quit [Quit: Connection closed for inactivity]
kakadu has quit [Quit: Konversation terminated!]
Anarchos has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
Anarchos has joined #ocaml
dedgrant has joined #ocaml
andreas__ has joined #ocaml
sh0t has joined #ocaml
noddy has quit [Ping timeout: 248 seconds]
govg has quit [Ping timeout: 240 seconds]
govg has joined #ocaml
govg has quit [Ping timeout: 260 seconds]
jao has joined #ocaml
sh0t has quit [Ping timeout: 255 seconds]
shinnya has joined #ocaml
Boomerang has joined #ocaml
KV has joined #ocaml
KV has quit [Client Quit]
kerrhau has joined #ocaml
kerrhau has joined #ocaml
kerrhau has quit [Changing host]
kakadu has joined #ocaml
samrat_ has quit [Ping timeout: 248 seconds]
kakadu has quit [Ping timeout: 252 seconds]
kakadu has joined #ocaml
Boomerang has quit [Quit: Lost terminal]
argent_smith has joined #ocaml
noddy has joined #ocaml
_andre has quit [Quit: leaving]
lgd__ has quit [Remote host closed the connection]
lgd__ has joined #ocaml
ygrek_ has joined #ocaml
mnemem has quit [Read error: Connection reset by peer]
mnemem has joined #ocaml
TheLemonMan has quit [Quit: "It's now safe to turn off your computer."]
enterprisey has joined #ocaml
JeanMax` has quit [Remote host closed the connection]
kakadu has quit [Read error: Connection reset by peer]
noddy has quit [Ping timeout: 240 seconds]
kakadu has joined #ocaml
wtetzner has joined #ocaml
mengu has joined #ocaml
Denommus has quit [Quit: going home]
wtetzner has quit [Ping timeout: 248 seconds]
wagle has quit [Read error: Connection reset by peer]
wagle has joined #ocaml
wtetzner has joined #ocaml
ygrek_ has quit [Ping timeout: 260 seconds]
pzp has quit [Quit: Connection closed for inactivity]
noddy has joined #ocaml
troydm has quit [Quit: What is Hope? That all of your wishes and all of your dreams come true? To turn back time because things were not supposed to happen like that (C) Rau Le Creuset]
AlexRussia has joined #ocaml
Anarchos has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
troydm has joined #ocaml
argent_smith has quit [Quit: Leaving.]
mnemem has quit [Read error: Connection reset by peer]
Anarchos has joined #ocaml
enterprisey has quit [Remote host closed the connection]
mnemem has joined #ocaml
<Anarchos> How can i specify to opam that merlin needs to link against an OS specific library ?
mnemem has quit [Ping timeout: 248 seconds]
Anarchos has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
enterprisey has joined #ocaml
lgd__ has quit [Remote host closed the connection]
lgd__ has joined #ocaml
mk9 has joined #ocaml
dhil has quit [Quit: Quit]
mk9 has quit [Client Quit]
mk9 has joined #ocaml
AlexRussia has quit [Quit: WeeChat 1.9.1]
pierpa has joined #ocaml
leah2 has quit [Ping timeout: 246 seconds]
leah2 has joined #ocaml
enterprisey has quit [Ping timeout: 260 seconds]
mk9_ has joined #ocaml
ziyourenxiang has joined #ocaml
mk9 has quit [Ping timeout: 248 seconds]
enterprisey has joined #ocaml
zolk3ri has quit [Remote host closed the connection]
enterprisey has quit [Ping timeout: 240 seconds]
mk9_ has quit [Quit: mk9_]
ygrek_ has joined #ocaml
sh0t has joined #ocaml
sh0t has quit [Remote host closed the connection]
sh0t has joined #ocaml
nullifidian__ has joined #ocaml
nullifidian_ has quit [Ping timeout: 240 seconds]
sh0t has quit [Remote host closed the connection]
sh0t has joined #ocaml
enterprisey has joined #ocaml
Soni has quit [Ping timeout: 258 seconds]
andreas__ has quit [Quit: Connection closed for inactivity]
al-damiri has quit [Quit: Connection closed for inactivity]
ygrek_ has quit [Ping timeout: 248 seconds]
Soni has joined #ocaml
dtornabene_ has quit [Quit: Leaving]