johnnowak has quit [Read error: 110 (Connection timed out)]
pstickne has quit [Read error: 104 (Connection reset by peer)]
pstickne has joined #ocaml
pstickne has quit [Read error: 54 (Connection reset by peer)]
pstickne has joined #ocaml
pstickne has quit [Read error: 104 (Connection reset by peer)]
Balakirev has left #ocaml []
slipstream-- has joined #ocaml
slipstream has quit [Read error: 60 (Operation timed out)]
diffbavis has quit [Read error: 54 (Connection reset by peer)]
pstickne has joined #ocaml
Smerdyakov has quit ["Leaving"]
bohanlon has quit [Remote closed the connection]
bohanlon has joined #ocaml
<zeeeeee>
is there a version of Marshal that produces human-readable serializations?
<zeeeeee>
(a la 'show'/'read' in haskell)
<pango>
check the Hump for sexplib, json-wheel,...
<zeeeeee>
pango: thanks
<zeeeeee>
how do i make a class obj containing a Set of obj?
<zeeeeee>
it's like the chicken and egg problem - if i first instantiate the module, obj is undefined, but if i first define the class, i haven't instantiated the Set yet
b00t has quit [Connection reset by peer]
b00t has joined #ocaml
love-pingoo has quit ["Connection reset by pear"]
<flux->
I think you need to go via class types: class type base = object .. end module ObjSet = Set.Make (struct type t = base let compare = compare end) class actual_class = object val s = ObjSet.empty .. end
<flux->
make that actual_class : base
velco has joined #ocaml
love-pingoo has joined #ocaml
vorago has quit [Read error: 113 (No route to host)]
cpfr has joined #ocaml
<cpfr>
howdy
<love-pingoo>
yo
<cpfr>
got a quick q
<cpfr>
im building a program for someone who doesnt have ocaml
<cpfr>
how do i statically compile my program if it uses libs
<cpfr>
like unix.cma etc
<love-pingoo>
ocaml libs or C libs ?
<cpfr>
ocaml libs
<love-pingoo>
it's always static
<cpfr>
oh well thats nice
<love-pingoo>
the only thing you have to worry about is not to build an executable requiring ocamlrun if you're compiling to bytecode
<love-pingoo>
make sure to use -custom
<cpfr>
im compiling to machine code
<love-pingoo>
no worry, then
<cpfr>
excellent
<cpfr>
so if i am using an ocaml lib that is a binding to a c lib
<cpfr>
that will still be dynamically linked
<cpfr>
or will that get statically linked
<love-pingoo>
not sure about the piece of C code
<cpfr>
can i run ldd to check?
<love-pingoo>
it'll say that you don't need the stub C code
<love-pingoo>
and I think it's right...
<love-pingoo>
actually I run a custom bytecode executable without installing the C bindings on which it depends
<love-pingoo>
yeah, the only dynamic stuff is the real C dynamic lib
<cpfr>
well thanks this is all great news
jlouis has quit [Remote closed the connection]
vorago has joined #ocaml
cypher23 has joined #ocaml
jlouis has joined #ocaml
ikaros has quit [Read error: 110 (Connection timed out)]
ikaros has joined #ocaml
bzzbzz has quit ["leaving"]
ramkrsna has joined #ocaml
cpfr has left #ocaml []
b00t has quit ["Leaving"]
swater has joined #ocaml
nucleos has joined #ocaml
<nucleos>
hello
pango has quit [Remote closed the connection]
love-pingoo has quit ["Leaving"]
pango has joined #ocaml
Smerdyakov has joined #ocaml
diffbavis has joined #ocaml
pango has quit [Remote closed the connection]
benny_ has joined #ocaml
<nucleos>
i've installed tuareg-mode, but i don't see syntax highlighting as i type in a buffer... Can someone help me?
nucleos has quit ["ChatZilla 0.9.77 [Firefox 2.0.0.2/0000000000]"]
pango has joined #ocaml
benny has quit [Read error: 110 (Connection timed out)]
Lacrimosa has joined #ocaml
<Lacrimosa>
:)
<Lacrimosa>
Can I ask something? Is there a mechanism in Ocaml for dynamic bytecode generation and execution, runtimely?
<Lacrimosa>
You know, there are a lot of Java and .NET libraries for dynamic bytecode generation - what about Ocaml ?
vorago has quit [No route to host]
<mbishop>
er
<mbishop>
I'm not sure what you mean, but perhaps you want MetaCaml?
<mbishop>
MetaOCaml[4] is a multi-stage programming extension of OCaml enabling incremental compiling of new machine code during runtime. Under certain circumstances, significant speedups are possible using multi-stage programming, because more detailed information about the data to process is available at runtime than at the regular compile time, so the incremental compiler can optimize away many cases of condition checking etc.
<mbishop>
says wikipedia
velco has quit ["<boris``> reduction ad absurdum is a fallacious method of proof"]
shawn has quit ["This computer has gone to sleep"]
<Smerdyakov>
Lacrimosa, for what applications do you want that functionality?
vorago has joined #ocaml
<Lacrimosa>
Smerdyakov: code persistance in a BerkleyDB database.
<Smerdyakov>
You want to store code in a database, you mean?
<Lacrimosa>
Smerdyakov: Yeah, like stored procedures, but in a flat db file
<Smerdyakov>
And simple dynamic loading isn't good enough for you?
<Smerdyakov>
I know OCaml bytecode has dynamic linking.
<Lacrimosa>
Smerdyakov: well i have to compile that...i need a faster solution
<Smerdyakov>
There just isn't any special support for compilation, that I know of.
<Smerdyakov>
Why do you need a faster solution? Creation of new stored procedures is in your critical path performancewise?
<Lacrimosa>
well i could dynamically generate machine code but..i thought there might be a proven solution already
<Smerdyakov>
The OCaml compilers are used a lot. I would consider any solution that depends on them "proven."
<Lacrimosa>
but they're relatively slow for that specific kind of procedures...
<Smerdyakov>
Why does it matter have compilation is slow?
<Smerdyakov>
s/have/if
<Lacrimosa>
well ...it's an OLTP database... about 40 transactions per second per CPU
<Lacrimosa>
itanium2
<Lacrimosa>
linux
<Smerdyakov>
So? Do transactions create new stored procedures?
<Lacrimosa>
yah its possible...there will be situations where most of the transactions will do exactly that - modify existing stored procedures
<Smerdyakov>
OK, thank you. Now I understand.
<Lacrimosa>
and that must be done realtime u know
<Smerdyakov>
So you really have situations where "regular users" are modifying stored procedures frequently, not just relatively rare batches of changes performed by "admins"?
<Lacrimosa>
well it's a component-based SOA system, so RPC calls really
<Smerdyakov>
That doesn't answer my question.
<Lacrimosa>
from time to time
<Smerdyakov>
What can a "regular user" do to modify a stored procedure?
<Lacrimosa>
~25
<Lacrimosa>
%
<Lacrimosa>
no regular users or something...that isnt really directly connected to the end user
<Smerdyakov>
Well, I propose you try doing it with ocamlc and dynamic linking. Run some experiments to see if performance is acceptable.
<Lacrimosa>
it isnt at all, what i need is a lightweight library ...well something like LLVM's C++ API
ppsmimou has quit ["Leaving"]
<Lacrimosa>
thank you anyway
ppsmimou has joined #ocaml
Lacrimosa has left #ocaml []
smimou has joined #ocaml
Mr_Awesome has joined #ocaml
joelr1 has joined #ocaml
<joelr1>
good day
<joelr1>
i'm doing something simple that's not working