mbishop changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | Grab Ocaml 3.10.0 from http://caml.inria.fr/ocaml/release.html (featuring new camlp4 and more!)
Morphous_ has joined #ocaml
ygrek has quit [Remote closed the connection]
jonathan has joined #ocaml
jonafan has quit [Nick collision from services.]
jonathan is now known as jonafan
jonathan has joined #ocaml
jonafan has quit [Nick collision from services.]
jonathan is now known as jonafan
pango has quit [Remote closed the connection]
RobertFischer has quit ["Check out more about me at http://www.SmokejumperIT.com"]
pango has joined #ocaml
jonathanv has joined #ocaml
jonafan has quit [Nick collision from services.]
jonathanv is now known as jonafan
Morphous has quit [Read error: 110 (Connection timed out)]
<mbishop> standard? no, but I believe oleg has a generic printer thing
<mbishop> only for metaocaml though
seafood_ has joined #ocaml
jonathan has joined #ocaml
jonafan has quit [Nick collision from services.]
jonathan is now known as jonafan
Yoric[DT] has left #ocaml []
<kreaturr> what does the toplevel use?
<jonafan> let compose f g = fun a -> f (g a);;
<jonafan> ocamlbottttt
jonathan has joined #ocaml
jonafan has quit [Nick collision from services.]
jonathan is now known as jonafan
wy has quit ["Ex-Chat"]
jonathanv has joined #ocaml
jonathan has joined #ocaml
jonafan has quit [Read error: 110 (Connection timed out)]
jonafan has joined #ocaml
jlouis_ has quit ["leaving"]
jlouis has joined #ocaml
context has quit [Read error: 104 (Connection reset by peer)]
jonathanv has quit [Read error: 110 (Connection timed out)]
jonathanv has joined #ocaml
wy has joined #ocaml
context has joined #ocaml
jonathan has quit [Read error: 110 (Connection timed out)]
jonathan has joined #ocaml
Associ8or has joined #ocaml
Associat0r has quit [Read error: 104 (Connection reset by peer)]
jonafan has quit [Read error: 110 (Connection timed out)]
jonafan has joined #ocaml
jonathanv has quit [Read error: 110 (Connection timed out)]
jonathanv has joined #ocaml
wy has quit [Remote closed the connection]
nuncanada has quit [Remote closed the connection]
jonathan has quit [Read error: 110 (Connection timed out)]
jonathan has joined #ocaml
jonafan has quit [Read error: 110 (Connection timed out)]
ertai has quit [Read error: 110 (Connection timed out)]
jonafan has joined #ocaml
jonathanv has quit [Read error: 110 (Connection timed out)]
jonathanv has joined #ocaml
jonathan has quit [Read error: 110 (Connection timed out)]
jonathan has joined #ocaml
jlouis_ has joined #ocaml
piggybo1 has joined #ocaml
mordaunt has joined #ocaml
jonafan has quit [Read error: 110 (Connection timed out)]
jonafan has joined #ocaml
jlouis has quit [Read error: 110 (Connection timed out)]
jonathanv has quit [Read error: 110 (Connection timed out)]
piggybox has quit [Connection timed out]
jonathan has quit [Read error: 110 (Connection timed out)]
buluca has quit [Read error: 113 (No route to host)]
Jeff_123 has joined #ocaml
qwr has quit [calvino.freenode.net irc.freenode.net]
Jeff_123 has quit [Client Quit]
qwr has joined #ocaml
Jeff_123 has joined #ocaml
<Jeff_123> utf
<Jeff_123> ascii
Jeff_123 has quit [Client Quit]
mordaunt has quit [Remote closed the connection]
wy has joined #ocaml
qpu has joined #ocaml
opening has quit [Connection timed out]
opening has joined #ocaml
gim has quit [Read error: 110 (Connection timed out)]
Jeff_123 has joined #ocaml
Mr_Awesome has joined #ocaml
ygrek has joined #ocaml
<flux> I hadn't realized MetaOcaml actually adds some expressiveness, instead of just being for performance
<Jeff_123> I was looking at it, hoping it would allow run-time compilation of code written during runtime but I didn't see that it could do that :(
<tsuyoshi> ocaml is a compiled language, after all
Yoric[DT] has joined #ocaml
<Jeff_123> sure, but metaocaml advertises run-time compilation of some sort. it's just not as powerful as it is in interpreted languages like tcl.
<Jeff_123> hi yoric, how goes the camlp4 fun?
<Yoric[DT]> Hi.
<Yoric[DT]> First release late last night :)
* Yoric[DT] hopes he didn't get anything too wrong.
<Yoric[DT]> My next steps will be to add pattern matching on lazy lists and pretty printing of lazy lists.
<tsuyoshi> seems to me if you want to construct code during runtime you should just use an embedded interpreter
<Jeff_123> I don't want to write one :(
<tsuyoshi> there are plenty already written
<Jeff_123> I'm just gonna stick with compiling everything
<tsuyoshi> there are two scheme interpreters written in ocaml
<tsuyoshi> you can also link with ruby, python, or perl
<tsuyoshi> unless what you really wanted was an ocaml interpreter?
<Jeff_123> For now I don't need scripting; it's a long term thing.
<Jeff_123> And ya I was thinking ocaml :)
<Jeff_123> so ya I could like, require the user to have ocaml installed, compile whatever they said to a library and use dynlink, but c'mon that's like cheating ;)
piggybo1 has left #ocaml []
Jeff_123 has quit []
Theq629 has quit ["Leaving"]
Jeff_123 has joined #ocaml
love-pingoo has joined #ocaml
Jeff_123 has quit [Client Quit]
jeom is now known as jnkm
seafood_ has quit []
ttamttam has joined #ocaml
Yoric[DT] has quit ["Ex-Chat"]
love-pingoo has quit ["Connection reset by pear"]
Jeff_123 has joined #ocaml
Jeff_123 has quit [Client Quit]
Proteus has quit [Remote closed the connection]
filp has joined #ocaml
wy__ has joined #ocaml
ertai has joined #ocaml
seafood_ has joined #ocaml
seafood_ has quit []
xavierbot has joined #ocaml
magnusj has quit [Remote closed the connection]
magnusj has joined #ocaml
gim has joined #ocaml
Jeff_123 has joined #ocaml
buluca has joined #ocaml
wy__ has quit ["Ex-Chat"]
ppsmimou has joined #ocaml
Jeff_123 has quit []
acatout has quit [Remote closed the connection]
acatout has joined #ocaml
seafood_ has joined #ocaml
wy has quit [Remote closed the connection]
jonathanv has joined #ocaml
marmottine has joined #ocaml
jonafan has quit [Read error: 110 (Connection timed out)]
hkBst has joined #ocaml
seafood_ has quit [calvino.freenode.net irc.freenode.net]
ttamttam has quit [calvino.freenode.net irc.freenode.net]
context has quit [calvino.freenode.net irc.freenode.net]
gaja has quit [calvino.freenode.net irc.freenode.net]
noj has quit [calvino.freenode.net irc.freenode.net]
l_a_m has quit [calvino.freenode.net irc.freenode.net]
flux has quit [calvino.freenode.net irc.freenode.net]
Hadaka has quit [calvino.freenode.net irc.freenode.net]
seafood_ has joined #ocaml
ttamttam has joined #ocaml
context has joined #ocaml
l_a_m has joined #ocaml
Hadaka has joined #ocaml
flux has joined #ocaml
gaja has joined #ocaml
noj has joined #ocaml
ikaros has joined #ocaml
ertai has quit [Read error: 110 (Connection timed out)]
ikaros has quit [Remote closed the connection]
buluca has quit [Read error: 113 (No route to host)]
wy has joined #ocaml
ertai has joined #ocaml
Yoric[DT] has joined #ocaml
qpu has quit ["kthxbye"]
deneb has joined #ocaml
wy has quit ["Ex-Chat"]
<flux> yoric[dt], nice! is there pattern matching support for lazy lists?
<Yoric[DT]> Not yet.
<Yoric[DT]> Actually, technically, if you're willing to run camlp4 twice, it might work already.
<Yoric[DT]> But that's not robust enough.
<Yoric[DT]> That'll be for the next release.
<Yoric[DT]> (hopefully)
<Yoric[DT]> If you wish to try the experimental support, use preprocessor pp_lazylistpattern .
<flux> maybe I'll play around with that on my holidays ;)
<Yoric[DT]> :)
<Yoric[DT]> Bug reports will be welcome.
<flux> have you tried writing actual software with it?
<flux> as a convenience instead of as a test case?
<Yoric[DT]> No.
<Yoric[DT]> Not yet.
<Yoric[DT]> I'm currently converting the countdown problem just as a better test case.
<Yoric[DT]> Plus my current work may end up using this syntax extension.
<Yoric[DT]> But nothing for the moment.
seafood_ has quit []
Jomyoot has joined #ocaml
deneb has quit ["KVIrc 3.2.4 Anomalies http://www.kvirc.net/"]
<Jomyoot> ้ร
<Jomyoot> hi
Jomyoot has left #ocaml []
<jcpiza> hi
bongy has joined #ocaml
ygrek has quit [Remote closed the connection]
petchema has joined #ocaml
bongy has quit ["Leaving"]
<Yoric[DT]> Well, I now have pretty-printing for lazy lists.
nuncanada has joined #ocaml
Tetsuo has joined #ocaml
buluca has joined #ocaml
buluca has quit [Remote closed the connection]
buluca has joined #ocaml
asmanur has joined #ocaml
madroach has joined #ocaml
context has quit [Remote closed the connection]
Yoric[DT] has quit ["Ex-Chat"]
asmanur has quit [Read error: 110 (Connection timed out)]
bluestorm has joined #ocaml
bluestorm has quit [Remote closed the connection]
pango has quit [Remote closed the connection]
asmanur has joined #ocaml
pango has joined #ocaml
buluca has left #ocaml []
buluca has joined #ocaml
jonathanv is now known as jonafan
__suri has joined #ocaml
ttamttam has left #ocaml []
__suri_ has quit [No route to host]
ertai has quit [Read error: 110 (Connection timed out)]
jonathanv has joined #ocaml
bluestorm has joined #ocaml
Mr_Awesome has quit ["aunt jemima is the devil!"]
jonafan has quit [Nick collision from services.]
jonathanv is now known as jonafan
crathman has joined #ocaml
ita has joined #ocaml
filp has quit ["Bye"]
ttamttam has joined #ocaml
ttamtta1 has joined #ocaml
buluca has quit [Read error: 110 (Connection timed out)]
ttamtta1 has left #ocaml []
ttamttam has left #ocaml []
ttamttam has joined #ocaml
psnively has joined #ocaml
ita has quit ["Hasta luego!"]
crathman_ has joined #ocaml
ygrek has joined #ocaml
crathman_ has quit ["ChatZilla 0.9.79 [Firefox 2.0.0.11/2007112718]"]
crathman has quit [Read error: 110 (Connection timed out)]
jeremiah has joined #ocaml
ygrek has quit ["Leaving"]
ygrek has joined #ocaml
psnively has quit []
Yoric[DT] has joined #ocaml
<Yoric[DT]> hi again
buluca has joined #ocaml
ertai has joined #ocaml
malc_ has joined #ocaml
<jonafan> so yoric
<jonafan> yesterday i was messing around with the toplevel interpreter
<jonafan> i wrote a compose function and fed it fun a -> 1 and string_of_int
<jonafan> the resulting function was 'a -> string
<jonafan> until i used it
<jonafan> after that it was stuck on whatever type i used
<jonafan> isn't that ... not supposed to happen?
Snark has joined #ocaml
<bluestorm> jonafan:
<bluestorm> wasn't the result '_a -> string ?
<jonafan> yeah i guess it was
<bluestorm> this is not equivalent to 'a
<jonafan> well.. why?
<jonafan> why is it '_a
<bluestorm> looking for an url
<bluestorm> jonafan:
<bluestorm> what's the type of
<bluestorm> (ref []) ?
<jonafan> i guess it'll change when something goes in it
<jonafan> but this doesn't seem like that
<bluestorm> try eta-expanso
<bluestorm> let yourfun x = (compose string_of_int (fun a -> 1)) x
<jonafan> ah!
<bluestorm> [21:23:42] <jonafan> but this doesn't seem like that
<bluestorm> actually it's the same problem, because you can hide something like "ref []" in a function like the one you were doing
<bluestorm> so the type system only generalize "immediate functions" (with an explicit argument), iirc
<jonafan> i think i got it
<jonafan> still kind of weird but at least it has a solution and is probably not that common of an issue anyway
malc_ has left #ocaml []
asmanur has quit [Remote closed the connection]
olleolleolle has joined #ocaml
pchiusano has joined #ocaml
<pchiusano> hello
jlouis has joined #ocaml
<pchiusano> do you always need to put ;; at the end of all lines?
<olleolleolle> No, but in the interactive prompt you do.
<pchiusano> but in an .ml file, you don't?
<olleolleolle> When you create files that you compile, you don't need to separate the lines like that.
<pchiusano> you can just use carriage return?
<olleolleolle> There's a good book around, that explains the rules well. (I'm a beginner, so my advice could be skewed.) (Yes, just a newline.)
<pchiusano> thx
ertai has quit [Read error: 110 (Connection timed out)]
<madroach> pchiusano: I would recommend you to put ;; after each global let, open and type statement, because it makes debugging some syntax errors easier.
<Yoric[DT]> I'm lookint at the AST of Camlp4.
<pchiusano> madroach: ok
<Yoric[DT]> Does anyone have an idea of what <:ident<a b>> may be ?
<Yoric[DT]> Obviously, it's an identifier that is itself the application of an identifier to another identifier.
<Yoric[DT]> I have no clue what it means, though.
<pchiusano> olle, that book looks nice
<Yoric[DT]> flux: I've just had my first successful lazy pattern matching :)
<pchiusano> how do I load a file in the REPL?
<flux> yoric[dt], nice! so it forces only as much as needed?
<flux> yoric[dt], btw, does case coverage analysis work with that? (or what is it called: the thing that say if you don't match all cases)
<Yoric[DT]> I'm actually using another Camlp4 extension for this pattern-matching: Patterns-0.3 .
<pchiusano> nm, got it
<Yoric[DT]> The case coverage analysis seems to work.
<Yoric[DT]> Although, according to the author, it's not flawless.
<Yoric[DT]> Now, I need to submit a few patches to that extension.
<pchiusano> how do you guys usually work when writing code...
jlouis_ has quit [Read error: 110 (Connection timed out)]
<Yoric[DT]> What do you mean ?
<pchiusano> like, I am used to the following workflow: I am editing a file, foo. I have an interactive prompt open. I make changes to the file, then reload the module in the repl, then issue some expressions
<Yoric[DT]> I'm putting music :)
<Yoric[DT]> I use the prompt relatively rarely.
<pchiusano> okay, so what do you do instead?
ttamttam has left #ocaml []
<Yoric[DT]> flux: mmmhhhh.... actually, looking at the code, code coverage doesn't work.
<Yoric[DT]> pchiusano: write a set of tests, compile everything, compile the tests, check the output.
<pchiusano> ok
<pchiusano> is that what most people do?
<Yoric[DT]> I'm not sure.
<Yoric[DT]> I believe I should spend more time using the toplevel.
<pchiusano> hmm, ok :)
<Yoric[DT]> mmmhhh....
<Yoric[DT]> Does anyone know how I can inspect a .cma and find out what modules it contains ?
<flux> yoric[dt], ocamlobjinfo
<Yoric[DT]> thanks
<flux> pchiusano, I usually press C-x C-e in xemacs to evaluate the function and perhaps then try it out a few times in the interactive session (inside xemacs)
<flux> for little parts
<flux> for the whole file I might go ahead and use #use
<flux> and for the whole project I might have a toplevel-target in the makefile
<Yoric[DT]> mmmhhhh.....
<Yoric[DT]> I have produced a .cma using OCamlBuild.
<Yoric[DT]> Now, I can #load it from the toplevel, but I can't open the modules it contains.
<Yoric[DT]> Any idea ?
<pchiusano> you cannot have multiple defs of same function in ocaml, right, like: factorial 1 = 1; factorial n = n * factorial (n-1); you would do factorial n = match n with 1 -> 1 | n -> n * factorial (n-1)
<pango> yup, or in this specific case, use 'function'
<pango> as in, let rec factorial = function 1 -> 1 | n -> n * factorial (n-1)
RobertFischer has joined #ocaml
pchiusano has quit [Read error: 104 (Connection reset by peer)]
<Yoric[DT]> So, no error regarding my .cma issue ?
pchiusano has joined #ocaml
<Yoric[DT]> So, no idea regarding my .cma issue ?
* Yoric[DT] is tired.
<bluestorm> pchiusano: you have to do the second way
<flux> yoric[dt], I sometimes have the same problem, I just work around it by loading the individual .cmo-files :)
<Yoric[DT]> :)
<Yoric[DT]> My problem is that I wish to distribute this.
<Yoric[DT]> It's a bug I found in my syntax extension.
<Yoric[DT]> The .cmo work fine, the .cma doesn't.
Snark has quit ["Quitte"]
<pchiusano> is there like an ocaml --make option?
<olleolleolle> pchiusano: like a build system?
<pchiusano> yeah, like I just pass it the main file, and it compiles all dependencies?
<bluestorm> Yoric[DT]:
<bluestorm> <:ident< a b >> get pretty-printed as a(b)
<bluestorm> don't know what that mean :p
<Yoric[DT]> pchiusano: ocamlbuild name_of_your_file.byte (or .native )
<Yoric[DT]> bluestorm: thanks :)
madroach has quit [Remote closed the connection]
<Yoric[DT]> bluestorm: any idea about my linking problem ?
<bluestorm> none
<bluestorm> moreover, i've not got to use ocamlbuild yet
<Yoric[DT]> I believe the problem is not specific to ocamlbuild.
<Yoric[DT]> mmhh...
<Yoric[DT]> Ok, I believe I got it.
<Yoric[DT]> There may be a problem with the fact that one of the modules was in a subdirectory.
pchiusano has quit [Read error: 104 (Connection reset by peer)]
pchiusano has joined #ocaml
pchiusano has quit [Read error: 101 (Network is unreachable)]
marmottine has quit ["Quitte"]
bluestorm has quit ["Konversation terminated!"]
wy has joined #ocaml
Tetsuo has quit ["Leaving"]
olleolleolle has quit []
seafood_ has joined #ocaml
ikaros has joined #ocaml
RobertFischer has quit [Read error: 113 (No route to host)]
<Yoric[DT]> Well, good night everyone.
Yoric[DT] has quit ["Ex-Chat"]
ikaros has quit ["segfault"]
Smerdyakov has quit ["Leaving"]
ita has joined #ocaml
seafood_ has quit []
wy has quit ["Ex-Chat"]
jlouis_ has joined #ocaml
jlouis__ has joined #ocaml
madroach has joined #ocaml
jlouis has quit [Read error: 110 (Connection timed out)]
pchiusano has joined #ocaml
<jcpiza> hello, is there mod_ocaml for Apache?