gildor changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | OCaml 3.12.1 http://bit.ly/nNVIVH
tufisi has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
emmanuelux has quit [Quit: emmanuelux]
hongboz has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 264 seconds]
hongboz has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
cdidd has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 252 seconds]
ulfdoz_ has joined #ocaml
ulfdoz has quit [Read error: Operation timed out]
ulfdoz_ is now known as ulfdoz
lggr has joined #ocaml
ghostbuster2 has quit [Ping timeout: 246 seconds]
<_habnabit> arrrrgh
<_habnabit> is there a tuareg-mode or a way of loading it that doesn't automatically set a bunch of faces? (cc thelema)
<_habnabit> for some reason my new theme doesn't come with faces preset for tuareg!!
lggr has quit [Ping timeout: 264 seconds]
ghostbuster2 has joined #ocaml
lggr has joined #ocaml
Yoric has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 265 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
madroach has quit [Ping timeout: 265 seconds]
madroach has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
Yoric has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
lggr has joined #ocaml
sivoais has quit [Quit: Lost terminal]
sivoais has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
Yoric has quit [Ping timeout: 240 seconds]
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
Playground has quit [Ping timeout: 264 seconds]
lggr has quit [Ping timeout: 248 seconds]
lggr has joined #ocaml
Automorphism has joined #ocaml
Automorphism is now known as Playground
lggr has quit [Ping timeout: 248 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
hongboz has quit [Ping timeout: 245 seconds]
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
Playground has quit [Ping timeout: 245 seconds]
Playground has joined #ocaml
lggr has quit [Ping timeout: 265 seconds]
lggr has joined #ocaml
Yoric has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
Ptival_ is now known as Ptival
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
pqmodn has quit [Changing host]
pqmodn has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
Playground has quit [Ping timeout: 264 seconds]
Playground has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
Yoric has quit [Ping timeout: 256 seconds]
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
ghostbuster2 has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
<adrien> morning
<pippijn> morning
<pippijn> do you know how to use oasis or ocamlbuild to link against a C library?
lggr has joined #ocaml
<pippijn> use_lib, maybe
<pippijn> nope.. not that
<pippijn> ah, CCLib in oasis
lggr has quit [Ping timeout: 246 seconds]
Playground has quit [Ping timeout: 256 seconds]
Playground has joined #ocaml
lggr has joined #ocaml
<adrien> yes
<adrien> glad to have helped you
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
orbitz has quit [Ping timeout: 240 seconds]
sgnb has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
orbitz has joined #ocaml
testcocoon has quit [Quit: Coyote finally caught me]
lggr has joined #ocaml
testcocoon has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
Playground has quit [Quit: leaving]
Playground has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
pango is now known as pangoafk
ankit9 has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
Snark has joined #ocaml
lggr has quit [Ping timeout: 248 seconds]
lggr has joined #ocaml
ankit9 has quit [Ping timeout: 256 seconds]
ontologiae has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
djcoin has joined #ocaml
lggr has joined #ocaml
ankit9 has joined #ocaml
Cyanure has joined #ocaml
hkBst has joined #ocaml
hkBst has quit [Changing host]
hkBst has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
sepp2k has joined #ocaml
lggr has joined #ocaml
eni has joined #ocaml
Yoric has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
hnrgrgr_ is now known as hnrgrgr
Cyanure has quit [Remote host closed the connection]
ontologiae has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
bobry has quit [Quit: Connection closed for inactivity]
mika1 has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
eikke has joined #ocaml
lggr has joined #ocaml
chambart has joined #ocaml
lggr has quit [Ping timeout: 265 seconds]
lggr has joined #ocaml
paolooo has joined #ocaml
ontologiae has joined #ocaml
paolooo has quit [Client Quit]
paolooo has joined #ocaml
eni has quit [Ping timeout: 256 seconds]
osa1__ has quit [Quit: Konversation terminated!]
cdidd has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
ankit9 has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
Snark has quit [Ping timeout: 246 seconds]
Yoric has quit [Ping timeout: 252 seconds]
hkBst_ has joined #ocaml
hkBst_ has quit [Changing host]
hkBst_ has joined #ocaml
lggr has quit [Ping timeout: 265 seconds]
hkBst has quit [Ping timeout: 246 seconds]
sithisbitch has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
ansx_ has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
brendan has quit [*.net *.split]
willb has quit [*.net *.split]
pngl has joined #ocaml
dsheets has quit [*.net *.split]
willb has joined #ocaml
ansx has quit [Ping timeout: 264 seconds]
dsheets has joined #ocaml
lggr has joined #ocaml
Kakadu has joined #ocaml
companion_cube has quit [*.net *.split]
vbmithr has quit [*.net *.split]
companion_cube has joined #ocaml
vbmithr has joined #ocaml
dsheets has quit [Ping timeout: 250 seconds]
beckerb has joined #ocaml
brendan has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
eni has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
ankit9 has joined #ocaml
Playground has left #ocaml []
lggr has quit [Ping timeout: 252 seconds]
tufisi has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
eni has quit [Quit: Leaving]
lggr has quit [Ping timeout: 264 seconds]
lggr has joined #ocaml
ankit9 has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 245 seconds]
osa1 has joined #ocaml
Kakadu has quit [Changing host]
Kakadu has joined #ocaml
pngl has quit [Ping timeout: 246 seconds]
sithisbitch has quit [Quit: Leaving]
sithisbitch has joined #ocaml
lggr has joined #ocaml
cixaxa has joined #ocaml
tufisi has quit [Ping timeout: 248 seconds]
ankit9 has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
ankit9 has quit [Ping timeout: 246 seconds]
Kakadu_ has joined #ocaml
lggr has joined #ocaml
Automorphism has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
lggr has joined #ocaml
TDJACR has quit [Read error: Operation timed out]
lggr has quit [Ping timeout: 245 seconds]
_andre has joined #ocaml
Yoric has joined #ocaml
lggr has joined #ocaml
<hcarty> thelema: Those are probably the last updates I'll be able to do for at least a few days. But at this point I think BatBounded at least in a useful state.
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
<pippijn> how would one normally go about passing "string array" as "char**" to C?
lggr has quit [Ping timeout: 244 seconds]
<pippijn> thanks
lggr has joined #ocaml
<hcarty> You're welcome
ontologiae has quit [Ping timeout: 248 seconds]
lggr has quit [Ping timeout: 248 seconds]
Submarine has joined #ocaml
Submarine has quit [Changing host]
Submarine has joined #ocaml
lggr has joined #ocaml
<Kakadu_> pippijn: You're implementing Qt bindings already?
lggr has quit [Ping timeout: 252 seconds]
osa1 has quit [Quit: Konversation terminated!]
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
Automorphism has quit [Quit: leaving]
lggr has quit [Ping timeout: 256 seconds]
TDJACR has joined #ocaml
ontologiae has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
flux has quit [Write error: Connection reset by peer]
flx_ has joined #ocaml
flx_ is now known as flux
lggr has joined #ocaml
wtetzner has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
sithisbitch has quit [Quit: Leaving]
lggr has quit [Ping timeout: 244 seconds]
paolooo has quit [Quit: Page closed]
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
<thelema> _habnabit: afaik, tuareg-mode uses standard faces, maybe your theme isn't a programming theme and doesn't have a full array of faces
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
<pippijn> Kakadu_: just playing around
<pippijn> Kakadu_: with QList, now
lggr has joined #ocaml
<Kakadu_> pippijn: http://paste.in.ua/4792/raw/
lggr has quit [Ping timeout: 256 seconds]
<Kakadu_> pippijn: and vice versa: http://paste.in.ua/4793/#2
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
Kakadu_ has quit [Quit: Konversation terminated!]
Kakadu_ has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
<pippijn> Kakadu_: passing int by reference is making me sad
<pippijn> Kakadu_: QApplication(int&, char**)
<flux> why does it make you sad? I think the point is to be able to modify it..
<Kakadu_> pippijn: what are u looking?
<pippijn> how would you pass an ocaml int by reference?
<Kakadu_> pippijn: aaah, it is a official docs
<flux> as a ref :)
<pippijn> good idea ;)
<flux> obviously plain integer cannot be passed by reference
lggr has joined #ocaml
<Kakadu_> pippijn: I've mustered up enough courage to recommend you to think about signals/slots connection firstly
<pippijn> oh, why?
<pippijn> Kakadu_: first I want to learn how to pass things between C and ocaml
<pippijn> flux: I have a problem
smondet has joined #ocaml
<Kakadu_> Maybe that you will get an idea to subclass every Qt class for which yo wnat to create bindings
<pippijn> I need to store a pointer to that int in C code
<pippijn> for at least 2 calls
<flux> pippijn, if no callbacks are involved, you can copy the value from the ref before those calls and restore it after
<flux> (I'm guessing what your problem is :))
<pippijn> hm
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
<pippijn> ok
<pippijn> I'm going to have to do this differently
eni has joined #ocaml
eni has quit [Client Quit]
lggr has quit [Ping timeout: 245 seconds]
ollehar has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 265 seconds]
Sablier_ has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
Submarine has quit [Quit: Leaving]
lggr has quit [Ping timeout: 245 seconds]
<pippijn> is it possible to put ocaml values into my own data structure?
<pippijn> (C data structure)
<Kakadu_> C++ data structure?
<Kakadu_> I think so
<adrien> yes
<adrien> just cast
<Kakadu_> but don't forget to register roots
<adrien> but what do you want to do with?
lggr has joined #ocaml
<pippijn> ah, register roots
<pippijn> caml_register_global_root?
<Kakadu_> pippijn: something like this
<pippijn> if I put values into a QList
chambart has quit [Read error: Connection reset by peer]
<pippijn> I need to remove all roots before inserting and re-add them after?
<Kakadu_> why?
<pippijn> because inserting into a list may realloc
<Kakadu_> C++ realloc
<pippijn> yes
<pippijn> and that can (and usually will) move the data
<Kakadu_> I think it will no touch OCaml values
<pippijn> so if ocaml stores that pointer I pass it, that will be invalid after realloc
lggr has quit [Ping timeout: 244 seconds]
chambart has joined #ocaml
<Kakadu_> WHY???
<Kakadu_> OK
<Kakadu_> If you in OCaml store C++ pointer than after C++ realloc epic fail can be possible
<pippijn> no
<pippijn> that's not what I mean
<Kakadu_> but If u store in C++ OCaml value, after reallocing C++ data type it will not move OCaml value
<pippijn> vector<value> values; return custom_alloc (value);
<pippijn> now ocaml has that vector
<pippijn> ok, now I add an ocaml value to it
<pippijn> values.append(some_value);
<pippijn> so now I need to register that root, right?
<Kakadu_> yep
<pippijn> caml_register_global_root(&values.back());
<pippijn> now I add another value: values.append(another_value);
<pippijn> now C++ may realloc the vector's internal array
<pippijn> which means that the pointer to values.back() is now invalid
lggr has joined #ocaml
<Kakadu_> I don't whink so
<Kakadu_> think*
<Kakadu_> really value is int
<Kakadu_> So you have QList<int>
<Kakadu_> after internal QList reallocing ints are still the same ints
Kakadu_ has quit [Quit: Konversation terminated!]
Kakadu has quit [Quit: Page closed]
lggr has quit [Ping timeout: 256 seconds]
<_habnabit> thelema, no, tuareg doesn't use standard faces :(
<pippijn> okay, now he's gone
<pippijn> so, how would I go about keeping a dynamically resizable array of ocaml values in C?
<pippijn> while paying respect to GC roots
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
ollehar has quit [Quit: ollehar]
<hcarty> pippijn: You should be safe I think - you'd be saving pointers in the array. The pointers can move around with affecting the underlying data.
<hcarty> pippijn: This is assuming that registering a global root doesn't store a pointer to the 'value' pointer...
<hcarty> If it does then you'd need to wrap everything behind another layer of pointers.
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
hkBst_ has quit [Quit: Konversation terminated!]
lggr has joined #ocaml
ghostbuster2 has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
beckerb has quit [Quit: Konversation terminated!]
lggr has joined #ocaml
mika1 has quit [Quit: Leaving.]
lggr has quit [Ping timeout: 240 seconds]
chambart has quit [Ping timeout: 246 seconds]
Yoric has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
osa1 has joined #ocaml
Kakadu has joined #ocaml
djcoin has quit [Quit: WeeChat 0.3.7]
lggr has quit [Ping timeout: 246 seconds]
ghostbuster2 has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
Cyanure has joined #ocaml
lggr has quit [Ping timeout: 265 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
ftrvxmtrx has joined #ocaml
Xizor has joined #ocaml
pngl has joined #ocaml
lggr has joined #ocaml
err404 has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
osa1 has quit [Quit: Konversation terminated!]
lggr has quit [Ping timeout: 248 seconds]
fraggle_laptop has quit [Ping timeout: 256 seconds]
fraggle_laptop has joined #ocaml
lggr has joined #ocaml
chambart has joined #ocaml
<thelema> _habnabit: oh. :( I wonder why it seems to work with the color scheme I picked on a fresh install
<_habnabit> thelema, it could be that it was similar enough to your existing theme
<_habnabit> thelema, also, it doesn't use _entirely_ its own faces. just a few
Yoric has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
<thelema> _habnabit: could be... Maybe we should push back onto the tuareg developers to use existing faces?
<_habnabit> thelema, haha, maybe. I'm curious what their excuse is
<thelema> probably "no existing face was what we needed"
pangoafk is now known as pango
lggr has joined #ocaml
fraggle_laptop has quit [Ping timeout: 265 seconds]
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
<wmeyer`> pippijn: you'd need to resort to custom C++ alocator I think
lggr has quit [Ping timeout: 256 seconds]
<wmeyer`> pippijn: of course vector will realocate, copy the C++ values, by invoking copy constructor, and then call the destructor
<wmeyer`> and BTW: you could wrap OCaml value into the C++ class
<wmeyer`> in the constructor register root, in the destructor delete root
<wmeyer`> similar strategy in the copy constructor, and default constructor
<wmeyer`> (so ignore custom allocator: you can do this purely using class)
lggr has joined #ocaml
<wmeyer`> if you ask me if it's sane that vector<Object> a(1000000); will call 1000000 copy constructor and destructor: I'd say no.
<wmeyer`> but that's how it works in the C++ world.
<pippijn> wmeyer`: I did that
<pippijn> ah no, I didn't
<pippijn> that is actually probably a good idea, though
<pippijn> right now, I remove/register all roots on every append: http://paste.xinu.at/Jr8OU/
<pippijn> but I can wrap it and only re-register when the actual realloc happens
<pippijn> yes, I'll do that
<pippijn> and it will be binary compatible with a simple "value"
<pippijn> I'm busy doing more interesting things now, though
lggr has quit [Ping timeout: 265 seconds]
<wmeyer`> there is almost always something more interesting than delving into C++ pie of sheit :-)
<wmeyer`> pippijn: I'm getting ready still to try out your frontend....
<wmeyer`> but stay tuned, for sure i want to use it instead of CIL
<wmeyer`> and at some point this requirment will converge
sepp2k1 has joined #ocaml
lggr has joined #ocaml
sepp2k has quit [Ping timeout: 246 seconds]
julm has quit [Ping timeout: 265 seconds]
julm has joined #ocaml
Sablier_ has quit [Ping timeout: 265 seconds]
lggr has quit [Ping timeout: 264 seconds]
dsheets has joined #ocaml
<pippijn> I just encountered my first use for phantom types
lggr has joined #ocaml
<thelema> pippijn: and? happy with them?
<pippijn> yes
<pippijn> very
lggr has quit [Ping timeout: 246 seconds]
Snark has joined #ocaml
<wmeyer`> pippijn: they rock with polymorphic variants
<thelema> wmeyer`: quite.
<pippijn> wmeyer`: http://paste.xinu.at/6BBn41/
lggr has joined #ocaml
<jonafan> haha one of my coworkers wrote an O(n^4) script and wondered why it was taking like 100 hours to process 40k records
<thelema> hah
<jonafan> i rewrote it as O(n log n) and await him running it after lunch
<jonafan> i expect it will take less than 10 seconds
Automorphism has joined #ocaml
lggr has quit [Ping timeout: 265 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
ftrvxmtrx has quit [Ping timeout: 245 seconds]
cixaxa has quit [Ping timeout: 240 seconds]
err404 has quit [Remote host closed the connection]
sepp2k1 has quit [Read error: Connection reset by peer]
<pippijn> how can I call ocaml class methods from C?
<nicoo> jonafan: Does he know anything about complexity ? o_O
<Kakadu> pippijn: easily :-)
<thelema> pippijn: 19.3.5 Objects
<thelema> (in the ocaml manual)
<pippijn> aha
<pippijn> I knew it
<pippijn> ocaml methods are hash lookups
lggr has joined #ocaml
BiDOrD has joined #ocaml
nicoo is now known as Uma
Automorphism has quit [Ping timeout: 252 seconds]
<pippijn> okay, looks good
<Uma> pippijn: Hey, what did you expect ?
<pippijn> looks very good, in fact
Uma is now known as nicoo
<pippijn> excellent :)
<pippijn> nicoo: that makes things a lot easier for me
sepp2k has joined #ocaml
<nicoo> What do you want to achieve ?
sepp2k has quit [Client Quit]
<pippijn> Qt bindings
<nicoo> Oh
chambart has quit [Ping timeout: 248 seconds]
* nicoo wishes you luck
<pippijn> my first test succeede
<pippijn> -e
BiDOrD_ has quit [Ping timeout: 264 seconds]
<pippijn> eh
<pippijn> succeeded*
<pippijn> I created a window with a button in it
<nicoo> \o/
<pippijn> about 750 lines of code
lggr has quit [Ping timeout: 248 seconds]
ontologiae has quit [Ping timeout: 240 seconds]
ftrvxmtrx has joined #ocaml
lggr has joined #ocaml
gnuvince has quit [Quit: Remember when men were men and regular expressions recognized regular languages?]
eni has joined #ocaml
<jonafan> no nicoo, his talents lie in other realms
<nicoo> jonafan: Yes, but it seems important to know a bit about complexity, in order to write non-horrifyingly-inefficient programs
lggr has quit [Ping timeout: 264 seconds]
lggr has joined #ocaml
<jonafan> i tried to explain what i meant by O(n^4) and the problems that can easily arrive with loops inside loops inside loops inside loops
<thelema> just do some counting - how many times does the middle block inside all the loops have to run...
lggr has quit [Ping timeout: 265 seconds]
ankit9 has joined #ocaml
lggr has joined #ocaml
cdidd has quit [Remote host closed the connection]
hongboz has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
<pippijn> Kakadu: http://paste.xinu.at/2LWz/
<hcarty> pippijn: Very nice
julm has quit [Ping timeout: 245 seconds]
Sablier_ has joined #ocaml
lggr has joined #ocaml
<Kakadu> pippijn: you are on the top of the iceberg
avsm has joined #ocaml
avsm has quit [Client Quit]
<pippijn> I think I'm going into the right direction
<Kakadu> yeah
<Kakadu> pippijn: I can recommend you to think about signals and slotes
lggr has quit [Ping timeout: 248 seconds]
osa1 has joined #ocaml
lggr has joined #ocaml
<Kakadu> pippijn: You can take slots and signal signatures like here: https://github.com/Kakadu/lablqt/wiki/Type-safe-connection-from-signals-to-slots
<pippijn> ah
<pippijn> I'm not going there, yet
<pippijn> I havea different approach
<Kakadu> pippijn: Also, are u planning to allow user to inherit OCaml's QWidget class?
TDJACR has quit [Disconnected by services]
lggr has quit [Ping timeout: 256 seconds]
<Kakadu> pippijn: I'm going to say that You can't listen key press events without overriding QWidget's keyPressEvent(QKeyEvent*) method
cdidd has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
ontologiae has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 265 seconds]
emmanuelux has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
ankit9 has quit [Ping timeout: 264 seconds]
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
<pippijn> meh
<pippijn> Kakadu: QApplication keeps the reference to argc
<Kakadu> and?
<pippijn> it's annoying
<pippijn> because I freed it
<pippijn> and then it died
ankit9 has joined #ocaml
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
err404 has joined #ocaml
cdidd has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 244 seconds]
lggr has joined #ocaml
<adrien> <3
lggr has quit [Ping timeout: 248 seconds]
<pippijn> Kakadu: http://paste.xinu.at/RWc/
<Kakadu> And now
<Kakadu> if you add this object somewhere
Submarine has joined #ocaml
Submarine has quit [Changing host]
Submarine has joined #ocaml
lggr has joined #ocaml
<pippijn> what do you mean?
<Kakadu> I'm very slow thinking.... omg
<Kakadu> How Qt knows that you have overriden some methods?
<pippijn> subclassing QWidget
<Kakadu> in C++ code?
<pippijn> yes
<Kakadu> OK
<pippijn> the C++ code then finds the ocaml method
<pippijn> if it exists, it's called
<Kakadu> So you call OCaml realization in every method?
<pippijn> yes
<Kakadu> and it method is not overriden it calles default Qt realization from superclass
<pippijn> the only other way would be to build vtables at runtime
<Kakadu> if*
<pippijn> yes
<adrien> how much C++ code does that require?
<Kakadu> pippijn: How you envented this realization so fast?
<pippijn> quite much
lggr has quit [Ping timeout: 256 seconds]
<Kakadu> invented*
<pippijn> maybe I can reduce it a little
<pippijn> 724 total
Snark has quit [Quit: Quitte]
<adrien> bah, compiling C++ for each file sounds annoying
<pippijn> hm?
<adrien> I need sleep right now :-)
<pippijn> me too
<pippijn> it's 4:30
_andre has quit [Quit: leaving]
<pippijn> 160 lines of ocaml code
lggr has joined #ocaml
<pippijn> by the way, the C++ side is completely broken regarding GC handling
<pippijn> I'm supposed to register local variables as roots, etc.
<pippijn> CAMLlocal1
<jonafan> based on the fact taht my version of this script took 2 minutes to run, i estimate that his version would have taken 16 million years
tufisi has joined #ocaml
<thelema> jonafan: not quite 10 seconds?
<jonafan> he came up with an estimate of 66 hours by running the script on 100 records and multiplying
<thelema> hmm n^4...
<thelema> so it took 40 minutes on 100 records?
<jonafan> i guess it must have
<thelema> I only get 7000 years
<jonafan> i'm not sure though, this script has a print statement for every record which probably slowed it down a lot
<thelema> 40 minutes * (100^4) = 7 605.30351 years
lggr has quit [Ping timeout: 248 seconds]
<thelema> well, at least you processed 100* more records in 1/20th the time
<jonafan> i sort of did 40k * log 40k = 120s
<thelema> oh, 40k records?
<jonafan> i dunno if that's a good way to do it
<jonafan> i actually don't know how many records there were either
<jonafan> i think it was about 40k though
<jonafan> i don't have the data but i kinda looked at it yesterday to figure out what he was doing
<thelema> then his solution would take 1.9 million years, if it was really an n^4 algorithm
<thelema> anyway...
lggr has joined #ocaml
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
<nicoo> jonafan: What is the script supposed to do, btw ?
Xizor has quit []
<jonafan> it calculates weighted averages of west nile virus infection rates i think
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
tufisi has quit [Ping timeout: 264 seconds]
<nicoo> He managed to do so in n^4 ?
<jonafan> impressive incompetence
<jonafan> he's a researcher, not a programmer
<jonafan> he writes papers
lggr has quit [Ping timeout: 244 seconds]
<jonafan> that's the difference between a computer scientist and a scientist with a computer i guess
ontologi1e has joined #ocaml
Cyanure has quit [Quit: Quitte]
ontologiae has quit [Ping timeout: 264 seconds]
Yoric has quit [Ping timeout: 252 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 244 seconds]
eni has quit [Quit: Leaving]
ankit9 has quit [Quit: Leaving]
lggr has joined #ocaml
lggr has quit [Ping timeout: 248 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 248 seconds]
lggr has joined #ocaml
foo303_ is now known as foo303
eikke has quit [Ping timeout: 248 seconds]
hongboz has quit [Ping timeout: 256 seconds]
Kakadu has quit [Quit: Konversation terminated!]
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
cdidd has joined #ocaml
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ocaml
ontologi1e has quit [Quit: leaving]
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ocaml
hongboz has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
smondet has quit [Quit: bye]
lggr has joined #ocaml
pngl has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 246 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
err404 has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 256 seconds]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
ghostbuster2 has joined #ocaml
emmanuelux has quit [Quit: emmanuelux]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
lopex has quit [Remote host closed the connection]
joewilliams has quit [Remote host closed the connection]
lggr has joined #ocaml
lggr has quit [Ping timeout: 256 seconds]
joewilliams has joined #ocaml
lggr has joined #ocaml
lggr has quit [Ping timeout: 246 seconds]
lopex has joined #ocaml
lopex has quit [Remote host closed the connection]
lggr has joined #ocaml
joewilliams has quit [Remote host closed the connection]
lopex has joined #ocaml
joewilliams has joined #ocaml
TaXules has quit [Ping timeout: 245 seconds]
lggr has quit [Ping timeout: 264 seconds]
lggr has joined #ocaml
TaXules has joined #ocaml
lggr has quit [Ping timeout: 264 seconds]
hongboz has quit [Remote host closed the connection]
Sablier_ has quit []
lggr has joined #ocaml
Submarine has quit [Ping timeout: 252 seconds]