authentic has quit [Read error: 110 (Connection timed out)]
^authentic is now known as authentic
ikaros_ has joined #ocaml
ygr has joined #ocaml
ikaros has quit [Read error: 110 (Connection timed out)]
ikaros_ has quit [Read error: 110 (Connection timed out)]
ikaros_ has joined #ocaml
prince has quit [Read error: 110 (Connection timed out)]
Linktim has joined #ocaml
adu has quit ["Bye"]
wilsonicus has joined #ocaml
filp has joined #ocaml
<wilsonicus>
Is it just me or are the guys in #c harsh?
Linktim_ has joined #ocaml
Linktim has quit [Read error: 110 (Connection timed out)]
rwmjones_ has joined #ocaml
Linktim_ has quit [Read error: 110 (Connection timed out)]
rwmjones has quit [Read error: 113 (No route to host)]
zarul has quit [Read error: 104 (Connection reset by peer)]
prince has joined #ocaml
z[x] has joined #ocaml
arquebus has joined #ocaml
arquebus has left #ocaml []
ygr has quit [Remote closed the connection]
wilsonicus has quit [Read error: 110 (Connection timed out)]
hkBst has joined #ocaml
<flx>
orbitz, you can easily, in a generic fashion, convert exceptions into values, so handling EOF becomes nicer
Yoric[DT] has joined #ocaml
jlouis has joined #ocaml
gildor_ has joined #ocaml
yangsx has quit [Read error: 110 (Connection timed out)]
oc13 has joined #ocaml
magthe has joined #ocaml
travisbemann has quit ["leaving"]
gildor has quit [Read error: 110 (Connection timed out)]
Linktim has joined #ocaml
Linktim_ has joined #ocaml
Linktim has quit [Read error: 110 (Connection timed out)]
Linktim- has joined #ocaml
evn_ has joined #ocaml
Linktim_ has quit [Read error: 110 (Connection timed out)]
Linktim_ has joined #ocaml
z[x] has quit [Remote closed the connection]
z[x] has joined #ocaml
Linktim- has quit [Read error: 110 (Connection timed out)]
^authentic has joined #ocaml
<Yoric[DT]>
Is anyone around here familiar with the OO Design Pattern called Visitor ?
authentic has quit [Read error: 110 (Connection timed out)]
^authentic is now known as authentic
<flx>
I've used it
<Yoric[DT]>
I have an algorithm implemented in OCaml and I'm directing students who are expected to translate it into Java.
<Yoric[DT]>
Essentially, pattern-matching on my AST becomes a Visitor.
<Yoric[DT]>
Now, my problem is that I have several mutually recursive functions performing pattern-matching on the AST.
<Yoric[DT]>
Mutually recursive Visitors are certainly a possibility, but I'm looking for someone who has experience with this kind of thing, before I tell anything stupid to my students.
<flx>
hm, my cases have only involved a single visitor class
<flx>
I'm not sure though if there should be any problem here
<Yoric[DT]>
Yeah, just like mine.
<flx>
the recursion would likely go through the user class
<Yoric[DT]>
My essential question is: should each recursive call instantiate a new Visitor or should all the visitors be pre-instantiated in some "environment".
<Yoric[DT]>
(i.e. emulating closures)
<flx>
I wouldn't probably use new instances, but it's difficult to see without trying
<Yoric[DT]>
Emulating closures is a pain.
<rwmjones_>
Yoric[DT], have you found visitor to be useful in OCaml? I've always thought of it as a hack for languages which lack proper enums / matching
<Yoric[DT]>
Well, in this case, my students are porting an OCaml algorithm to a language which lacks proper matching :)
<Yoric[DT]>
Camlp4 contains Visitor-like code inside the pretty-printer.
<Yoric[DT]>
I don't remember why, but it sounded like a coherent choice.
schme has joined #ocaml
oc13 has quit [Read error: 110 (Connection timed out)]
<flx>
this is helpful.. gprof tells that camlPervasives__$40_166 takes a lot of time.
<flx>
how would I read that?
Linktim_ has quit [Remote closed the connection]
Linktim has joined #ocaml
jlouis has quit ["Leaving"]
jlouis has joined #ocaml
TheLittlePrince has joined #ocaml
<flx>
phew, I thought my scaling fixes actually degraded performance, but with a more realistic case they help tremendously
<flx>
so much that I can't wait for the benchmark to finish with the original code..
z[x] has quit [Remote closed the connection]
schme has quit [Remote closed the connection]
schme has joined #ocaml
munga has joined #ocaml
munga has quit [SendQ exceeded]
munga has joined #ocaml
<flx>
hm, I have a code structure where I end up doing lots of receivers = List.concat (List.map (\_.receivers) children) in a tree-like fashion: lots of copying happens (no, I don't really use the syntax extension ;-))
<flx>
any suggestions for a better structure?
<flx>
there is one step where I really want a list
<flx>
but potentially lots of copying happens before that
<Smerdyakov>
[concatMap] functions are fairly common when working with compilers that don't do deforestation.
<flx>
ah, that's a good point, I should just write that first :)
<flx>
but the actual issue is that that receivers ends up being copied by someone else again
<flx>
I think there could be a more speed-efficient organization for the field
OChameau has joined #ocaml
<orbitz>
can 'type's be scoppe dinside a function?
<flx>
sort of, you can have a module inside a function
Mr_Awesome has quit [Read error: 110 (Connection timed out)]
<flx>
let foo = let module Bar = struct type t = int end in ..
<mfp>
<flx> this is helpful.. gprof tells that camlPervasives__$40_166 takes a lot of time. -> that's Pervasives.(@) ('@' = 0x40 in ASCII)
Mr_Awesome has joined #ocaml
<flx>
ah, of course
hkBst has quit ["Konversation terminated!"]
<flx>
thanks
hkBst has joined #ocaml
<jlouis>
Time for faster concat ;)
<flx>
I could use rev_append as well, that would help a bit ;)
delamarche has joined #ocaml
z[x] has joined #ocaml
|Catch22| has joined #ocaml
ikaros_ has quit [Read error: 104 (Connection reset by peer)]
ikaros_ has joined #ocaml
delamarche has quit [brown.freenode.net irc.freenode.net]
jlouis has quit [brown.freenode.net irc.freenode.net]
palomer has quit [brown.freenode.net irc.freenode.net]
delamarche has joined #ocaml
jlouis has joined #ocaml
palomer has joined #ocaml
jlouis has quit [Connection timed out]
olleolleolle has joined #ocaml
delamarche has quit []
olleolleolle has quit []
pango_ has quit [Remote closed the connection]
jlouis has joined #ocaml
Linktim has quit [Read error: 104 (Connection reset by peer)]
Linktim has joined #ocaml
pango_ has joined #ocaml
z[x] has quit [Remote closed the connection]
jlouis has quit [Read error: 110 (Connection timed out)]
Morphous has joined #ocaml
wilsonicus has joined #ocaml
wilsonicus has quit [Remote closed the connection]
Amorphous has quit [Read error: 110 (Connection timed out)]
oc13 has joined #ocaml
ygrek has joined #ocaml
Preston has joined #ocaml
<Preston>
good afternoon i am trying to use programs that use the ocaml-xml-light package but the programs i am using can never "find" the ocaml-xml-light package
<Preston>
however, it is installed
<Preston>
is there a method for getting ocaml to recognize ocam-xml-light is actually installed
<Yoric[DT]>
Do you know ocamlfind ?
jlouis has joined #ocaml
<Preston>
yes
<Preston>
well, i mimiced what the configure script was doing
<Preston>
ocamlfind query xml-light
<Preston>
would that be the correct syntax for checking to see if ocaml can correctly find a package?
jlouis_ has joined #ocaml
magthe has quit ["Ex-Chat"]
filp has quit ["Bye"]
jlouis has quit [Read error: 110 (Connection timed out)]
postalchris has joined #ocaml
netx has quit [Remote closed the connection]
netx has joined #ocaml
bluestorm has joined #ocaml
coucou747 has joined #ocaml
<hcarty>
Preston: What OS are you using?
<Preston>
CentOS RHEL 5
<Preston>
..i figured it out :)
<Preston>
but now netclient isn't installing any .cmx files
<Preston>
:(
<Yoric[DT]>
Preston: indeed, it is.
filp has joined #ocaml
<rwmjones_>
Preston, where are you getting your ocaml packages from?
rwmjones_ is now known as rjones
rjones is now known as rwmjones
OChameau has quit ["Leaving"]
<Preston>
well some from the websites that the programmers have (i compile from source) and some via rpms
schme has quit [Remote closed the connection]
<rwmjones>
Preston, well as you may know I maintain the EPEL5 & Fedora packages for ocaml