mbishop changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | Grab OCaml 3.10.2 from http://caml.inria.fr/ocaml/release.html (featuring new camlp4 and more!)
seafood has joined #ocaml
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
RobertFischer has joined #ocaml
seafood_ has joined #ocaml
jonathanv has joined #ocaml
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood_ has quit [Client Quit]
seafood has joined #ocaml
<jonathanv> so
<jonathanv> is it just me or is making a monad class actually impossible
Smerdyakov has quit ["Leaving"]
<dibblego> OCaml does not have higher-kinds, last I asked someone (i.e. don't take my word for it)
<jonathanv> i wanted to make a series of monad classes so i could do let (>>=) m f = m#bind f;;
<dibblego> you need higher kinds for a monad class, but I don't know OCaml all that well to be sure
<jonathanv> but i keep getting this "type scheme cannot quantify 'b : it escapes this scope" error
<jonathanv> i can make it monads that only bind ('a -> 'a monad) functions, but never ('a -> 'b monad)
<jonathanv> i think i want 'b to escape the scope
<dibblego> monads also need a unit, whatever the syntax would be
<jonathanv> i think that's the point
<jonathanv> yeah, i couldn't get that one to work quite right either
<dibblego> you want forall b. on the bind function, while forall a. on the class
seafood has quit []
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood has quit [Client Quit]
AxleLonghorn has joined #ocaml
AxleLonghorn has left #ocaml []
seafood has joined #ocaml
<jonathanv> it seems like this won't work
<jonathanv> even if i could get this to work, it woudn't work like i want because other types of monads would take different types of functions for bind
<jonathanv> holy crap, it's friggin 8:18 already
<jonathanv> k thxbai
jonathanv has quit ["XCHAT NEGROS"]
m3ga has joined #ocaml
Amorphous has quit [Read error: 110 (Connection timed out)]
Amorphous has joined #ocaml
Ched- has quit [Connection timed out]
Ched- has joined #ocaml
AxleLonghor1 has joined #ocaml
AxleLonghor1 has left #ocaml []
structured has quit [Read error: 110 (Connection timed out)]
sporkmonger_ has quit []
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood has quit []
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
seafood has quit []
seafood has joined #ocaml
seafood has quit [Client Quit]
seafood has joined #ocaml
seafood_ has joined #ocaml
seafood_ has quit [Read error: 104 (Connection reset by peer)]
seafood_ has joined #ocaml
seafood has quit [Read error: 113 (No route to host)]
m3ga has quit ["disappearing into the sunset"]
RobertFischer has quit ["Taking off -- check out http://smokejumperit.com and http://enfranchisedmind.com/blog/"]
ygrek has joined #ocaml
seafood_ has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
seafood has quit [Client Quit]
ygrek has quit [Remote closed the connection]
ygrek_ has joined #ocaml
Jedai has quit [Read error: 110 (Connection timed out)]
seafood has joined #ocaml
Kopophex has quit ["Leaving"]
<seafood> Hello again, I'm really sorry to ask the same question again. I was told by one of you (I forget who) some tools/libraries that helped write OCaml to C bindings. It turns out I disabled logging in my IRC client. Duh!
<seafood> Could you tell me again?
<flux> swik (?), ocamlidl, saffir
<flux> saffire, or something like that :)
<seafood> flux: Thanks very much.
aldous_fuxley has joined #ocaml
aldous_fuxley has quit [Remote closed the connection]
hkBst has joined #ocaml
Jedai has joined #ocaml
OChameau has joined #ocaml
jeremiah has quit [Read error: 104 (Connection reset by peer)]
Tetsuo has joined #ocaml
rwmjones_ has joined #ocaml
jeremiah has joined #ocaml
Snark has joined #ocaml
vbmithr has joined #ocaml
<seafood> flux: It's swig.
seafood has quit []
seafood has joined #ocaml
letrec has joined #ocaml
l_a_m has joined #ocaml
seafood has quit [Read error: 110 (Connection timed out)]
seafood has joined #ocaml
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
seafood has quit []
seafood has joined #ocaml
<vixey> what is caml light for?
<letrec> Caml light is used in education. See caml.inria.fr
<vixey> thank you
<vixey> that's quite amazing
<vixey> "The whole system is quite small: about 100K for the runtime system, and another 100K of bytecode for the compiler. Two megabytes of memory is enough to recompile the whole system."
<letrec> Yes. But for real world usage, you should use Ocaml
<vixey> I am just starting out with ocaml now, It's great :)
<letrec> Yes, Ocaml is a very interesting and thought-provoking language.
<letrec> It can also be used for real world implementation -- I wrote a C compiler in 4 weekends! So have fun. What do you plan to do with it?
<vixey> wow
<vixey> I'm implementing Prolog and I've chosen to target Scheme and Ocaml
<letrec> I don't know prolog much. But do you want to write a compiler? An interpreter?
<vixey> I'm working on a compiler now after writing several interpreters to try out the different ways
seafood has quit [Read error: 110 (Connection timed out)]
<letrec> Ok, sounds great. Good luck with it. On this IRC channel, you can find a lot of knowledgeable people who can help you a great deal.
<vixey> thank you
jeremiah has quit [Read error: 104 (Connection reset by peer)]
TychoBrahe has quit [Read error: 131 (Connection reset by peer)]
seafood has joined #ocaml
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
<flux> fun-nyy.. I was trying out a module I just wrote, but for some reason it outputted nothing
<flux> I put a debug message before the point where the iterated printing should occur - nothing
<flux> and the expression even seemed invisible to the debugger (first time ever I suppose I've really used a debugger seriously)
<flux> the top-level expression was of form: let _ = print_endline "Foo:"; (* other expression here *)
seafood has quit [Read error: 104 (Connection reset by peer)]
<flux> I had forgotten one argument from the other expression..
seafood has joined #ocaml
jeremiah has joined #ocaml
OChameau has quit [Read error: 110 (Connection timed out)]
seafood has quit [Read error: 104 (Connection reset by peer)]
seafood has joined #ocaml
OChameau has joined #ocaml
<flux> I wonder if it is possible to write a more type safe interface to this: http://modeemi.fi/~flux/software/ocaml/multiKeyMap.mli
<flux> the problematic case remaining is that you can do iter_foreign with a mapping that has not been associated with the module
<letrec> When using the C/Ocaml interface in Windows, how do I specify the C compiler that has to be used?
seafood has quit [Read error: 110 (Connection timed out)]
TychoBrahe has joined #ocaml
tty56 has joined #ocaml
<rwmjones_> gildor_, is there a developer repo for ocaml-gettext? thought I might have a go at fixing bugs 66 & 67.
<vixey> do you usually write out makefiles by hand?
<rwmjones_> vixey, i do .. but there are other alternatives for ocaml, including omake, ocamlbuild, OCamlMakefile ...
<rwmjones_> probably others
jlouis has quit [Remote closed the connection]
sporkmonger has joined #ocaml
<flux> vixey, I used to write Makefiles by hand for a long time, but nowadays when starting something small, I juse use OCamlMakefile.. Perhaps I should look into ocamlbuild some day.
<gildor_> rwmjones_: what do you mean by a dev repo ?
<gildor_> vixey: ocamlbuild is a very nice solution (but required ocaml > 3.10) and OCamlMakefile is great for small projects
jonafan_ has joined #ocaml
Yoric[DT] has joined #ocaml
Smerdyakov has joined #ocaml
LordMetroid has joined #ocaml
<rwmjones_> gildor_, I meant version control repository so I can submit patches against the very latest version ... as it is, I'll send you patches against 0.3.1
<gildor_> rwmjones_: i don't have time to work on ocaml-gettext since 0.3.1, so it is ok if you submit a patch against it
<gildor_> i am planning to setup a darcs repository, but have hard time to convert my CVS and SVN history
jonafan has quit [Read error: 110 (Connection timed out)]
<flux> perhaps the guys on #darcs have ideas on how to do that
<gildor_> flux: thanks for the tip
<gildor_> but the problem is about "how to track an unstructured SCM like subversion"
<gildor_> and it has no easy answer
<flux> well, one option is to just keep the old data in svn
<gildor_> (i.e. how can you follow rename of whole directory inside SVN history)
<gildor_> flux: yep, this simple and straightforward
<gildor_> but i am trying other solution, using a fine analysis of SVN dump file, to track and reinterpret SVN history to get a clean repo without problematic renames, to use tools like git-svn
bzzbzz has quit ["leaving"]
koobe has joined #ocaml
Snark has quit ["Ex-Chat"]
bluestorm has joined #ocaml
<letrec> How do I use ocamlbuild to compiler my mixed Ocaml/C app?
<letrec> I'm not sure it is even possible, so I'm asking.
<flux> I don't know, but afaik it should be possible
<flux> for instance ocamlc can compile c files fine
<letrec> Ok, thanks. I don't know how to specify the C file. Doc doesn't cover this.
<letrec> How do you compiler a C file?
<flux> ocamlc -c c_file.c
<flux> disclaimer: I don't know anything about ocamlbuild
<flux> but perhaps you can pick a project that uses ocamlbuild and has c files
<letrec> Ok, I'll have a look.
<rwmjones_> gildor_, do you think if you've got a moment you could give me a yes/no on the suggested fix for http://le-gall.net/sylvain+violaine/bts/?do=details&id=66 ? If yes, then I can add it to our Fedora package straightaway.
<gildor_> rwmjones_: your patch seems clean
<rwmjones_> is that good :-?
<gildor_> rwmjones_: but (sorry to ask you that) i always need to have a test case to prove where the error is
<rwmjones_> gildor_, you mean add a test case to the code?
<gildor_> i.e. add a test case in tests/test.ml
<rwmjones_> ah ok I'll do it
<gildor_> rwmjones_: sorry for this, but my coding policy is to always have test case before correcting bugs (it is safer for future version)
<gildor_> rwmjones_: once you add this to your patch -> apply and release 0.3.2
<rwmjones_> sure, I understand
szell` has joined #ocaml
struk_atwork2 is now known as struk_atwork
szell has quit [Read error: 110 (Connection timed out)]
TheLittlePrince has joined #ocaml
<petchema> (FYI) http://www.irisa.fr/centredoc/publis/theses/2005/irisapublication.2005-09-28.4154781075 (fr) very interesting project, with an OCaml prototype...
<flux> ..in french
<petchema> hence the (fr)
<Yoric[DT]> French is beautiful.
<Smerdyakov> French is the Windows 95 of natural languages. ;D
* Yoric[DT] frappe Smerdyakov avec une truite humide.
delamarche has joined #ocaml
postalchris has joined #ocaml
<rwmjones_> gildor_, any idea why a test added to test/test.ml:all_test just never gets run?
<rwmjones_> fuck fuck fuck ... I was editing the wrong file!!
* Yoric[DT] wonders if that's why English is so much better than French.
<Yoric[DT]> Maybe that's the equivalent of a Kernel Panic.
jlouis has joined #ocaml
Tetsuo has quit [Read error: 110 (Connection timed out)]
Ched- has quit [Remote closed the connection]
Axioplase has joined #ocaml
pango_ has quit [Remote closed the connection]
pango_ has joined #ocaml
asmanur has joined #ocaml
rwmjones_ has quit ["Closed connection"]
Linktim has joined #ocaml
rwmjones has quit [Remote closed the connection]
<bluestorm> in case someone is interested
<bluestorm> i just uploaded my self-generated camlp4 doc
<bluestorm> (actually it's only a part of the doc, but an interesting part imho)
<bluestorm> (and i'm not sure it will stay forever at that place, but anyway i found it useful when trying to understand the camlp4 stuff)
Ched- has joined #ocaml
<Yoric[DT]> Good idea.
<letrec> Gents, when I enter the command 'ocaml what.cma', the program evaluates the expressions defined by 'let _ =...' in what.ml. Now, if I use 'ocamlc what.cma', it creates a.out, but running a.out does nothing. Any idea?
<letrec> It must be pretty basic question..
TheLittlePrince has quit [Client Quit]
<bluestorm> letrec: .cma sometimes get evaluated, and sometimes they don't until you actually use them
<bluestorm> (and i don't know why)
jonafan_ is now known as jonafan
<letrec> bluestorm: ok, thanks. Kind of laziness in ocaml..
<bluestorm> for example using a basic .ml with something like let module a = struct include What end in () could help
Smerdyakov has quit ["go somewhere else"]
<bluestorm> (as i don't understand what i'm talking about, you should not attach to much truth value to what i say)
LordMetroid has quit ["Leaving"]
<letrec> Well, as you're only one who is talking right now, you're kind of oracle to me. (Au pays des aveugles...).
<letrec> Thanks anyway.
<struk_atwork> letrec: show me your top level code
LordMetroid has joined #ocaml
delamarche has quit []
Snrrrub has joined #ocaml
postalchris has quit [Read error: 104 (Connection reset by peer)]
postalchris has joined #ocaml
smimou has quit ["bli"]
vixey has quit [Read error: 104 (Connection reset by peer)]
OChameau has quit ["Leaving"]
<pango_> letrec: I wonder if it's not a consequence of "smart linking"... If a module is not referenced at all, it's dropped by the linker... hence not executed
<pango_> letrec: the size of the executable could (in/con)firm that hypothesis
robozni has quit ["leaving"]
ygrek has joined #ocaml
tty56_ has joined #ocaml
tty56 has quit [Read error: 113 (No route to host)]
tty56__ has joined #ocaml
tty56_ has quit [Read error: 104 (Connection reset by peer)]
tty56 has joined #ocaml
l_a_m has quit [Remote closed the connection]
postalchris has quit [Read error: 113 (No route to host)]
Snark has joined #ocaml
asmanur_ has joined #ocaml
asmanur has quit [Read error: 110 (Connection timed out)]
tty56__ has quit [Read error: 113 (No route to host)]
kelaouchi has joined #ocaml
Axioplase has quit ["Lost terminal"]
Axioplase has joined #ocaml
tty56 has quit []
filp has joined #ocaml
Axioplas1 has joined #ocaml
Axioplase has quit [Read error: 104 (Connection reset by peer)]
asmanur_ has quit [Read error: 104 (Connection reset by peer)]
smimou has joined #ocaml
postalchris has joined #ocaml
Linktim has quit [Remote closed the connection]
struk_atwork has quit [Read error: 104 (Connection reset by peer)]
Snrrrub has quit [Read error: 104 (Connection reset by peer)]
<palomer> hrmph
<palomer> how do you divide a string into words?
<palomer> like split "foo bar" => ["foo";"bar"]
<hcarty> palomer: Pcre has split function. Str probably does as well.
<palomer> ok
<palomer> thx!
<jonafan> is there really no way to do this? http://pastebin.eu/pastebin.php?show=5124
struk_atwork has joined #ocaml
delamarche has joined #ocaml
Snark has quit ["Ex-Chat"]
<mbishop> I believe split takes a delimiter though, just so you know
vixey has joined #ocaml
<hcarty> I think, for both libraries, that the delimiter is a regexp
ofaurax has joined #ocaml
delamarche has quit []
kelaouchi has quit ["leaving"]
ofaurax has quit ["Leaving"]
struk_atwork has quit [Read error: 104 (Connection reset by peer)]
ygrek_ has quit [Remote closed the connection]
Dzlk has joined #ocaml
ygrek has quit [Remote closed the connection]
<bluestorm> jonafan: how can having monad as objects make sense ?
<bluestorm> you can't even have a proper "return"
<jonafan> having 1 bind operator is how it makes sense
<jonafan> however, at this point, i mostly think it's just absurd that this apparently can't be done
<jlouis> there is probably a really good reason for the type system to reject it
<jonafan> i don't see how
<jlouis> though what it is eludes me at the moment
<bluestorm> btw
<bluestorm> it's (init : 'a option
<bluestorm> )
<jonafan> ah yes
mattam has quit [Read error: 110 (Connection timed out)]
zmdkrbou has quit [Read error: 110 (Connection timed out)]
hkBst has quit ["Konversation terminated!"]
sporkmonger has quit [Read error: 110 (Connection timed out)]
jlouis has quit ["Leaving"]
postalchris has quit [Read error: 104 (Connection reset by peer)]
Axioplas1 has quit ["leaving"]
bluestorm has quit ["Konversation terminated!"]
<jonafan> i still don't understand
postalchris has joined #ocaml
filp has quit [Read error: 110 (Connection timed out)]
filp has joined #ocaml
sporkmonger has joined #ocaml
sporkmonger has quit [Read error: 104 (Connection reset by peer)]
sporkmonger has joined #ocaml
filp has quit ["Bye"]
postalchris has quit [Read error: 104 (Connection reset by peer)]
sporkmonger has quit [Read error: 110 (Connection timed out)]
xevz has joined #ocaml
Yoric[DT] has quit ["Ex-Chat"]
pango_ has quit [Remote closed the connection]
TychoBrahe has quit [Remote closed the connection]
vbmithr has quit ["Zz"]
pango_ has joined #ocaml
TychoBrahe has joined #ocaml
marmottine has joined #ocaml
mfp has quit [Read error: 101 (Network is unreachable)]
mfp has joined #ocaml