cjeris changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/
vital303 has joined #ocaml
skal_ has quit [Read error: 104 (Connection reset by peer)]
joshcryer has joined #ocaml
pedro_ has joined #ocaml
pedro_soc has quit [Read error: 113 (No route to host)]
flux has quit [Read error: 101 (Network is unreachable)]
flux has joined #ocaml
david_koontz has quit ["Leaving"]
<mrvn> pango_: that doesn't realy scale, not tail recursive. :)
<tsuyoshi> there's a function for doing that in extlib
dark_light has joined #ocaml
dark_ has joined #ocaml
pstickne has joined #ocaml
dark_light has quit [Read error: 113 (No route to host)]
pstickne has quit [Read error: 145 (Connection timed out)]
pstickne has joined #ocaml
flux has quit [Read error: 104 (Connection reset by peer)]
flux has joined #ocaml
vorago has quit [Read error: 113 (No route to host)]
joshcryer has quit [Client Quit]
joshcryer has joined #ocaml
Smerdyakov has quit ["Leaving"]
<pango_> mrvn: since it's a given, I chose the most readable implementation
Submarine has joined #ocaml
revence has joined #ocaml
<revence> What is the bot here called?
<revence> And, in what language is Ocaml written?
<pango_> OCaml is written in OCaml
<pango_> some parts of the runtime are in C, I believe
<revence> pango_: Oh. Good, then.
<revence> There seems to be no bot here.
* revence thinks he should write an IRC bot in Ocaml ... and wonders if he'll get support ...
<revence> I'm just starting out with Ocaml. (Because I want to write F#, which is Ocaml-based).
<revence> The bot would be a nice project to acquaint me with the language.
bohanlon has joined #ocaml
<revence> So, nobody has an IRC bot for #ocaml?
* revence wants an excuse to try kicking one ... and maybe transplant it to F#. :oD
<pango_> clog logs the channel for http://tunes.org/~nef/logs/ocaml/ I don't remember seeing other kinds of bots here
vorago has joined #ocaml
<revence> I'll try to hack on one.
<revence> Must confess it is envy for the #haskell bot, which is such a utility over there.
revence has quit [""Okay. let rec usual_routine x = usual_routine x;; usual_routine 1000;;""]
<flux> hmm.. a similar one might be possible in ocaml too, but it would require a camlp4 module to forbid certain structures, such as references to external symbols ("extern") and using certain modules ("Unix") and even certain functions from certain modules ("Pervasives.open_out")
<flux> I suppose doing the last one would be a blanket block on using symbol name "open_out"?
<flux> actually, a better solution would be to compile an ocaml with a new pervasives library, that excluded all kinds of stuff
<flux> but the "extern"-block would still need to be implemented.
<flux> actually that sounds like a fun project ;)
<flux> I doubt you would be able to dynamically link code compiled in such fashion to an existing program, though, as the module interfaces would differ
<flux> but you could run the compiled code as an external process, with certain limits (cpu-time, memory, etc)
vital303 has quit [Read error: 145 (Connection timed out)]
jlouis_ has quit [Remote closed the connection]
skal has joined #ocaml
joshcryer has quit [Client Quit]
<pedro_> hi, Im trying to use GLDraw in the interactive interpreter, How can i bound to this library?
<pedro_> the error : Unbound value GlDraw.viewport.
<flux> I haven't used opengl for quite a while from ocaml, but maybe something like #use "topfind";; #require "lablgl";; would suffice?
<flux> (I don't know how GlDraw relates to lablgl, if it even does ;-))
slipstream has joined #ocaml
slipstream-- has quit [Read error: 60 (Operation timed out)]
benny_ has joined #ocaml
benny has quit [Read error: 60 (Operation timed out)]
<pedro_> umm i must install the lablgl package on my linux :)
<pedro_> and then i can comile the code.
<flux> yeah, I think that's a good start..
<flux> hmm.. is 'assert (print_string "foo"; true)' something the compiler is allowed to optimize away when you compile with -noassert?
<flux> evaluation order would say "no"
Celos has joined #ocaml
<Celos> hi, i've installed ocaml on my linux distrib, it works fine in my terminal, but i would like to know, how can i open ml file, or save, i don't find any doc about ocaml un shell
<Celos> hmm, i've just find the answer for loading file :D still looking for saving
<flux> you cannot edit and save files in ocaml
<flux> you'll use an external editor for that
<Celos> ok
<Celos> hmm, it's not possible to see the last function written when i press the up arrow key ?
<flux> celos, use rlwrap or ledit
<Celos> ok
<Celos> thx :)
mikeX has joined #ocaml
Submarine has quit [Remote closed the connection]
Celos has quit ["Quitte"]
romanoffi has quit ["Leaving."]
postalchris has joined #ocaml
postalchris has left #ocaml []
bohanlon has quit [Remote closed the connection]
postalchris has joined #ocaml
benny99 has joined #ocaml
postalchris has quit [Read error: 145 (Connection timed out)]
bluestorm_ has joined #ocaml
pango_ has quit [Remote closed the connection]
pango_ has joined #ocaml
benny99 has left #ocaml []
Riesz has quit ["Leaving.."]
postalchris has joined #ocaml
benny99 has joined #ocaml
<benny99> it's me bothering again
<benny99> What were your very first "OCAML-Beginner-Tasks" ?
<lucca> implement a mandelbrot set drawing program
<lucca> (very easy, actually!)
Smerdyakov has joined #ocaml
<benny99> lucca: something even more easy maybe ?
<benny99> lucca: I guess you didn't start with that huh ?
<lucca> well, hello world?
<benny99> lucca: something less easy :p
<benny99> lucca: hm, I'll read that book till I think that I'm able to do something, maybe that helps the most :|
<benny99> thanks
benny99 has left #ocaml []
<mrvn> lucca: I did that in ocaml with both text mode output and graphics module. But ocaml is really slow in both floats and gfx.
<mrvn> And I implemented the M-Set a 3rd time when I looked at interfacing with C. Move the main loop into C code. :)
<lucca> heh
<lucca> mrvn: even slower if you use the Complex type
<Smerdyakov> You wouldn't need to do that if you were using MLton. ;)
<lucca> but it makes a very pretty hello world
<lucca> which was all I needed
<mrvn> lucca: My code is optimized for the M-Set. With complex you have operations that are not neccessary.
<mrvn> Smerdyakov: You wouldn't need it if the ocaml compiler would unbox floats. I tried it on alpha where it seemed to never unbox them.
<lucca> if you want a good fast program, you're right
<lucca> if you want a learning tool with maximal clarity and ease of learning, no
Sparkles has joined #ocaml
<lucca> someday it'd be nice if the compiler could trace out the flow of the complexes and simplify it to exactly what is needed by the code And unbox floats... but in the meantime it's fine if it just works
<Smerdyakov> lucca, just use SML & MLton... ;D
<mrvn> let rec loop n z = if (n >= nmax) then n else if Complex.abs z > 4. then n else loop (n+1) (Complex.add (Complex.mul z z) z0)
<lucca> Smerdyakov: nah, already moving on to haskell :p
<Smerdyakov> lucca, why?
<mrvn> The thing is that you can use parts of the Complex.abs in the Complex.mul and you can use Complex.abs ^ 2 so you don't have to use sqrt()
<mrvn> And even better if you transform the formula and don't check for bailout every iteration.
<lucca> Smerdyakov: lazy eval, monad transformers, deriving
<mrvn> Smerdyakov: ever looked at the asm code for the M-set loop in MLton?
<Smerdyakov> mrvn, I don't know what "M-set" is.
<mrvn> Smerdyakov: Mandelbrot set
<lucca> Mandelbrot set
<Smerdyakov> lucca, you can use monad transformers in ML.
<Smerdyakov> lucca, and there is also opt-in lazy evaluation.
<lucca> Smerdyakov: well I'm looking at the ML's again now
pango_ has quit [Remote closed the connection]
pango_ has joined #ocaml
Sparkles has quit []
bluestorm_ has quit ["Konversation terminated!"]
postalchris has quit ["Leaving."]
postalchris has joined #ocaml
Submarine has joined #ocaml
z__z has joined #ocaml
<postalchris> ocamlcp + camlp4: anybody have a well-worn strategy for making this happen?
benny99 has joined #ocaml
<benny99> wui, 53 people ;)
bsmith has quit [Remote closed the connection]
bsmith has joined #ocaml
benny99 has left #ocaml []
vital303 has joined #ocaml
jlouis has joined #ocaml
postalchris has quit ["Leaving."]
_JusSx_ has joined #ocaml
_JusSx_ has quit ["leaving"]
vital303 has quit ["Leaving."]
vital303 has joined #ocaml
postalchris has joined #ocaml
vital303 has quit [Remote closed the connection]
Mr_Awesome has joined #ocaml
postalchris has quit ["Leaving."]
Mr_Awesome has quit ["...and the Awesome level drops"]