gildor changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | OCaml 3.12.1 http://bit.ly/nNVIVH
everyonemines has quit [Quit: Leaving.]
twittard has quit [Quit: twittard]
Drup has quit [Quit: Leaving.]
gnech has joined #ocaml
bobzhang1988 has joined #ocaml
iago has quit [Quit: Leaving]
<gnech> hi
<gnech> what are some good bodies of code to play around/learn with?
bobzhang1988 has quit [Ping timeout: 272 seconds]
groovy2shoes has joined #ocaml
groovy2shoes has quit [Read error: Connection reset by peer]
Tobu has quit [Read error: Connection reset by peer]
Tobu has joined #ocaml
groovy2shoes has joined #ocaml
groovy2shoes has quit [Read error: Connection reset by peer]
twittard has joined #ocaml
Kakadu has joined #ocaml
Submarine has joined #ocaml
Submarine has quit [Changing host]
Submarine has joined #ocaml
letrec has quit [Quit: Konversation terminated!]
letrec has joined #ocaml
letrec has quit [Ping timeout: 252 seconds]
Kakadu has quit [Quit: Konversation terminated!]
Kakadu has joined #ocaml
Kakadu has quit [Client Quit]
Kakadu has joined #ocaml
Submarine has quit [Ping timeout: 252 seconds]
edwin has joined #ocaml
Submarine has joined #ocaml
Submarine has quit [Changing host]
Submarine has joined #ocaml
everyonemines has joined #ocaml
ttamttam has joined #ocaml
ttamttam has left #ocaml []
groovy2shoes has joined #ocaml
EmmanuelOga has joined #ocaml
EmmanuelOga has quit [Ping timeout: 244 seconds]
othiym23 has quit [Quit: Leaving...]
avsm has quit [Quit: Leaving.]
groovy2shoes has quit [Read error: Connection reset by peer]
Snark has joined #ocaml
gnech has quit [Ping timeout: 240 seconds]
Cyanure has joined #ocaml
Drup has joined #ocaml
groovy2shoes has joined #ocaml
groovy2shoes has quit [Quit: It is now safe to turn off your groovebot.]
emmanuelux has joined #ocaml
<Kakadu> hi! A have a little bit offtopic for you
<Kakadu> Can you help me to construct grammar which is good in some places for yacc-analizer and is bad for recursive descent?
<everyonemines> Something with lots of nesting that's right-recursive.
<everyonemines> Lisp. :-)
<everyonemines> but with deeper nesting
<everyonemines> unlambda :-)
everyonemines has quit [Remote host closed the connection]
<Kakadu> ;-) some unknown labguages :-)
everyonemines has joined #ocaml
<Kakadu> maybe some if ... then ... (else ...)?
<Kakadu> btw, is E ::= aEb right-recursive rule?
everyonemines has quit [Quit: Leaving.]
Cyanure has quit [Remote host closed the connection]
Cyanure has joined #ocaml
zorun__ has quit [Quit: leaving]
zorun has joined #ocaml
MaskRay has quit [Ping timeout: 252 seconds]
fantasticsid has joined #ocaml
fantasticsid has quit [Client Quit]
MaskRay has joined #ocaml
MaskRay has quit [Changing host]
MaskRay has joined #ocaml
asdfhjkl has joined #ocaml
milosn_ has joined #ocaml
milosn has quit [Ping timeout: 260 seconds]
BiDOrD_ has quit [Ping timeout: 248 seconds]
BiDOrD has joined #ocaml
letrec has joined #ocaml
Drup has quit [Quit: Leaving.]
fracek has joined #ocaml
fracek has left #ocaml []
<olasd> diml: hi, I just filed Intent to Package bugs in debian for zed and lambda-term, could you review the long descriptions I wrote for them? (http://bugs.debian.org/658584 for zed, and http://bugs.debian.org/658596 for lambda-term)
<thelema> hcarty: http://files.vhugot.com/misc/batSet_rnd_failure.txt <- Hugot just reproduced an error with BatSet
<thelema> hcarty: oops,n/m, it's actually a bug in the test
<diml> olasd: sounds good to me (i should probably add them to _oasis files ;-))
<diml> olasd: but note that the development version of lambda-term does not use iconv anymore, so maybe it should not be advertised
letrec has quit [Ping timeout: 252 seconds]
BiDOrD has quit [Ping timeout: 245 seconds]
letrec has joined #ocaml
BiDOrD has joined #ocaml
Tobu has quit [Ping timeout: 248 seconds]
BiDOrD has quit [Ping timeout: 245 seconds]
BiDOrD has joined #ocaml
Tobu has joined #ocaml
jamii has joined #ocaml
<larsrh> some batteries users around? I'm trying to fold_monad an 'a list
<larsrh> I have test : int -> int -> int option
<larsrh> and try to WM.fold_monad test 1 [1,2,3];;
<larsrh> but [1,2,3] has to be of type `int BatEnum.t'
<larsrh> I'm not sure how to construct something of this type
<mfp> larsrh: BatList.enum : 'a list -> 'a BatEnum.t
<larsrh> mfp: thanks, that worked
Tobu has quit [Ping timeout: 252 seconds]
Tobu has joined #ocaml
gnech has joined #ocaml
MaskRay has quit [Quit: leaving]
Xizor has joined #ocaml
iago has joined #ocaml
ocp has joined #ocaml
Smerdyakov has joined #ocaml
oriba has joined #ocaml
BiDOrD_ has joined #ocaml
BiDOrD has quit [Ping timeout: 256 seconds]
BiDOrD_ has quit [Ping timeout: 252 seconds]
BiDOrD has joined #ocaml
gnech has quit [Ping timeout: 240 seconds]
ocp has quit [Quit: Leaving.]
BiDOrD has quit [Ping timeout: 252 seconds]
* adrien curses at the fact that it's a good idea to avoid camlp4 on windows
Tobu has quit [Ping timeout: 252 seconds]
<thelema> adrien: I avoid camlp4 on all platforms
BiDOrD has joined #ocaml
Smerdyakov has quit [Quit: Leaving]
<adrien> thelema: sexplib's "with sexp" syntax is quite useful
Tobu has joined #ocaml
<adrien> I've been rewriting code to avoid it and bah
BiDOrD has quit [Ping timeout: 245 seconds]
<thelema> I'm still not convinced it's worth the hassle of camlp4
<thelema> It does generate a printing function automatically, but batteries makes this pretty easy too
<adrien> well, that's why I'm rewriting :P
<adrien> I used to have a staged setup
<adrien> I would preprocess on linux, commit to a git branch, and pull on windows; it has been working quite well but I only have one file which uses camlp4 and the "with sexp" syntax so I figured I could as well remove camlp4 use altogether
BiDOrD has joined #ocaml
<adrien> plus I was using it on all files instead of only the files that need it
<adrien> so my build times were 16.5 seconds instead of 9.5s...
<thelema> fair enough
<adrien> but I don't understand why this line seems to require camlp4... { metadata_of_sexp sexp with size_expanded = pkg_size }
<adrien> I guess it's from something before but I can't see it; any way, I'll tackle that later on
<thelema> dunno - seems okay to me, assuming that metadata_of_sexp is a function
<Qrntzz> and that it returns a record?
<adrien> it's a function generated by sexplib, but in a different file
<adrien> and it errors on sexp to be preice
<adrien> I really only get a syntax error when not using camlp4 on that file
<adrien> but the "metadata" type is a record with 10 fiels, I'll do it a bit later ;p
<tomprince> Doesn't camlp4 change the syntax more than just allowing syntax extensions? At least by default.
gnech has joined #ocaml
<thelema> tomprince: you mean revised syntax?
<tomprince> Something like that yes.
<thelema> camlp4o / camlp4r
<thelema> original / revise
<thelema> d
letrec has quit [Ping timeout: 260 seconds]
wut__ has joined #ocaml
BiDOrD has quit [Ping timeout: 252 seconds]
BiDOrD has joined #ocaml
oriba has quit [Quit: oriba]
Kakadu has quit [Quit: Konversation terminated!]
Cyanure has quit [Read error: Operation timed out]
<larsrh> Is there a reason why `let module M = Foo.Bar(Baz) in let open M in ...' compiles, but `open Foo.Bar(Baz) in ...' does not?
<thelema> yes, modules need names
<larsrh> Oh, okay
<larsrh> any other way to write this shorter, then?
<thelema> you can do 'include Foo.Bar(Baz), iirc
<thelema> (ignore starting `
<larsrh> doesn't seem to work inside a let binding
<larsrh> [expr] expected after "="
<thelema> oh yeah, not inside let, only wight inside module
<thelema> *right
<thelema> so inside let... you'll have to use longer syntax.
<thelema> maybe open module Foo.Bat(Baz) in ...?
<thelema> or is it 'let open module'
<thelema> open and include are only valid at toplevel of module (not inside let)
<bobry> I wonder if a manual for camlp4 3.12 even exists? the only one i've googled is for 3.07, anyone?
<larsrh> thelema: no luck
<larsrh> yeah, it is `let open'
<larsrh> but after `open', it expects [module_longindent]
<larsrh> *ident
BiDOrD has quit [Ping timeout: 256 seconds]
<thelema> let open module-path in expr
<thelema> yes, the let open requires a module-path, and a functor application isn't a module path
<thelema> a module-path is either a module-name or a module-path.module-name
<larsrh> I see
<thelema> There's a bit of nominal typing around modules
<bobry> thelema: it's for 3.10, and it's missing reference like http://caml.inria.fr/pub/docs/manual-camlp4/manual010.html
<adrien> let open Sexplib.Sexp in
<adrien> match sexp with
<adrien> | ...
<adrien> ='(
<adrien> I've been eating that for the past few days
<thelema> so it's important that values have a module-path
antegallya has joined #ocaml
<larsrh> okay, thanks so far
<thelema> bobry: camlp4 hasn't changed significantly (just bugfixes, iirc) from 3.10 to 3.12
<bobry> ah, i see -- thanks
BiDOrD has joined #ocaml
fraggle_ is now known as FRAGGLE_
FRAGGLE_ is now known as fraggle_
BiDOrD has quit [Ping timeout: 252 seconds]
ikaros has joined #ocaml
Tobu has quit [Ping timeout: 272 seconds]
antegallya has quit [Ping timeout: 252 seconds]
Tobu has joined #ocaml
antegallya has joined #ocaml
BiDOrD has joined #ocaml
antegallya has quit [Ping timeout: 248 seconds]
EmmanuelOga has joined #ocaml
EmmanuelOga has quit [Ping timeout: 244 seconds]
EmmanuelOga has joined #ocaml
Tobu has quit [Ping timeout: 252 seconds]
Tobu has joined #ocaml
Snark has quit [Quit: Quitte]
fraggle_laptop has joined #ocaml
asdfhjkl has quit [Quit: Leaving]
othiym23 has joined #ocaml
Tobu has quit [Ping timeout: 272 seconds]
Tobu has joined #ocaml
othiym23 has quit [Quit: Leaving...]
jamii has quit [Read error: Connection reset by peer]
antegallya has joined #ocaml
<larsrh> I have another question about module types... Assume I have module type Foo = sig type bar end
<larsrh> now, I want to implement a stucture FooImpl which defines "int" for "bar"
<larsrh> any way to write that in the mli?
<larsrh> because I cannot simply say "include Foo;; type bar = int"
<adrien> in which context are you going to use that module?
<adrien> functors?
<larsrh> no, no functors involved
<larsrh> the problem is that I have functions in Foo which take a "bar"
<larsrh> and if I can't state that "bar" is actually "int" in "FooImpl", it is difficult to construct that "bar" for the user
<larsrh> my current solution is to specify an identity function "int -> bar" in "FooImpl"
edwin has quit [Remote host closed the connection]
fraggle_laptop has quit [Remote host closed the connection]
EmmanuelOga has quit [Ping timeout: 244 seconds]
Xizor has quit []
antegallya has quit [Remote host closed the connection]
dcolish has quit [Quit: Coyote finally caught me]
yroeht has joined #ocaml
othiym23 has joined #ocaml
Derander_ has joined #ocaml
maufred_ has joined #ocaml
othiym231 has joined #ocaml
Derander has quit [Ping timeout: 255 seconds]
orbitz_ has joined #ocaml
maufred has quit [Ping timeout: 255 seconds]
othiym23` has quit [Ping timeout: 255 seconds]
ski has quit [Ping timeout: 255 seconds]
orbitz has quit [Ping timeout: 255 seconds]
zmoazeni_ has quit [Ping timeout: 255 seconds]
ski has joined #ocaml
zmoazeni has joined #ocaml
Drakken has left #ocaml []
oriba has joined #ocaml
otk_ has joined #ocaml
<mfp> larsrh: include Foo with type bar = int
otk has quit [Ping timeout: 252 seconds]
ocp has joined #ocaml
Cyanure has joined #ocaml
Tobu has quit [Ping timeout: 248 seconds]
Cyanure has quit [Ping timeout: 240 seconds]
ikaros has quit [Quit: Ex-Chat]
<larsrh> mfp: thanks!
Tobu has joined #ocaml
letrec has joined #ocaml
MaskRay has joined #ocaml
fantasticsid has joined #ocaml
ulfdoz_ has joined #ocaml
emmanuelux has quit [Ping timeout: 240 seconds]
ulfdoz has quit [Ping timeout: 252 seconds]
ulfdoz_ is now known as ulfdoz