flux changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | 3.11.0 out now! Get yours from http://caml.inria.fr/ocaml/release.html
gnuvince_ has joined #ocaml
Camarade_Tux has quit ["Leaving"]
Amorphous has quit [Read error: 110 (Connection timed out)]
Amorphous has joined #ocaml
jeanbon has quit ["EOF"]
AxleLonghorn has joined #ocaml
Ched has quit [Read error: 60 (Operation timed out)]
rhar has quit [Read error: 60 (Operation timed out)]
xerxes_ has joined #ocaml
xerxes has quit [Read error: 60 (Operation timed out)]
Ched has joined #ocaml
AxleLonghorn has left #ocaml []
kaustuv has quit ["1"]
sgwizdak has joined #ocaml
xerxes_ is now known as Xerxes_on_Mepehd
Xerxes_on_Mepehd is now known as MepehdroneXerxes
MepehdroneXerxes is now known as Xerxes
tar_ has joined #ocaml
<tar_> In my ml file I can say "module Context = Map.Make(String)" but is there a similar shortcut for my mli file, or do I need to reproduce the module signature long-hand?
<thelema> ? Map.make is a functor with an output signature
<tsuyoshi> module Context: Map.S with key = String.t
<tsuyoshi> or key = string
<tsuyoshi> oh sorry
<tsuyoshi> module Context: Map.S with type key = string
<tar_> Oh, thank you
<tar_> Okay, now I see that in the functor examples
jamii has joined #ocaml
jedai has quit [Read error: 60 (Operation timed out)]
jedai has joined #ocaml
tar_ has quit []
Xerxes has quit ["Ex-Chat"]
kaustuv has joined #ocaml
Camarade_Tux has joined #ocaml
Camarade_Tux_ has joined #ocaml
Camarade_Tux has quit [Read error: 110 (Connection timed out)]
Camarade_Tux_ has quit ["Leaving"]
rhar has joined #ocaml
m3ga has quit ["disappearing into the sunset"]
rhar has quit ["Leaving"]
s4tan has joined #ocaml
seafood_ has joined #ocaml
Skolem has quit [hubbard.freenode.net irc.freenode.net]
lutter has quit [hubbard.freenode.net irc.freenode.net]
bebui has quit [hubbard.freenode.net irc.freenode.net]
gl has quit [hubbard.freenode.net irc.freenode.net]
gl has joined #ocaml
Skolem has joined #ocaml
bebui has joined #ocaml
lutter has joined #ocaml
verte has joined #ocaml
s4tan has quit []
s4tan has joined #ocaml
komar_ has joined #ocaml
love-pingoo has joined #ocaml
rwmjones_ has joined #ocaml
_zack has joined #ocaml
hkBst has joined #ocaml
jeanbon has joined #ocaml
Camarade_Tux has joined #ocaml
<rwmjones_> the Str.global_substitute function is annoyingly limited?
<rwmjones_> you don't know which substring matched, so the 'subst' function can't do anything useful
<rwmjones_> or am I missing something ...?
<mfp> rwmjones_: you get it via another function
<mfp> the API is quite ugly, as it uses global state
<mfp> rwmjones_: Str.matched_string : string -> string
<rwmjones_> ugh
<rwmjones_> mfp thanks
<mfp> global_substitute gives you the string you matched against, and when passed to matched_string you get the matching fragment
<mfp> it's really ugly
<mfp> I suppose it's that way for perf., to avoid allocating stuff in each call to the subst function
<mfp> but it could use at least something like type match = { ... record with mutable fields } val global_substitute : regexp -> ?match:match -> (match -> string) -> string -> string
<mfp> so it just updates some offsets in the match record, no allocation or caml_modify needed, fast and reentrant
<mfp> all of Str uses global state though :-|
<rwmjones_> yes, it works
<rwmjones_> I've got a self-imposed limitation of not using anything apart from stdli
<rwmjones_> stdlib
<mfp> quite a limitation that is... not even extlib?
<rwmjones_> mfp, yeah, for libguestfs ... the C programmers will get frightened
gnuvince_ has quit [Read error: 113 (No route to host)]
<kaustuv> isn't the pcre binding pervasive enough?
verte_ has joined #ocaml
slash_ has quit [Client Quit]
verte has quit [Nick collision from services.]
verte_ is now known as verte
<flux> rwmjones, libguestfs?
komar_ has quit [Remote closed the connection]
Spiwack has joined #ocaml
s4tan has quit []
jedai has quit ["KVIrc 3.4.0 Virgo http://www.kvirc.net/"]
Demitar has quit [Remote closed the connection]
s4tan has joined #ocaml
Demitar has joined #ocaml
seafood_ has quit [Read error: 113 (No route to host)]
jeddhaberstro has joined #ocaml
<rwmjones_> flux, probably this is a better link for libguestfs & ocaml: http://rwmj.wordpress.com/2009/04/20/generating-code/
munga_ has joined #ocaml
_zack has quit ["Leaving."]
_zack has joined #ocaml
Associat0r has joined #ocaml
seafood has joined #ocaml
komar_ has joined #ocaml
seafood has quit []
verte has quit [":("]
Mypat has joined #ocaml
yakov has joined #ocaml
<yakov> hey
<yakov> guys do you know if there's some secret build of findlib for windows?
Mypat has quit [Remote closed the connection]
love-pingoo has quit ["Connection reset by pear"]
badkins has joined #ocaml
rwmjones_ has quit [Read error: 110 (Connection timed out)]
l_a_m has quit [Read error: 60 (Operation timed out)]
_zack has quit ["Leaving."]
s4tan has quit []
ztfw has joined #ocaml
willb has joined #ocaml
jeddhaberstro has quit [Read error: 104 (Connection reset by peer)]
jeddhaberstro has joined #ocaml
psnively has joined #ocaml
rwmjones_ has joined #ocaml
munga_ has quit ["Ex-Chat"]
willb has quit [Read error: 60 (Operation timed out)]
Spiwack has quit ["Leaving"]
jeanbon has quit [Read error: 113 (No route to host)]
jeanbon has joined #ocaml
yakov has quit ["õÈÏÖÕ Ñ ÏÔ ×ÁÓ (xchat 2.4.5 ÉÌÉ ÓÔÁÒÛÅ)"]
OChameau has quit ["Leaving"]
Yoric[DT] has joined #ocaml
ztfw` has joined #ocaml
kaustuv_ has joined #ocaml
ztfw has quit [Read error: 60 (Operation timed out)]
jamii has quit [Remote closed the connection]
ztfw`` has joined #ocaml
ztfw`` has quit [Remote closed the connection]
jlouis has quit [Read error: 60 (Operation timed out)]
ztfw` has quit [Read error: 110 (Connection timed out)]
willb has joined #ocaml
robocop has joined #ocaml
<robocop> hello
<mrvn> olleh
<robocop> do you ever seen this error : This kind of expression is not allowed as right-hand side of `let rec' ?
<mrvn> yes
<robocop> *have you (sorry)
robocop has quit [Remote closed the connection]
<mrvn> You can't access members of the left hand side or pass it as argument to functions that are fully applied.
robocop has joined #ocaml
<mrvn> You can't access members of the left hand side or pass it as argument to functions that are fully applied.
<robocop> re, sorry, pidgin bug.
<mrvn> Did that solve your problem?
<robocop> no
<robocop> I paste my code : http://paste.pocoo.org/show/113915/
<mrvn> where is the error?
<kaustuv_> I wonder if adding one more word to the headers of blocks and limiting constructors and records to have a maximum of 64 arguments/fields in exchange for unboxed native integers and floats would cause a riot.
<mrvn> kaustuv_: how would you do that on 32bit?
<mrvn> I'm assuming you want to add a bitfield tell what fields are boxed. On 32bit that would limit you to blocks of size 32 or add more words.
<robocop> mrvn: what means "access members of the left hand side" ?
<mrvn> robocop: let rec x = { x = x.x }
<robocop> hum, okey.
<mrvn> shouldn't matter with functions.
<mrvn> kaustuv_: I would rather add a variable size bitmap to the end of the block instead of limiting the size of blocks.
<hcarty> kaustuv_: If you have a working patch then it probably would cause loud grumbling as "OCaml 4.0"
<hcarty> kaustuv_: I imagine something like this would cause some amount of cheers as well. What would this mean for arrays?
<mrvn> hcarty: arrays already have a tag for the type of content.
<kaustuv_> No, I don't have a patch, but I've been looking into the feasibility of it.
<robocop> okey mrvn, but i don't understand why I've got this error with this code.
<mrvn> kaustuv_: wouldn't that also give you untagged ints (int == nativeint)?
<mrvn> robocop: I don't eigther.
<robocop> I thinks it's because I use "let rec
<robocop> *"let rec ... and ... and "
<mrvn> robocop: but you do use recursion
<mrvn> robocop: pull the nums out of the let rec and try it on its own.
<robocop> mrvn: if I pull the nums and test nums, no problem
<robocop> mrvn: no problem for nums
<robocop> but same problem for the rest
<mrvn> kaustuv_: Define a block as header(tag,size,color), value array, bitmap(ceil(size / sizeof(value) / 8)) values.
<mrvn> robocop: so it isn't the outer let rec that is the problem.
<robocop> hum, okey.
<mrvn> Does it need to be tail recursive?
<robocop> no
<mrvn> let nums = parser [< 'int n; ss >] -> n :: (nums ss) | [< >] -> [];;?
<mrvn> +rec
<robocop> okey
<robocop> no, no problems.
<robocop> thanks a lot.
<mrvn> robocop: that works? Good guess. :)
<robocop> but this error is strange, is not it ?
<mrvn> Still don't see why the tail recursive way doesn't work.
<robocop> perhaps it's a bogue ?
<robocop> *bug
<mrvn> kaustuv_: How would you implement Store_field(b, n, v)? The value v could be a pointer or nativeint without any way to tell.
<mrvn> robocop: ask on the ML.
bzzbzz has quit ["leaving"]
thelema has quit [Read error: 110 (Connection timed out)]
<robocop> Hum, in reality, I've got an other problem : http://paste.pocoo.org/show/113924/
<robocop> this code : exec (lexer "(+ 5 3)");; always send me : Exception: Stream.Error "".
<Associat0r> hey electrocop
robocop has quit ["Leaving."]
jlouis has joined #ocaml
Falcon has joined #ocaml
Falcon has left #ocaml []
monadic_kid has joined #ocaml
slash_ has joined #ocaml
badkins has left #ocaml []
jeanbon has quit ["EOF"]
jeanbon has joined #ocaml
hkBst has quit [Read error: 104 (Connection reset by peer)]
psnively has quit []
Camarade_Tux has quit ["Leaving"]
rwmjones_ has quit ["Leaving"]
Ariens_Hyperion has joined #ocaml
\xs is now known as bindreturn
willb has quit [Read error: 110 (Connection timed out)]
thelema has joined #ocaml
det has joined #ocaml
gildor has quit [hubbard.freenode.net irc.freenode.net]
rumbleca has quit [hubbard.freenode.net irc.freenode.net]
sbok has quit [hubbard.freenode.net irc.freenode.net]
munga has quit [hubbard.freenode.net irc.freenode.net]
prigaux has quit [hubbard.freenode.net irc.freenode.net]
mfp has quit [hubbard.freenode.net irc.freenode.net]
mfp has joined #ocaml
rumbleca has joined #ocaml
munga has joined #ocaml
gildor has joined #ocaml
sbok has joined #ocaml
prigaux has joined #ocaml
Ariens_Hyperion has quit []
Ariens_Hyperion has joined #ocaml
brendan has quit ["leaving"]
brendan has joined #ocaml
komar_ has quit [Read error: 104 (Connection reset by peer)]
slash_ has quit [Client Quit]
Pepe_ has quit [Remote closed the connection]
Pepe_ has joined #ocaml
jlouis has quit [Remote closed the connection]
jlouis has joined #ocaml
TaXules has quit [Remote closed the connection]
TaXules has joined #ocaml
det has quit [Read error: 110 (Connection timed out)]
jeanbon has quit ["EOF"]
jeanbon has joined #ocaml
Yoric[DT] has quit ["Ex-Chat"]
monadic_kid has quit ["Leaving"]
det has joined #ocaml