ChanServ changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml 4.02.1 announcement at http://ocaml.org/releases/4.02.html | Public channel logs at http://irclog.whitequark.org/ocaml
freling has quit [Client Quit]
rgrinberg has quit [Ping timeout: 256 seconds]
nicoo has quit [Ping timeout: 265 seconds]
xorpse has quit [Ping timeout: 246 seconds]
Nijikokun has quit [Read error: No route to host]
yminsky has joined #ocaml
TheLemonMan has quit [Quit: leaving]
nicoo has joined #ocaml
rwmjones has quit [Ping timeout: 245 seconds]
MrScout has joined #ocaml
MrScout has quit [Remote host closed the connection]
Hannibal_Smith has quit [Quit: Leaving]
thomasga has quit [Quit: Leaving.]
rwmjones has joined #ocaml
MrScout has joined #ocaml
thomasga has joined #ocaml
madroach has quit [Ping timeout: 264 seconds]
madroach has joined #ocaml
ghostpl_ has joined #ocaml
yminsky has quit [Quit: yminsky]
ghostpl_ has quit [Ping timeout: 245 seconds]
boogie has quit [Remote host closed the connection]
reem has quit [Remote host closed the connection]
shinnya has joined #ocaml
reem has joined #ocaml
MrScout has quit [Ping timeout: 265 seconds]
yminsky has joined #ocaml
thomasga has quit [Quit: Leaving.]
rgrinberg has joined #ocaml
steshaw has quit [Quit: Connection closed for inactivity]
rgrinberg has quit [Ping timeout: 252 seconds]
ygrek has joined #ocaml
<whitequark> any of you know a type system powerful enough to represent doubly linked lists?
Bhavya has quit [Quit: Quit the channel]
<bernardofpc> whitequark: perhaps Coq's is
<bernardofpc> but I'm unsure about your requirements "represent doubly linked list"
<whitequark> oh, right
<whitequark> memory safety
<bernardofpc> you consider OCaml's T.S. powerfull enough to represent a tree, I suppose ?
<whitequark> more like Rust's type system, and yes
<bernardofpc> my guess is that cpdt.pdf might have an answer for that
lordkryss has quit [Quit: Connection closed for inactivity]
<bernardofpc> maybe you can start with something like DCons : a -> (v, rv) -> (a :: v , snoc rv a) on the predicate that (rev v = rv)
<bernardofpc> moving a cursor on the list will transform it into (snoc v a, cons a rv) (if I made no mistakes)
<whitequark> hrm
<whitequark> is this like a zipper?
<bernardofpc> that's probably horribly slow, though
<bernardofpc> I don't know zippers :/
<dmbaturin> I read the zipper paper and didn't get it.
<dmbaturin> Maybe I should read it again.
ygrek has quit [Ping timeout: 252 seconds]
`eeks has joined #ocaml
shinnya has quit [Ping timeout: 264 seconds]
claudiuc has quit [Remote host closed the connection]
jwatzman|work has quit [Quit: jwatzman|work]
JuggleTux has quit [Ping timeout: 244 seconds]
JuggleTux has joined #ocaml
rgrinberg has joined #ocaml
antkong has quit [Read error: Connection reset by peer]
antkong has joined #ocaml
antkong has quit [Client Quit]
whitedawg has joined #ocaml
darkf has joined #ocaml
<bernardofpc> whitequark: a first approx could be the chapter 6 of cpdt.pdf
<bernardofpc> you can define left / right as functions taking and returning pairs of lists { l, rl | l = rev l}
<bernardofpc> there might be lots of proofs that everything goes ok along the way, but you should be safe
<whitequark> hmmmmm
badkins has quit []
ygrek has joined #ocaml
reem has quit [Remote host closed the connection]
mcclurmc has quit [Ping timeout: 255 seconds]
mcclurmc has joined #ocaml
ghostpl_ has joined #ocaml
`eeks has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
seangrove has quit [Ping timeout: 244 seconds]
reem has joined #ocaml
ghostpl_ has quit [Ping timeout: 264 seconds]
waneck has quit [Quit: Leaving]
yminsky has quit [Quit: yminsky]
enquora has quit [Quit: enquora]
reem has quit [Remote host closed the connection]
ericwa has quit [Quit: Leaving...]
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
kapil___ has joined #ocaml
keen__________84 has joined #ocaml
keen__________83 has quit [Ping timeout: 246 seconds]
mcclurmc has quit []
<scythe-> um
<scythe-> ocamlfind hates me
<scythe-> ocamlfind is installed as a dependency of camlp4
<scythe-> despite this ocamlfind inevitably insists that it cannot find camlp4
<scythe-> for strange reasons
mcclurmc has joined #ocaml
<scythe-> seriously this is ridiculous
<tcpc> use opam
<tcpc> misreading, sorry
<tcpc> scythe-: did you check the versions? (maybe ocamlfind 1.X is installed as a dependency of camlp4 1.X' and ocamlfind 1.Y doesn't find camlp4 1.Y')
<scythe-> no
<scythe-> i literally typed "opam install camlp4" three seconds before "ocamlfind query camlp4"
<scythe-> explain
<whitequark> did you do eval `opam config env`
ghostpl_ has joined #ocaml
<scythe-> whitequark: thank you :D
<whitequark> ✔ troubleshooting via telepathy
ghostpl_ has quit [Ping timeout: 250 seconds]
Bhavya has joined #ocaml
nullcat_ has joined #ocaml
matason_ has joined #ocaml
rgrinberg1 has joined #ocaml
pgas` has joined #ocaml
hannes` has joined #ocaml
ski_ has joined #ocaml
govg_ has joined #ocaml
cthuluh_ has joined #ocaml
martintrojer_ has joined #ocaml
hnrgrgr_ has joined #ocaml
adrien_ has joined #ocaml
hannes has quit [Read error: Connection reset by peer]
govg has quit [Ping timeout: 245 seconds]
ski has quit [Ping timeout: 245 seconds]
osheeta has quit [Ping timeout: 245 seconds]
pgas has quit [Ping timeout: 245 seconds]
hnrgrgr has quit [Read error: Connection reset by peer]
ousado has quit [Read error: Connection reset by peer]
matason has quit [Ping timeout: 240 seconds]
The_Mad_Pirate has quit [Excess Flood]
martintrojer has quit [Ping timeout: 240 seconds]
Snark has joined #ocaml
osheeta_ has joined #ocaml
Snark has quit [Ping timeout: 240 seconds]
rgrinberg has quit [Ping timeout: 240 seconds]
_5kg has quit [Ping timeout: 240 seconds]
cthuluh has quit [Ping timeout: 240 seconds]
adrien has quit [Read error: Connection reset by peer]
ousado has joined #ocaml
cdidd has quit [Ping timeout: 245 seconds]
AlexRussia has quit [Ping timeout: 240 seconds]
cdidd has joined #ocaml
_5kg has joined #ocaml
AlexRussia has joined #ocaml
ygrek has quit [Ping timeout: 252 seconds]
badon has quit [Read error: Connection reset by peer]
badon has joined #ocaml
<Drup> whitequark: it's very satisfying, isn't it ? :)
seliopou has quit [Ping timeout: 264 seconds]
dav has quit [Ping timeout: 265 seconds]
dav has joined #ocaml
rgrinberg1 has quit [Ping timeout: 252 seconds]
seliopou has joined #ocaml
rgrinberg1 has joined #ocaml
sgnb` has quit [Read error: No route to host]
adrien_ is now known as adrien
marynate has joined #ocaml
JuggleTux has quit [Ping timeout: 246 seconds]
pgas` is now known as pgas
govg_ has quit [Quit: leaving]
govg has joined #ocaml
olibjerd has quit [Ping timeout: 250 seconds]
ygrek has joined #ocaml
matason_ has quit [Quit: Later!]
marynate has quit [Read error: Connection reset by peer]
marynate has joined #ocaml
marynate has quit [Ping timeout: 255 seconds]
whitedawg1 has joined #ocaml
whitedawg has quit [Ping timeout: 246 seconds]
AlexRussia has quit [Ping timeout: 245 seconds]
ggole has joined #ocaml
Haudegen has quit [Ping timeout: 265 seconds]
larhat has quit [Quit: Leaving.]
moei has joined #ocaml
matason has joined #ocaml
Haudegen has joined #ocaml
AlexRussia has joined #ocaml
regnat has joined #ocaml
ghostpl_ has joined #ocaml
matason has quit [Quit: Leaving...]
ghostpl_ has quit [Ping timeout: 265 seconds]
prsn has quit [Ping timeout: 252 seconds]
matason has joined #ocaml
govg has quit [Quit: leaving]
keen__________84 has quit [Read error: Connection reset by peer]
reem has joined #ocaml
keen__________84 has joined #ocaml
Simn has joined #ocaml
darkf has quit [Read error: Connection reset by peer]
darkf has joined #ocaml
olibjerd has joined #ocaml
psy_ has quit [Ping timeout: 252 seconds]
reem has quit [Remote host closed the connection]
reem has joined #ocaml
ia0 has quit [Quit: leaving]
ia0 has joined #ocaml
struktured has quit [Ping timeout: 256 seconds]
olibjerd has quit [Ping timeout: 272 seconds]
ghostpl_ has joined #ocaml
maufred has quit [Ping timeout: 246 seconds]
dsheets has quit [Ping timeout: 255 seconds]
maufred has joined #ocaml
rgrinberg1 has quit [Ping timeout: 240 seconds]
whitedawg has joined #ocaml
whitedawg1 has quit [Ping timeout: 256 seconds]
ghostpl_ has quit [Ping timeout: 272 seconds]
prsn has joined #ocaml
maufred has quit [Ping timeout: 244 seconds]
kakadu has joined #ocaml
maufred has joined #ocaml
avsm has joined #ocaml
avsm1 has joined #ocaml
Bhavya has quit [Quit: Quit the channel]
madroach has quit [Ping timeout: 264 seconds]
JuggleTux has joined #ocaml
avsm has quit [Ping timeout: 256 seconds]
madroach has joined #ocaml
xificurC has joined #ocaml
reem has quit [Remote host closed the connection]
octachron has joined #ocaml
reem has joined #ocaml
Bhavya has joined #ocaml
prsn has quit [Ping timeout: 252 seconds]
prsn has joined #ocaml
nullcat_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
zpe has joined #ocaml
regnat has quit [Quit: WeeChat 1.0.1]
Algebr has joined #ocaml
<Algebr> Are strings the only object that uses/gets the [] notation?
<companion_cube> yes
<companion_cube> you mean .[i] ?
<Algebr> yea
<Algebr> it seems to me a little inconsistent, why isn't it .()? and why make only strings get .[]
<companion_cube> again, I think it's for type inference purpose
prsn has quit [Ping timeout: 256 seconds]
<ia0> I think so too
<ia0> this is the same reason than for + and +.
<ia0> with typeclasses you don't have the problem anymore
prsn has joined #ocaml
<ia0> you just abstract over what you mean until some constraint appear
ghostpl_ has joined #ocaml
<companion_cube> well, with typeclasses you still have only one + or [] operator, only it's parametrized by the real implementation (the typeclass)
<Algebr> How do you get the top level to dump its search path?
olibjerd has joined #ocaml
rgrinberg1 has joined #ocaml
The_Mad_Pirate has joined #ocaml
rgrinberg1 has quit [Ping timeout: 245 seconds]
whitedawg has quit [Quit: Leaving.]
larhat has joined #ocaml
prsn has quit [Ping timeout: 246 seconds]
<ia0> companion_cube> well, with typeclasses you still have only one + or [] operator, <= yes, "the problem" was to have several + and [] operator
prsn has joined #ocaml
ousado has quit [Changing host]
ousado has joined #ocaml
aubergines has joined #ocaml
psy_ has joined #ocaml
reem has quit [Remote host closed the connection]
psy_ has quit [Max SendQ exceeded]
psy_ has joined #ocaml
fedjo has quit [Read error: Connection reset by peer]
fedjo has joined #ocaml
<Algebr> Is ocamlnet like the definitive set of packages related to web stuff?
<MercurialAlchemi> depends what you want to do
axiles has quit [Ping timeout: 255 seconds]
<MercurialAlchemi> people tend to like cohttp more if they need an http client or server, I think
axiles has joined #ocaml
fedjo has quit [Ping timeout: 246 seconds]
prsn has quit [Ping timeout: 245 seconds]
prsn has joined #ocaml
dsheets has joined #ocaml
Haudegen has quit [Ping timeout: 256 seconds]
AlexRussia has quit [Ping timeout: 252 seconds]
avsm1 has quit [Quit: Leaving.]
The_Mad_Pirate has quit [Quit: Konversation terminated!]
dsheets has quit [Quit: Leaving]
dsheets has joined #ocaml
Haudegen has joined #ocaml
_5kg has quit [Ping timeout: 265 seconds]
mort___ has joined #ocaml
The_Mad_Pirate has joined #ocaml
prsn has quit [Ping timeout: 252 seconds]
prsn has joined #ocaml
olibjerd has quit [Quit: Ex-Chat]
sdothum has joined #ocaml
prsn has quit [Ping timeout: 252 seconds]
prsn has joined #ocaml
<tobiasBora> Hello
freling has joined #ocaml
tane has joined #ocaml
prsn has quit [Ping timeout: 250 seconds]
prsn has joined #ocaml
_5kg has joined #ocaml
ygrek has quit [Ping timeout: 264 seconds]
badon has quit [Disconnected by services]
badon_ has joined #ocaml
badon_ is now known as badon
_andre has joined #ocaml
fraggle-boate has joined #ocaml
rgrinberg1 has joined #ocaml
prsn has quit [Ping timeout: 240 seconds]
prsn has joined #ocaml
rgrinberg1 has quit [Ping timeout: 264 seconds]
rand000 has joined #ocaml
lordkryss has joined #ocaml
struktured has joined #ocaml
Bhavya has quit [Quit: Quit the channel]
tane has quit [Quit: Verlassend]
prsn has quit [Ping timeout: 256 seconds]
prsn has joined #ocaml
cthuluh_ is now known as cthuluh
prsn has quit [Ping timeout: 264 seconds]
rand000 has quit [Quit: leaving]
prsn has joined #ocaml
larhat1 has joined #ocaml
yomimono has joined #ocaml
larhat has quit [Ping timeout: 244 seconds]
<reynir> opam doesn't support ocaml 3.11.2 :(
Algebr has quit [Ping timeout: 252 seconds]
prsn has quit [Ping timeout: 264 seconds]
prsn has joined #ocaml
axiles has quit [Ping timeout: 264 seconds]
<flux> ..it's 7 years old..
ski_ is now known as ski
<reynir> unfortunately that's the version in the repos on solaris 11 :/
<flux> compile a newer one?
rgrinberg1 has joined #ocaml
axiles has joined #ocaml
thomasga has joined #ocaml
<dmbaturin> Solaris 11 is less than seven years old, I wonder why would they use 3.12. Which repo are you talking about, by the way? Blastwave or something else?
badkins has joined #ocaml
rgrinberg1 has quit [Ping timeout: 245 seconds]
tane has joined #ocaml
AlexRussia has joined #ocaml
prsn has quit [Ping timeout: 252 seconds]
prsn has joined #ocaml
avsm has joined #ocaml
avsm1 has joined #ocaml
ptc has joined #ocaml
ptc is now known as Guest60404
Guest60404 has quit [Client Quit]
avsm has quit [Ping timeout: 252 seconds]
<Drup> dmbaturin: 3.12 would be fine, it's 3.11 !
<adrien_znc> hipster
brendan has quit [Remote host closed the connection]
<dmbaturin> Drup: Yeah, a typo. "Solaris 12" typo would be funny at least.
prsn has quit [Ping timeout: 252 seconds]
fraggle_ has quit [Read error: Connection reset by peer]
prsn has joined #ocaml
shinnya has joined #ocaml
<reynir> does opam expect make to be gnu make?
<avsm1> reynir: on *BSD, it rewrites `make` to be `gmake`
<avsm1> thats why make isn't quoted in the build rules (its a macro)
enquora has joined #ocaml
fraggle_ has joined #ocaml
mcclurmc has quit [Remote host closed the connection]
mcclurmc has joined #ocaml
ptc_ has joined #ocaml
prsn has quit [Ping timeout: 256 seconds]
prsn has joined #ocaml
maufred has quit [Read error: Connection reset by peer]
ptc_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ptc_ has joined #ocaml
Submarine has joined #ocaml
Submarine has joined #ocaml
prsn has quit [Ping timeout: 264 seconds]
prsn has joined #ocaml
darkf has quit [Quit: Leaving]
planetlarg has joined #ocaml
maufred has joined #ocaml
shinnya has quit [Ping timeout: 256 seconds]
boadie has joined #ocaml
hannes` is now known as hannes
prsn has quit [Ping timeout: 246 seconds]
prsn has joined #ocaml
|jbrown| has joined #ocaml
maufred has quit [Ping timeout: 245 seconds]
maufred has joined #ocaml
iorivur has joined #ocaml
avsm1 has quit [Read error: Connection reset by peer]
boadie has quit [Remote host closed the connection]
avsm has joined #ocaml
maufred has quit [Ping timeout: 246 seconds]
maufred has joined #ocaml
prsn has quit [Ping timeout: 245 seconds]
rgrinberg1 has joined #ocaml
prsn has joined #ocaml
rgrinberg1 has quit [Ping timeout: 264 seconds]
uris77 has joined #ocaml
thomasga has quit [Quit: Leaving.]
prsn has quit [Ping timeout: 246 seconds]
prsn has joined #ocaml
avsm has quit [Quit: Leaving.]
struktured has quit [Ping timeout: 256 seconds]
thomasga has joined #ocaml
uris77 has quit [Quit: leaving]
TheLemonMan has joined #ocaml
ptc_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
prsn has quit [Ping timeout: 246 seconds]
yminsky has joined #ocaml
seangrove has joined #ocaml
prsn has joined #ocaml
ptc has joined #ocaml
ptc is now known as Guest72175
boogie has joined #ocaml
yminsky has quit [Ping timeout: 256 seconds]
madroach has quit [Ping timeout: 264 seconds]
MrScout has joined #ocaml
madroach has joined #ocaml
MrScout has quit [Remote host closed the connection]
MrScout has joined #ocaml
rgrinberg1 has joined #ocaml
MrScout has quit [Quit: Leaving...]
prsn has quit [Ping timeout: 255 seconds]
prsn has joined #ocaml
planetlarg has quit [Quit: Ex-Chat]
octachron has quit [Quit: Leaving]
avsm has joined #ocaml
Submarine has quit [Remote host closed the connection]
TheLemonMan has quit [Quit: leaving]
avsm has quit [Quit: Leaving.]
slash^ has joined #ocaml
prsn has quit [Ping timeout: 250 seconds]
prsn has joined #ocaml
<tobiasBora> I have a question about mli files.
maufred has quit [Ping timeout: 246 seconds]
Guest72175 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
|jbrown| has quit [Ping timeout: 252 seconds]
<tobiasBora> Is there a way to put comment in the .ml to auto generate the .mli file ?
<tobiasBora> Here is my problem :
maufred has joined #ocaml
<tobiasBora> When I code, I usually put the comments in the .ml file. However when I generate the .mli they are lost.
mort___ has quit [Ping timeout: 265 seconds]
<tobiasBora> That's why each type I regerate a .mli I need to manually add all the comments, and it's really not practicall.
<tobiasBora> There is another way that I could use, which is to add during the coding the functions in the interface file .mli
<tane> you usually write the mli files yourself
<tane> and just put the comments in there
<tobiasBora> but the problem is that often I change functions, add others one... And I often miss one or more functions
<pippijn> tobiasBora: your mli file contains API documentation
<tane> well, this is a development process then
<pippijn> tobiasBora: your ml file contains implementation notes
<tane> why do you need documentation meanwhile?
<tane> if you cannot define a api in a mli, there is no sense for an api documentation
<tobiasBora> tane: I need documentation because I want to publish my code ^^
<tane> tobiasBora, then do so, when it's stable
<tane> i.e. changes to MLI are acceptable for you, if you change your api, you can change the MLI or add stuff to it
iorivur has quit [Quit: No Ping reply in 180 seconds.]
iorivur has joined #ocaml
<tobiasBora> I see... Well if the only solution I will do that stuff, but a way to put everything in a single file that automately generate the .mli would be more practicall...
<tane> not really
<tane> autogenerated MLI's are worth no extra information
<tane> you could look into the ML anyway
<tobiasBora> They are clearer
<tobiasBora> for a user
<tane> because every function is part of the interface, so there is no way to look at any function that wasn't exposed
<tane> that may be, yes
<tobiasBora> Well a well done tools whould add a way to hide a function, for example by using an annotation... Or put in the .mli only functions that are commented.
<tobiasBora> For example if I do :
<tane> convention over configuration? :)
<tobiasBora> let mysecret_function a = a + 5
<tobiasBora> it's not exported in the .mli
prsn has quit [Ping timeout: 252 seconds]
<tobiasBora> but :
<tobiasBora> (** Here is some doc *)
<tobiasBora> let mypublicfunction a = a + 6
<tobiasBora> would be exported
<tobiasBora> tane: When the convention isn't restrictive I don't see any problem for that...
<tane> yeah, should be possible to build such tools, but i know of none so far
prsn has joined #ocaml
olauzon has joined #ocaml
<tobiasBora> Ok, maybe an idea for a later project... Thank you !
<tane> yeah, good idea :)
thomasga has quit [Quit: Leaving.]
thomasga has joined #ocaml
`eeks has joined #ocaml
`eeks has quit [Read error: Connection reset by peer]
`eeks has joined #ocaml
lordkryss has quit [Quit: Connection closed for inactivity]
<_obad_> in opam, is there a single command to remove a given package and install another one? (so that it doesn't recompile things twice)
prsn has quit [Ping timeout: 244 seconds]
lordkryss has joined #ocaml
ptc has joined #ocaml
ptc is now known as Guest42127
rand000 has joined #ocaml
prsn has joined #ocaml
thomasga has quit [Quit: Leaving.]
avsm has joined #ocaml
avsm1 has joined #ocaml
avsm has quit [Read error: Connection reset by peer]
martintrojer_ has quit [Quit: ZNC - 1.6.0 - http://znc.in]
brendan has joined #ocaml
WraithM has joined #ocaml
martintrojer has joined #ocaml
thomasga has joined #ocaml
AlexRussia has quit [Ping timeout: 255 seconds]
sepp2k has joined #ocaml
<_andre> does anyone know why i'd get an "undefined symbol: caml_c_thread_unregister" error loading a C extension?
<smondet> _andre: "loading" you mean in the toplevel?
<_andre> yeah
prsn has quit [Ping timeout: 256 seconds]
<smondet> _andre: try `#thread;;` before loading?
<_andre> duh
<_andre> thanks
zpe has quit [Remote host closed the connection]
prsn has joined #ocaml
<_andre> completely forgot about #thread
<smondet> it worked?
<_andre> yeah
<smondet> cool
<_andre> a few months without using the language and you forget this kind of things :\
MrScout_ has joined #ocaml
<mrvn> Don't use Weak.t to store your knowledge
<_andre> :P
<_andre> it feels like i'm using a circular buffer
<Drup> _obad_: nope, no such thing
jwatzman|work has joined #ocaml
jwatzman|work has quit [Client Quit]
jwatzman|work has joined #ocaml
MrScout_ has quit [Read error: Connection reset by peer]
<haesbaert> if I got this right: Lwt.choose returns "the return" of the first Lwt that exits
<haesbaert> is there a way to get the "Lwt" instead of the value returned by that Lwt ?
ghostpl_ has quit [Remote host closed the connection]
MrScout_ has joined #ocaml
MrScout_ has quit [Remote host closed the connection]
<Drup> since it's a finished thread, why do you care ?
<haesbaert> say: let t1 = t1_bla () in let t2 = t2_bla () in let t_finished = Lwt.choose [ t1; t2 ] >>=... if t1 = finished
<haesbaert> because I want to do some cleanup depending on the thread that exists
<haesbaert> *exits
<haesbaert> something like this
<haesbaert> obviously finished would have to be bound before
MrScout_ has joined #ocaml
<haesbaert> I mean I can change the threads to return something and then compare on the something, but seems artificial
<haesbaert> now they return unit
<haesbaert> Lwt unit it is
<Drup> you should call Lwt.finalize for doing things like that
AlexRussia has joined #ocaml
<haesbaert> but doesn't that interfere with the GC ?
<haesbaert> I mean, won't the finalize only run when that blocks are collected /
<haesbaert> ?
yomimono has quit [Ping timeout: 256 seconds]
<Drup> No, that's not the semantic of finalize
<Drup> it's Lwt.finalize, not Gc.finalize ;)
<Drup> > finalize f g returns the same result as f () whether it fails or not. In both cases, g () is executed after f.
<haesbaert> I see, but isn't Lwt.finalize just a co-operative wrapper for Gc.finalize
<Drup> n o
<Drup> No.*
<haesbaert> awesome then,
<haesbaert> will use that
prsn has quit [Ping timeout: 240 seconds]
prsn has joined #ocaml
Submarine has joined #ocaml
Submarine has joined #ocaml
<haesbaert> omg it works
<haesbaert> Drup: thanks !
govg has joined #ocaml
aubergines has quit [Quit: leaving]
govg has quit [Ping timeout: 264 seconds]
govg_ has joined #ocaml
prsn has quit [Ping timeout: 256 seconds]
prsn has joined #ocaml
slash^ has quit [Read error: Connection reset by peer]
larhat1 has quit [Quit: Leaving.]
zpe has joined #ocaml
<_obad_> drup: thanks. ended up recompiling a bunch of times anyway
tani has joined #ocaml
dhil has joined #ocaml
tane has quit [Ping timeout: 245 seconds]
prsn has quit [Ping timeout: 272 seconds]
ggole has quit [Ping timeout: 245 seconds]
prsn has joined #ocaml
kmicinski has joined #ocaml
thomasga has quit [Ping timeout: 252 seconds]
<kmicinski> Hi all, I am wondering how I can diagnose a problem from a package I've installed that sends incorrect flags to ocamlopt through ocamlbuild.
<kmicinski> When I do an `ocamlbuild -pkg z3 main.native`
<kmicinski> ocamlopt is called with '-cclib -lz3'
<kmicinski> rather than -cclib -lz3
<kmicinski> the quotes mess up ocamlopt
kakadu has quit [Quit: Page closed]
<kmicinski> I'm not sure what to change, I looked at the META information in the Z3 distribution that I was building and it had what I think is right: linkopts = "-cclib -lz3"
<kmicinski> but those end up being malformed when passed to ocamlopt, can someone point me at the right place to diagnose this?
<Drup> are you sure this is really the issue ?
<Drup> you are using z3's own ocamlfind_install target, right ?
<kmicinski> yes, Iam
<kmicinski> (using that target)
<kmicinski> but I am not sure that's the problem
<kmicinski> I ran ocamlopt without the quotes and it worked
<kmicinski> adding the quotes messes it up
<Drup> I had no issue with this install
<Drup> well, no issue, that's a bit far fetched
<Drup> not the issue you are describing, at least.
<kmicinski> So, when I comment out `linkopts` in the META file, it *works*, for a small project
<kmicinski> I'll try a larger projet that actually uses Z3 and see if it throws a runtime error...
<kmicinski> I guess I could just check out your z3 API and build it to test it : )
<Drup> yes, and try the tests too
<Drup> because it would not actually try to link otherwise
<kmicinski> Hm, but doing so requires a decent amount of work getting your repo to install
<Drup> (most of the issues I had with z3's ocamlfind_install where at link time, but they *should* be solved by now)
<Drup> decent amount of work ?
<Drup> you don't need my custom z3
<Drup> it's optional
<Drup> and disable by default
<kmicinski> ah, okay, I was confused by the message in the README that says "you still need to compile and install the fork of z3 on your system."
kmicinski has quit [Quit: Lost terminal]
prsn has quit [Ping timeout: 264 seconds]
prsn has joined #ocaml
freling has quit [Quit: Leaving.]
ghostpl_ has joined #ocaml
Guest42127 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
prsn has quit [Ping timeout: 244 seconds]
ptc has joined #ocaml
ptc is now known as Guest15301
prsn has joined #ocaml
axiles has quit [Ping timeout: 245 seconds]
axiles has joined #ocaml
zpe has quit [Remote host closed the connection]
lordkryss has quit [Quit: Connection closed for inactivity]
kmicinski has joined #ocaml
kakadu has joined #ocaml
prsn has quit [Ping timeout: 245 seconds]
prsn has joined #ocaml
MrScout_ has quit [Ping timeout: 256 seconds]
Anarchos has joined #ocaml
Denommus has joined #ocaml
<Anarchos> why does coq have its own instance of the ocaml virtual machine ?
<struk|work> smondet: do I need git://github.com/smondet/atd2cconv to compile latest ketrew?
MrScout_ has joined #ocaml
<smondet> struk|work: yes, to compile master you need the `-sort` option of atd2cconv
<smondet> whichnot released
<smondet> *is
<struk|work> smondet: ok
Anarchos has quit [Ping timeout: 264 seconds]
prsn has quit [Ping timeout: 272 seconds]
prsn has joined #ocaml
<whitequark> the PR which m17n was depending on got merged
<whitequark> now it just requires trunk https://github.com/whitequark/ocaml-m17n#installation
MrScout_ has quit [Remote host closed the connection]
TheLemonMan has joined #ocaml
kmicinski has quit [Ping timeout: 245 seconds]
MrScout_ has joined #ocaml
matason has quit [Quit: Leaving...]
WraithM has quit [Quit: leaving]
MrScout_ has quit [Remote host closed the connection]
prsn has quit [Ping timeout: 256 seconds]
prsn has joined #ocaml
h0ffline has joined #ocaml
<h0ffline> hey, im just learning ocaml and would like some help with a problme im having.
<companion_cube> please ask the question, not the permission
<companion_cube> :)
<reynir> what if they want to know what permissions to run ocaml under ;)
<h0ffline> im not sure what is wrong with this code
<reynir> that was a bad joke
_andre has quit [Quit: leaving]
<h0ffline> but it keeps saying there is a syntax error when i use ;; to end the function
<companion_cube> ok, the problem is you write let a = b; rather than let a = b in
<adrien> let a = b in ........
Anarchos has joined #ocaml
<h0ffline> companion_cube, was that a joke?
<h0ffline> or am i not reading the same code you are?
<TheLemonMan> read the trailing ; as in ()
<h0ffline> oh
<struk|work> smondet: another build question...is there a "make" command that installs trakeva?
<h0ffline> so i remove the semicolons?
<companion_cube> you replace the ";" with "in"
<companion_cube> let x= 1 in let y = 2 in x+y
<h0ffline> thanks that works, but i have no idea why, is there a good resource to read about that or is it just part of the syntax that i missed
<companion_cube> it's the normal syntax
<h0ffline> okay, thanks
<companion_cube> ";" is only a specific operator to evaluate expressions sequentiall
<companion_cube> y
prsn has quit [Ping timeout: 252 seconds]
prsn has joined #ocaml
claudiuc has joined #ocaml
claudiuc has quit [Remote host closed the connection]
claudiuc has joined #ocaml
badon has quit [Quit: Leaving]
ericwa has joined #ocaml
<smondet> struk|work: you're not using opam?
Guest15301 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
badon has joined #ocaml
<smondet> struk|work: you may need https://github.com/smondet/dev-opam-repo
prsn has quit [Ping timeout: 252 seconds]
<struk|work> smondet: ok will try that thanks
prsn has joined #ocaml
ptc has joined #ocaml
ptc is now known as Guest3513
MrScout_ has joined #ocaml
boogie has quit [Read error: Connection reset by peer]
boogie has joined #ocaml
reem has joined #ocaml
ghostpl_ has quit [Remote host closed the connection]
prsn has quit [Ping timeout: 256 seconds]
freling has joined #ocaml
reem has quit [Remote host closed the connection]
prsn has joined #ocaml
kmicinski has joined #ocaml
ghostpl_ has joined #ocaml
freling has quit [Quit: Leaving.]
kmicinski has quit [Ping timeout: 245 seconds]
ghostpl_ has quit [Ping timeout: 252 seconds]
<Denommus> hah, strict evaluation just hit me in the face XD
reem has joined #ocaml
<Denommus> I was trying to emulate Haskell's "maybe" (the function, not the type) with 'a -> ('b -> 'a) -> 'b option -> 'a
* Drup slaps Denommus with a strict evaluation.
<Denommus> but I forgot the first parameter was strictly evaluated unlike in Haskell, and I should have done (unit -> 'a) instead
<Denommus> I ended up just using match XD
<Drup> that's why you usually have both in libraries
<Denommus> I have not been using any library, except Str
prsn has quit [Ping timeout: 252 seconds]
`eeks has quit [Quit: Textual IRC Client: www.textualapp.com]
prsn has joined #ocaml
sepp2k has quit [Quit: Konversation terminated!]
dav has quit [Ping timeout: 255 seconds]
<Anarchos> Denommus did'nt you use 'a lazy ?
<Denommus> Anarchos: which library is that?
<Anarchos> Denommus Pervasives one i guess.
<Anarchos> let a = lazy 1;; val a : int lazy_t = lazy 1
freling has joined #ocaml
dav has joined #ocaml
olauzon has quit [Quit: olauzon]
<dmbaturin> If I want to modify some global state in response to requests, can I do it from Lwt callbacks?
seangrove has quit [Remote host closed the connection]
<Denommus> Anarchos: ah, it's lazy_t
<Denommus> Anarchos: but just using match is simpler ;-)
prsn has quit [Ping timeout: 246 seconds]
<Anarchos> Denommus match ? But your arg will be evaluate unless you use a lazy value, ?
prsn has joined #ocaml
pyon has quit [Quit: I'm sorry but... I don't have any interest in three-dimensional girls.]
<Denommus> Anarchos: match... is conditional. It won't enter in the branch unless it matches correctly
<smondet> dmbaturin: not sure I get your question, but yes, the idea of cooperative threads is to be able to mutate global state without caring too much
<Anarchos> Denommus i thought you didn't want to evaluate the first 'a argument
kakadu has quit [Remote host closed the connection]
<dmbaturin> smondet: Well, a toy example of what I want to do is a program that keep a top level int ref and allows network clients to update its contents.
<smondet> dmbaturin: then yes `my_ref := ...` or `incr my_ref` won't be preempted by Lwt threads (but if `Lwt_preemptive` thread touches `my_ref` then you break the assumption of course)
jwatzman|work has quit [Quit: jwatzman|work]
reem has quit [Remote host closed the connection]
<dmbaturin> smondet: An, I was thinking exactly about the cooperative. On the other hand, is it a good idea to spawn a cooperative thread when new connection is received and pass the file descriptor to it?
<Denommus> Anarchos: no, I mean I replaced the whole function by a match
freling has quit [Quit: Leaving.]
Guest3513 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Denommus> Anarchos: like, instead of calling option bar baz blah, I know only do match blah with ...
myst has quit [Disconnected by services]
myst has joined #ocaml
prsn has quit [Ping timeout: 264 seconds]
prsn has joined #ocaml
ptc has joined #ocaml
ptc is now known as Guest82053
MrScout_ has quit [Remote host closed the connection]
<Anarchos> Denommus sounds right too. Good luck for yoru dev !
reem has joined #ocaml
xificurC has quit [Ping timeout: 256 seconds]
<Denommus> Anarchos: I'm considering OCaml for Google Code Jam, so I'm practicing with it
MrScout_ has joined #ocaml
ghostpl_ has joined #ocaml
reem has quit [Remote host closed the connection]
<smondet> dmbaturin: Lwt threads a very light, negligible compared to IO, so yes use them at will (as long as you don't run something "long" with yielding; that will block the other threads)
<smondet> s/with/without/
<Denommus> Anarchos: ah, and thanks
freling has joined #ocaml
<Anarchos> Denommus i am happy if i could help you !
pyon has joined #ocaml
ghostpl_ has quit [Ping timeout: 255 seconds]
prsn has quit [Ping timeout: 264 seconds]
freling has quit [Quit: Leaving.]
prsn has joined #ocaml
sdegutis has joined #ocaml
<sdegutis> Still on the fence of Haskell vs OCaml, after using both. Help.
<TheLemonMan> why not both ?
freling has joined #ocaml
<dmbaturin> sdegutis: Write in Coq, it can produce both ocaml and haskell.
<Drup> sdegutis: rust didn't made the cut ?
<dmbaturin> smondet: Thanks, going to make a toy prototype and see how it works.
reem has joined #ocaml
<companion_cube> sdegutis: to write what, exactly?
<sdegutis> TheLemonMan: I want to have only one favorite language in the same competing arena.
<sdegutis> dmbaturin: if it can seriously do that, that's neat
<sdegutis> Drup: Rust doesn't allow me to abandon low-level concerns when I don't want/need them, which is a big downside for when I want to entirely write in high-level code
<sdegutis> companion_cube: a large web app
tani has quit [Quit: Verlassend]
<Drup> sdegutis: client code or not ?
<whitequark> writing a "large" web app as your first project in a language is probably unwise, especially if said language doesn't have a mature web framework
reem has quit [Remote host closed the connection]
<Drup> I was going to get offended, just for show, about eliom's maturity, but really I don't need too. x)
<Anarchos> why max_int+1 doesn't raise an exception
<sdegutis> Drup: wha do you mean?
<sdegutis> whitequark: good point thanks
<Drup> it depends what you mean by "mature"
<whitequark> Anarchos: because in 1986 people thought overflow checking is slow
<sdegutis> tokenrove: thanks for the advice in PM about Ur and Ur/Web
<Drup> yeah, no, screw Ur/Web
<whitequark> what about ur/web?
<tokenrove> i mentioned ur/web to him, in a privmsg because i feel it's off-topic for #ocaml
<whitequark> i mean to Drup
<Drup> it gets lot of mention in various circles, but it not nearly as innovating and/or fabulous at the praise it recieve.
<Drup> whitequark: it's eliom, in a stand alone language, without FFI and without client values
<Drup> and without documentation
<smondet> Anarchos: the type `int` officially represents integers modulo `max_int`
<Drup> but it got a paper in POPL, so, there is that.
<tokenrove> the documentation isn't complete, but it's not bad
rgrinberg1 has quit [Ping timeout: 255 seconds]
<Drup> (I'm still wondering how it got accepted, there is literally no innovation in this paper, but that's another subject)
<dmbaturin> What is a web framework doing in POPL?
axiles has quit [Ping timeout: 240 seconds]
<Drup> tokenrove: "empty", not "incomplete"
<smondet> Ur/Web is both a language and framework
prsn has quit [Ping timeout: 272 seconds]
<Drup> the mention "...and more to come!" is there since *at least* a year, if not more.
reem has joined #ocaml
<Drup> so, nope, sorry. You can even use J2EE if you want, there are at least some reasons to do so (easy to find devs), but Ur/Web, literally no good reasons.
prsn has joined #ocaml
reem has quit [Remote host closed the connection]
<Drup> (well, that's my personal opinon, you can do whatever you want of course ~~)
<sdegutis> :)
<sdegutis> Thanks everyone for your feedback.
<Drup> sdegutis: the two big frameworks in ocaml/haskell respectivelly are http://www.yesodweb.com/ and http://ocsigen.org/ (there are other, smaller, obviously). yesod is server only, ocsigen is both
<Drup> (the current situation for client-side Haskell is currently quite confused)
<sdegutis> I think I've made my decision.
<Drup> tokenrove: sorry for the strong reaction. ;)
<smondet> Drup: the thing that annoys me the most about Ur/Web is that it diverts Adam from doing all his other much cooler stuff (Bedrock, CPDT, ...) :D
<Drup> I literally know nothing about the rest.
<Drup> what is it ?
<smondet> mostly Coq
<Drup> amusing
<smondet> in a "future of real-world engineering" way
<cojy_> what do you guys dislike about Ur/Web
<dmbaturin> Wait, you mean Adam Chlipala?
<tokenrove> Drup: it's okay. i actually had specifically tried to avoid mentioning it here at all. but fwiw, i am using it on some things and am pretty happy with it so far.
<cojy_> yea dmbaturin
<dmbaturin> I wouldn't imagine him making a web framework. :)
reem has joined #ocaml
<smondet> I think initially it was a startup idea
<cojy_> if he had someone else to invest effort into a few more practical things it was missing it'd be a pretty serious force
<Drup> cojy_: I sort of answered, no ?
<Drup> the simple fact that it's a new language is sort of a deal breaker for me.
<tokenrove> it seems to me like the ocaml web ecosystem is really active, though, which is great
<cojy_> Drup: "Ur/Web, literally no good reasons." thats all i saw, no actual negatives
reem has quit [Remote host closed the connection]
<cojy_> idk i can see taht but its also way nicer
<cojy_> i always dread the lack of it's records when going back to ocaml
<Drup> cojy_: it's a very good research language, literally no argument there :)
<TheLemonMan> are there any {re,de}cent opengl bindings ?
<Drup> cojy_: and mostly it's not "it's bad", it's rather "there are better options"
reem has joined #ocaml
jwatzman|work has joined #ocaml
<cojy_> they dont actually match in security though do they? it seems more like "different options"
jwatzman|work has quit [Read error: Connection reset by peer]
jwatzman|work has joined #ocaml
jwatzman|work has quit [Client Quit]
prsn has quit [Ping timeout: 252 seconds]
<tokenrove> TheLemonMan: i like tgls: https://github.com/dbuenzli/tgls
<smondet> TheLemonMan: and js_of_ocaml has binding to WebGL also
prsn has joined #ocaml
reem has quit [Remote host closed the connection]
<Drup> define "security"
<Drup> (overloaded terms :D)
<TheLemonMan> tokenrove, that looks perfect, thanks :D
bjorkintosh has quit [Ping timeout: 256 seconds]
reem has joined #ocaml
sdegutis has quit [Quit: Leaving...]
reem has quit [Remote host closed the connection]
jwatzman|work has joined #ocaml
ghostpl_ has joined #ocaml
reem has joined #ocaml
Algebr has joined #ocaml
TheLemonMan has quit [Quit: leaving]
avsm1 has quit [Quit: Leaving.]
prsn has quit [Ping timeout: 240 seconds]
reem has quit [Remote host closed the connection]
ghostpl_ has quit [Ping timeout: 245 seconds]
prsn has joined #ocaml
Guest82053 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
reem has joined #ocaml
Simn has quit [Quit: Leaving]
boadie has joined #ocaml
dhil has quit [Quit: Leaving]
ptc has joined #ocaml
ptc is now known as Guest23255
prsn has quit [Ping timeout: 255 seconds]
rgrinberg1 has joined #ocaml
prsn has joined #ocaml
shinnya has joined #ocaml
MrScou___ has joined #ocaml
MrScout_ has quit [Ping timeout: 250 seconds]
boadie has quit [Ping timeout: 265 seconds]