mbishop changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | Grab Ocaml 3.10.0 from http://caml.inria.fr/ocaml/release.html (featuring new camlp4 and more!)
benny_ has joined #ocaml
tehdeuce has joined #ocaml
<tehdeuce> Would it be possible to write a function that takes a number as an input and then consumes that many arguments (ie, you could write consume 2 x y, and it would consume x and y and do nothing with them)?
<zmdkrbou> nope
<zmdkrbou> you couldn't give a type to this function
<zmdkrbou> (that's why the type of printf is an ugly hack in ocaml)
<tehdeuce> It wouldn't be possible even with -rectypes?
<tehdeuce> Excuse my ignorance. I'm not completely sure how rectypes works
<zmdkrbou> it's not a recursive type problem, no
noteventime has quit [Remote closed the connection]
<tehdeuce> okay. Thanks for the help
benny has quit [Read error: 110 (Connection timed out)]
piggybox5 has joined #ocaml
piggybox has quit [Nick collision from services.]
jatqceer has joined #ocaml
jatqceer has left #ocaml []
tehdeuce has quit ["Leaving."]
yzx has joined #ocaml
yzx has left #ocaml []
kosmikus has quit [Remote closed the connection]
kosmikus has joined #ocaml
_blackdog has quit ["Ex-Chat"]
<psnively> Hmmm. Seems like that should be doable with a polymorphic Y combinator.
seafoodX has joined #ocaml
psnively has quit []
Clintach_ has joined #ocaml
seafoodX has quit [heinlein.freenode.net irc.freenode.net]
kosmikus has quit [heinlein.freenode.net irc.freenode.net]
piggybox5 has quit [heinlein.freenode.net irc.freenode.net]
benny_ has quit [heinlein.freenode.net irc.freenode.net]
Foxyloxy has quit [heinlein.freenode.net irc.freenode.net]
slipstream-- has quit [heinlein.freenode.net irc.freenode.net]
vincenz has quit [heinlein.freenode.net irc.freenode.net]
vorago has quit [heinlein.freenode.net irc.freenode.net]
z__z has quit [heinlein.freenode.net irc.freenode.net]
vincenz has joined #ocaml
benny has joined #ocaml
z__z has joined #ocaml
slipstream has joined #ocaml
Foxyloxy has joined #ocaml
seafoodX has joined #ocaml
piggybox has joined #ocaml
kosmikus has joined #ocaml
piggybox5 has joined #ocaml
slipstream-- has joined #ocaml
vorago has joined #ocaml
kosmikus has quit [Success]
slipstream-- has quit [Connection reset by peer]
vorago has quit [Read error: 104 (Connection reset by peer)]
vorago has joined #ocaml
piggybox5 has quit [No route to host]
kosmikus has joined #ocaml
<lde> type 'a f = 'a -> 'a f;;
<lde> let rec f x :'a f = f;;
<lde> Why does f 23 goes into an endless loop?
<flux> I don't know, but it works if you don't run ocaml in -rectypes and use an explicity constructor instead
<lde> flux: You mean something like type 'a f = F of ('a -> 'a f)?
<flux> yes
<lde> And how would I use it?
<lde> let rec f x :'a f = (F f)?
<flux> yes
<lde> Without :'a f even.
<flux> well, you can put the 'a f there if you want
<lde> But in this case f x evaluates to F f
<lde> Yes, i mean it's not needed now.
<lde> Hm.
<lde> I'd have to define another function taking (F f) as an argument.
<lde> To use it in any way.
<lde> Right?
<flux> you could use let get_f (F f) = f to extract the function
<flux> maybe someone on the caml mailing list could tell if that infinite loop is a bug or a feature
<lde> Right, but i wanted to do f 1 2 3 4 ... (No, not for any particular reason ;-).
<flux> perhaps you can't :)
<lde> Oh well.
<lde> Thanks.
<flux> hm
<flux> you could define something like let (++) (F f) n = f n
<flux> but it wouldn't be the same, would it..
<flux> but it would allow you to write f 42 ++ 44 ++ 64 etc.. perhaps you could pick a nicer operator
<lde> Yes, that's pretty close. :-)
ygrek has joined #ocaml
jlouis has joined #ocaml
xavierbot has joined #ocaml
<rwmjones> (object method m = "morning" end) # m;;
<xavierbot> - : string = "morning"
Foxyloxy has quit ["Sausages!"]
<ygrek> Sys.ocaml_version;;
<xavierbot> Characters 1-18:
<xavierbot> Sys.ocaml_version;;
<xavierbot> ^^^^^^^^^^^^^^^^^
<xavierbot> Unbound value Sys.ocaml_version
<flux> 4;;3;;
<xavierbot> - : int = 4
<flux> let _ = ();;
<xavierbot> - : unit = ()
<flux> type 'a f = F of ('a -> 'a f) let rec f x = F f let (++) (F f) x = f x let _ = f 42 ++ 44 ++ 22;;
<xavierbot> type 'a f = F of ('a -> 'a f)
<lde> let rec f () = f () in f ();;
<xavierbot> Characters 31-34:
<xavierbot> Parse error: [binding] expected after [opt_rec] (in [str_item])
<xavierbot> Characters 5-8:
<xavierbot> Parse error: illegal begin of top_phrase
<lde> hm
<lde> while true do () done;;
<xavierbot> Characters 9-10:
<xavierbot> while true do () done;;
<xavierbot> ^
<xavierbot> Unbound value f
<flux> unbound value f, hm?-)
<lde> true;;
<xavierbot> Characters 1-5:
<xavierbot> Parse error: [sequence] expected after "while" (in [expr])
<xavierbot> true;;
<xavierbot> ^^^^
<flux> let _ = while true do () done;;
<flux> uh oh :)
jlouis_ has quit [Read error: 110 (Connection timed out)]
<lde> 23;;
<rwmjones> the subprocess should die after 60 seconds of CPU, then restart
<rwmjones> that's the theory anyway ...
<flux> hmph
<flux> 60 seconds is a lot, imo
<flux> 5 seconds would be more suitable
<rwmjones> yup
<rwmjones> but remember that it's n seconds over the lifetime of the process
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<flux> heh, restart :)
<rwmjones> worked as well, amazing :-)
<rwmjones> print_endline "am I ok?";;
<xavierbot> am I ok?
<xavierbot> - : unit = ()
Clintach_ has quit [Read error: 113 (No route to host)]
<flux> how about flood prevention?
<flux> I'm not going to try that unless you say it has one :)
<rwmjones> the IRC chan itself does that
<flux> what?
<flux> does it flood itself out of the ircnet?
<flux> I was thinking more in the lines of "max 4 lines of output per query"
<lde> Apparently it does.
piggybox5 has joined #ocaml
piggybox has quit [Nick collision from services.]
<rwmjones> xavierbot, help
<xavierbot> rwmjones: expr ;; evaluate expr in OCaml toplevel
<xavierbot> rwmjones: help help message
<xavierbot> rwmjones: restart restart the toplevel
clog has joined #ocaml
noteventime has joined #ocaml
david_koontz has quit ["Leaving"]
ramkrsna has joined #ocaml
piggybox has quit []
oxylin has joined #ocaml
velco has joined #ocaml
ayrnieu has joined #ocaml
love-pingoo has joined #ocaml
oxylin has quit ["Ex-Chat"]
<love-pingoo> mmmm :\
<love-pingoo> anybody knows a way of imlementing OrderedType with a "physical" (as in (==)) ordering
<love-pingoo> ?
<love-pingoo> I'm trying to get rid of identifiers in some code, using physical equality of some record instead. But I have to hash over these things...
<love-pingoo> I'm afraid this will backfire
<rwmjones> what's OrderedType?
<zmdkrbou> the module for keys in the Map.Make functor and so on
<rwmjones> module StringSet = Map.Make (String);;
<xavierbot> module StringSet :
<xavierbot> sig
<xavierbot> type key = String.t
<xavierbot> type 'a t = 'a Map.Make(String).t
<xavierbot> val empty : 'a t
<xavierbot> val is_empty : 'a t -> bool
<xavierbot> val add : key -> 'a -> 'a t -> 'a t
<xavierbot> val find : key -> 'a t -> 'a
<xavierbot> val remove : key -> 'a t -> 'a t
<xavierbot> val mem : key -> 'a t -> bool
<xavierbot> val iter : (key -> 'a -> unit) -> 'a t -> unit
<xavierbot> val map : ('a -> 'b) -> 'a t -> 'b t
<xavierbot> val mapi : (key -> 'a -> 'b) -> 'a t -> 'b t
<xavierbot> val fold : (key -> 'a -> 'b -> 'b) -> 'a t -> 'b -> 'b
<xavierbot> val compare : ('a -> 'a -> int) -> 'a t -> 'a t -> int
<xavierbot> val equal : ('a -> 'a -> bool) -> 'a t -> 'a t -> bool
<xavierbot> end
<rwmjones> StringSet.keys;;
<xavierbot> Characters 1-15:
<xavierbot> StringSet.keys;;
<xavierbot> ^^^^^^^^^^^^^^
<xavierbot> Unbound value StringSet.keys
<ppsmimou> hum
<ppsmimou> what if I type
<ppsmimou> let () = while true do () done;;
<zmdkrbou> you're so mean :)
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
slipstream-- has joined #ocaml
<zmdkrbou> Sys.command "ls";;
<xavierbot> Characters 0-11:
<xavierbot> Sys.command "ls";;
<xavierbot> ^^^^^^^^^^^
<xavierbot> Unbound value Sys.command
<zmdkrbou> hehe
<love-pingoo> this game has been played yesterday already
<ppsmimou> zmdkrbou: tsss, I was thinking to try exactly the same thing
<love-pingoo> though I didn't see the issue
<zmdkrbou> ppsmimou: you h4x0rz
<ppsmimou> ;)
<love-pingoo> how bad can it be to cast a record to an int using Obj.magic ? I've node idea :)
<zmdkrbou> ergl
<ppsmimou> ah new fun
<rwmjones> like this?
<ppsmimou> let () = (Obj.magic 0) ^ "x";;
<xavierbot> Characters 11-20:
<xavierbot> let () = (Obj.magic 0) ^ "x";;
<xavierbot> ^^^^^^^^^
<xavierbot> Unbound value Obj.magic
<ppsmimou> too bad
<bluestorm_> love-pingoo: wouldn't Hahstbl.hash be better
<bluestorm_> ?
<rwmjones> Hashtbl.hash;;
<xavierbot> - : 'a -> int = <fun>
<ppsmimou> rwmjones: what modules does your bot have ?
<rwmjones> ppsmimou, most of them
<rwmjones> I'll upload a new version of the source so you can all check
<rwmjones> that's the latest
slipstream-- has quit [Read error: 104 (Connection reset by peer)]
<zmdkrbou> external hash_param : int -> int -> 'a -> int = "caml_hash_univ_param" "noalloc"
<zmdkrbou> let hash x = hash_param 10 100 x
<zmdkrbou> ahah love-pingoo if you want black magic, that's what you need :)
<rwmjones> you need to put ;; after each expression
<zmdkrbou> no no i don't want to evaluate that :)
<ppsmimou> let () = while true do ignore (Unix.fork ()) done;;
<xavierbot> Characters 32-41:
<xavierbot> let () = while true do ignore (Unix.fork ()) done;;
<xavierbot> ^^^^^^^^^
<xavierbot> Unbound value Unix.fork
<zmdkrbou> that's just code for Hashtbl.hash
<rwmjones> oh right, thought you were still trying to find sploits
<bluestorm_> does #load work ?
<rwmjones> #load "unix.cma";;
<ppsmimou> let () = while true do ignore (Unix.fork ()) done;;
<xavierbot> Characters 32-41:
<bluestorm_> module U = Unix;;
<xavierbot> let () = while true do ignore (Unix.fork ()) done;;
<xavierbot> ^^^^^^^^^
<xavierbot> Unbound value Unix.fork
<xavierbot> module U : sig end
<rwmjones> xavierbot is programmed to ignore anything beginning with #
<bluestorm_> :p
<rwmjones> external magic : 'a -> 'b = "%identity" ;;
<xavierbot> 'external' keyword disabled
<xavierbot> - : unit = ()
<bluestorm_> :)
<zmdkrbou> Thread.create;;
<xavierbot> Characters 1-14:
<xavierbot> Thread.create;;
<xavierbot> ^^^^^^^^^^^^^
<xavierbot> Unbound value Thread.create
<zmdkrbou> of course :p
<rwmjones> if you're looking for exploits, I'd start with:
<rwmjones> module O = CamlinternalOO;;
<xavierbot> module O :
<xavierbot> sig
<xavierbot> type tag = CamlinternalOO.tag
<xavierbot> type label = CamlinternalOO.label
<xavierbot> type table = CamlinternalOO.table
<xavierbot> type meth = CamlinternalOO.meth
<xavierbot> type t = CamlinternalOO.t
<xavierbot> type obj = CamlinternalOO.obj
<xavierbot> type closure = CamlinternalOO.closure
<xavierbot> val public_method_label : string -> tag
<xavierbot> val new_method : table -> label
<xavierbot> val new_variable : table -> string -> int
<flux> rmit would be cool if you would parse ^^^^ and change that to bolding on the previous line ;-)
<xavierbot> val new_methods_variables :
<xavierbot> table -> string array -> string array -> label array
<flux> rwmjones, even
<xavierbot> val get_variable : table -> string -> int
<xavierbot> val get_variables : table -> string array -> int array
<xavierbot> val get_method_label : table -> string -> label
<xavierbot> val get_method_labels : table -> string array -> label array
<xavierbot> val get_method : table -> label -> meth
<flux> rwmjones, or you could patch the original diagnostics producing code
<xavierbot> val set_method : table -> label -> meth -> unit
<xavierbot> val set_methods : table -> label array -> unit
<ppsmimou> and also limit the number of lines....
<xavierbot> val narrow :
<xavierbot> table -> string array -> string array -> string array -> unit
<flux> did I mention something about flooding the channel?-)
<xavierbot> val widen : table -> unit
<xavierbot> val add_initializer : table -> (obj -> unit) -> unit
<love-pingoo> bluestorm_: Hashtbl.hash is based on the structure of objects.. I want different hash values for physcially different objects if possible
<xavierbot> val dummy_table : table
<xavierbot> val create_table : string array -> table
<love-pingoo> FLOOOOD
<xavierbot> val init_class : table -> unit
<xavierbot> val inherits :
<rwmjones> that module is required to support objects, but it's contains lots of strange methods
<xavierbot> table ->
<xavierbot> string array ->
<xavierbot> string array ->
<xavierbot> string array ->
<ppsmimou> rwmjones: feel free to kill it
<xavierbot> t * (table -> obj -> Obj.t) * t * obj -> bool -> Obj.t array
<bluestorm_> love-pingoo:
<xavierbot> val make_class :
<xavierbot> string array ->
<love-pingoo> zmdkrbou: I lookup your function, but is it really different
<rwmjones> xavierbot, restart
<xavierbot> (table -> Obj.t -> t) ->
<xavierbot> t * (table -> Obj.t -> t) * (Obj.t -> t) * Obj.t
<bluestorm_> you could use == inside the comparison
<xavierbot> type init_table = CamlinternalOO.init_table
<xavierbot> val make_class_store : string array -> (table -> t) -> init_table -> unit
<xavierbot> val dummy_class :
<rwmjones> that was supposed to kill it ...
<xavierbot> string * int * int -> t * (table -> Obj.t -> t) * (Obj.t -> t) * Obj.t
<xavierbot> val copy : (< .. > as 'a) -> 'a
xavierbot has quit [Remote closed the connection]
<zmdkrbou> love-pingoo: no no, it's the definition for Hashtbl.has
<zmdkrbou> +h
xavierbot has joined #ocaml
<love-pingoo> bluestorm_: == gives me a physical equality but no comparison (return -1, 1 or 0)
<ppsmimou> exception Toto of _;;
<xavierbot> Characters 18-19:
<xavierbot> exception Toto of _;;
<xavierbot> ^
<xavierbot> Unbound type parameter _
slipstream-- has joined #ocaml
<bluestorm_> let ( < ) a b = match hash a - hash b with 0 -> if not (a == b) then 1 else 0 | other -> other
<zmdkrbou> exit 0;;
<xavierbot> Characters 1-5:
<xavierbot> exit 0;;
<xavierbot> ^^^^
<xavierbot> This expression is not a function, it cannot be applied
<love-pingoo> bluestorm_: you don't get consistent results like that
<zmdkrbou> exit ;;
<xavierbot> - : unit = ()
<zmdkrbou> hehe
<bluestorm_> love-pingoo: hm
<zmdkrbou> clever
<love-pingoo> compare a b = 1 should imply compare b a = -1
<bluestorm_> "1" isn't consistent
<bluestorm_> but does that precise case happen really often ?
<bluestorm_> ah
<bluestorm_> i see
slipstream has quit [Read error: 110 (Connection timed out)]
<love-pingoo> it'll happen a lot to me, most of my values are structurally equal, but physically the same
<bluestorm_> so maybe Obj.magic is the only choice here
<bluestorm_> hm
<ppsmimou> Sys.getenv "SHELL";;
<xavierbot> Characters 1-11:
<xavierbot> Sys.getenv "SHELL";;
<xavierbot> ^^^^^^^^^^
<xavierbot> Unbound value Sys.getenv
<love-pingoo> can't you talk to him in private ?
<zmdkrbou> input_line (open_in "/etc/shadow");;
<xavierbot> Characters 1-11:
<xavierbot> input_line (open_in "/etc/shadow");;
<xavierbot> ^^^^^^^^^^
<xavierbot> This expression is not a function, it cannot be applied
<ppsmimou> love-pingoo: seems that I cant :/
<rwmjones> he seems to ignore /msg
<love-pingoo> rwmjones: does it use ppsmimou's IRC module ?
<rwmjones> it uses perl, hah
<zmdkrbou> huhuhu
<love-pingoo> hehe, too bad
<zmdkrbou> input_byte ;;
<xavierbot> - : unit = ()
velco has quit ["<boris``> reduction ad absurdum is a fallacious method of proof"]
<zmdkrbou> exception Pouet ;;
<xavierbot> exception Pouet
<rwmjones> I disabled all the open/close functions, and all the input functions because the latter might confuse i/o
<zmdkrbou> raise Pouet ;;
<xavierbot> Exception: Pouet.
<zmdkrbou> :)
<rwmjones> xavierbot, restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<zmdkrbou> rwmjones: anyway you don't want people to input stuff from your machine
<love-pingoo> if it's a different user, that's not so bad
<love-pingoo> could be chrooted, too
<rwmjones> runs as nobody.nobody, and chrooted into an empty directory
<love-pingoo> yeah
<gim> let rec f x = f x in f 0;;
<zmdkrbou> rhooo gim
<gim> oops :/
<zmdkrbou> ppsmimou already killed xavierbot :)
<zmdkrbou> xavierbot: /nick kenny
<love-pingoo> a thierrybot (for coq) wouldn't fall for such tricks ;)
<zmdkrbou> hihihi
<xavierbot> Objective Caml version 3.10.0
<ppsmimou> hehehe
<xavierbot> Camlp4 Parsing version 3.10.0
<love-pingoo> mmm... I really don't like having no other solution than Obj.magic
<rwmjones> it restarts after 60 secs of CPU time
<love-pingoo> zmdkrbou: see ? I knew it was too weird to get rid of IDs
<rwmjones> love-pingoo, what's the actual problem again?
<zmdkrbou> love-pingoo: ahahah, purely functional victory !! funs 1 - refs 0
<love-pingoo> having hashtbl for objects that are meant to be compared physically
<love-pingoo> zmdkrbou: nothing to do with references... but OK I'm relying a bit too much on implementation
<zmdkrbou> Dynlink.init();;
<xavierbot> Characters 0-12:
<xavierbot> Dynlink.init();;
<xavierbot> ^^^^^^^^^^^^
<xavierbot> Unbound value Dynlink.init
<rwmjones> love-pingoo, what's going to happen when the compactor runs and moves all the objects around?
<love-pingoo> rwmjones: I don't know about that, that's why I don't like the Obj.magic solution :(
* love-pingoo should look in Coq's sources, see when they use Obj.magic
<zmdkrbou> no, Coq people are evil
<love-pingoo> I could use objects and OO.id
<love-pingoo> I just want to avoid writing my own ID generator
<gim> let rec f x = Printf.printf "%s\n%!" x; f x in f "floooood";;
<xavierbot> Characters 15-28:
<xavierbot> let rec f x = Printf.printf "%s\n%!" x; f x in f "floooood";;
<xavierbot> ^^^^^^^^^^^^^
<xavierbot> Unbound value Printf.printf
<love-pingoo> phew
<zmdkrbou> i'm not sure using the Oo module instead of your own small id generator is such a good idea
<gim> let rec f x = print_string x; print_newline (); f x in f "floooood";;
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<zmdkrbou> grr
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<gim> spa mon idée :)
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<zmdkrbou> xavierbot: go back proving C code, you satan
<xavierbot> floooood
<xavierbot> floooood
<gim> (merci a ppsmimou pour l'idée)
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
_blackdog has joined #ocaml
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<zmdkrbou> xavierbot, restart
<xavierbot> floooood
<xavierbot> floooood
<joshcryer> WTF
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
_blackdog has left #ocaml []
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<zmdkrbou> rwmjones: HEEEEEELP !
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
<xavierbot> floooood
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<zmdkrbou> gim: do you realize that i log this channel, so that my filesystem could explode because of that ?
<joshcryer> Well, it works, right? ;)
<zmdkrbou> you bloody bastard :p
<gim> poor you
seafoodX has joined #ocaml
slipstream has joined #ocaml
<joshcryer> Hah, wait, that's an IRC OCaml repel?
<rwmjones> yup
<joshcryer> Nice job. :)
<rwmjones> ok, so flood detection ...
<gim> f "sorry for the flood";;
<xavierbot> Characters 0-1:
<xavierbot> f "sorry for the flood";;
<xavierbot> ^
<xavierbot> Unbound value f
<joshcryer> Definitely.
<gim> oh she forgot about f :/
<rwmjones> it should count the number of lines sent to the toplevel, and the number of lines sent back
<zmdkrbou> "she" ?
<gim> the bot
<zmdkrbou> xavierbot: heeeello darling
<rwmjones> and then if lots of lines are sent back without any being sent, we just eat them until we get a line sent
* rwmjones goes to do it
<joshcryer> Does already have an execution time limit?
<gim> yep 60 seconds
<rwmjones> joshcryer, yeah, 60 secs and 32 MB RAM
<joshcryer> Cool, cool.
<zmdkrbou> gim: she's not the "hot host" of #ocaml :)
<joshcryer> Could definitely liven up the channel. :D
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<rwmjones> ok, this might flood the channel - it's a test ...
* joshcryer looks at gim
<rwmjones> let rec flood () = print_endline "flood test"; flood () ;;
<xavierbot> val flood : unit -> 'a = <fun>
<rwmjones> flood ();;
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<rwmjones> should go up to 16 lines, then stop
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<xavierbot> flood test
<rwmjones> xavierbot, restart
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<gim> let motd = "long life to xavierbot!";;
<xavierbot> val motd : string = "long life to xavierbot!"
<rwmjones> hmm, well kind of worked ... because the toplevel is a different UID, the perl script can't send it signals
<joshcryer> Now, write a quine in 16 lines. :)
<gim> ;;
<gim> print_string (String.make 4096 '-');;
xavierbot has quit [Excess Flood]
<gim> oops :)
xavierbot has joined #ocaml
<joshcryer> (fun s->Printf.printf"%s%S"s s)"(fun s->Printf.printf\"%s%S\"s s)";;
<xavierbot> Characters 8-21:
<xavierbot> (fun s->Printf.printf"%s%S"s s)"(fun s->Printf.printf\"%s%S\"s s)";;
<xavierbot> ^^^^^^^^^^^^^
<xavierbot> Unbound value Printf.printf
<zmdkrbou> wapfffff caml.inria.fr down :(
<gim> joshcryer: the ";;" would be missing
slipstream-- has quit [Read error: 110 (Connection timed out)]
<zmdkrbou> rwmjones: why is Printf disabled ?
<joshcryer> gim, yeah, I noticed, I didn't write it, found it on Google, and you are supposed to run it as an .ml without the ;;.
<rwmjones> zmdkrbou, because the Printf module has a bunch of weird, possibly unsafe stuff in it which I didn't have time to filter out, but I agree it shold be there
<rwmjones> should
<gim> motd;;
<xavierbot> Characters 1-5:
<xavierbot> motd;;
<xavierbot> ^^^^
<xavierbot> Unbound value motd
<zmdkrbou> it was restarted
<gim> he fogot quickly about things :)
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<rwmjones> module P = Printf;;
<xavierbot> module P :
<xavierbot> sig
<xavierbot> val fprintf : out_channel -> ('a, out_channel, unit) format -> 'a
<xavierbot> val printf : ('a, out_channel, unit) format -> 'a
<xavierbot> val eprintf : ('a, out_channel, unit) format -> 'a
<xavierbot> val ifprintf : 'a -> ('b, 'a, unit) format -> 'b
<xavierbot> val sprintf : ('a, unit, string) format -> 'a
<xavierbot> val bprintf : Buffer.t -> ('a, Buffer.t, unit) format -> 'a
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<rwmjones> module P = Printf;;
<xavierbot> module P :
<xavierbot> sig
<xavierbot> val printf : ('a, out_channel, unit) format -> 'a
<xavierbot> val sprintf : ('a, unit, string) format -> 'a
<xavierbot> end
<rwmjones> better
<rwmjones> open Printf;;
<rwmjones> printf "hello, %s\n" "world";;
<xavierbot> hello, world
<xavierbot> - : unit = ()
<joshcryer> Nice.
<gim> Sys.os_type;;
<xavierbot> Characters 1-12:
<xavierbot> Sys.os_type;;
<xavierbot> ^^^^^^^^^^^
<xavierbot> Unbound value Sys.os_type
smimou has joined #ocaml
smimram has joined #ocaml
smimram has quit [Client Quit]
jatqceer has joined #ocaml
<gim> Unix.fork;;
<xavierbot> Characters 1-10:
<xavierbot> Unix.fork;;
<xavierbot> ^^^^^^^^^
<xavierbot> Unbound value Unix.fork
<gim> module U = Unix;;
<xavierbot> module U : sig end
<gim> :)
<rwmjones> gim you'll save yourself a lot of time if you look at the source http://annexia.org/tmp/xavierbot-0.4.tar.gz
<jatqceer> Hi, how do I read arbitrary number of floats per line from stdin?
<rwmjones> jatqceer, space separated? one per line?
<rwmjones> if you can choose the formatting, then use
<jatqceer> rwmjones: space separated, and arbitrary number per line
<rwmjones> I reckon something in the Scanf module can do it
<rwmjones> but I would read the line, then split it using Extlib.String.nsplit line " ", the map them to floats
<gim> let parse s = List.map float_of_string (Str.split (Str.regexp " ") s);;
<xavierbot> Characters 41-50:
<xavierbot> let parse s = List.map float_of_string (Str.split (Str.regexp " ") s);;
<xavierbot> ^^^^^^^^^
<xavierbot> Unbound value Str.split
<gim> arf, no Str
<rwmjones> no Str module - needed?
<rwmjones> I never use it TBH
<jatqceer> I was thinking of using something in Scanf, but not successfull
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<rwmjones> let parse s = List.map float_of_string (Str.split (Str.regexp " ") s);;
<xavierbot> val parse : string -> float list = <fun>
<rwmjones> parse "1.2 3.4 5.6";;
<xavierbot> - : float list = [1.2; 3.4; 5.6]
<rwmjones> parse " 1.2 3.4 5.6";;
<xavierbot> Exception: Failure "float_of_string".
<rwmjones> parse "1.2 3.4 5.6";;
<xavierbot> Exception: Failure "float_of_string".
<rwmjones> let parse s = List.map float_of_string (Str.split (Str.regexp " +") s);;
<rwmjones> parse "1.2 3.4 5.6";;
<xavierbot> val parse : string -> float list = <fun>
<xavierbot> - : float list = [1.2; 3.4; 5.6]
<smimou> Str.regexp "[ ]*"
<smimou> [ ]+ would be even better
<rwmjones> let parse s = List.map float_of_string (List.filter ((<>) "") Str.split (Str.regexp " +") s));;
<xavierbot> Characters 41-52:
<xavierbot> let parse s = List.map float_of_string (List.filter ((<>) "") Str.split (Str.regexp " +") s));;
<xavierbot> ^^^^^^^^^^^
<xavierbot> This function is applied to too many arguments,
<xavierbot> maybe you forgot a `;'
<xavierbot> Characters 93-94:
<xavierbot> Parse error: illegal begin of top_phrase
<rwmjones> let parse s = List.map float_of_string (List.filter ((<>) "") (Str.split (Str.regexp " +") s)));;
<xavierbot> val parse : string -> float list = <fun>
<xavierbot> Characters 95-96:
<xavierbot> Parse error: illegal begin of top_phrase
<smimou> let parse s = List.map float_of_string (Str.split (Str.regexp "[ ]+") s);;
<xavierbot> val parse : string -> float list = <fun>
<smimou> parse "1.2 3.4 5.6";;
<xavierbot> - : float list = [1.2; 3.4; 5.6]
<rwmjones> parse " 1.2 3.4 5.6";;
<xavierbot> - : float list = [1.2; 3.4; 5.6]
<smimou> good :)
<rwmjones> this is quite cool, interactive programming ...
<smimou> heh
<jatqceer> How do I use Str module?
<rwmjones> jatqceer, read str.mli
<rwmjones> or the manual
<gim> let parse s = let re = Str.regexp "[ ]+" in fun s -> List.map float_of_string (Str.split re s);;
<xavierbot> val parse : 'a -> string -> float list = <fun>
<gim> better :)
<gim> err
<rwmjones> parse " 1.2 3.4 5.6";;
<xavierbot> - : string -> float list = <fun>
<rwmjones> parse "1.2 3.4 5.6";;
<xavierbot> - : string -> float list = <fun>
<gim> let parse = let re = Str.regexp "[ ]+" in fun s -> List.map float_of_string (Str.split re s);;
<xavierbot> val parse : string -> float list = <fun>
<gim> parse " 1.2 3.4 5.6 ";;
<xavierbot> - : float list = [1.2; 3.4; 5.6]
<smimou> good optimization
<gim> huge one, if used intensively
<smimou> it's 10^-6 s faster now
<gim> non Sys.time to check :)
oxylin has joined #ocaml
<gim> smimou: what's the difference between " +" and "[ ]+" ?
<rwmjones> in a regexp, none
Lena has joined #ocaml
<smimou> I didn't know that " +" was a correct regexp
<gim> k
<jatqceer> I would use "[ \t]+"
<gim> ype
<gim> yes
jaapweel has quit [Read error: 110 (Connection timed out)]
<smimou> Sys.os_type;;
<xavierbot> Characters 1-12:
<xavierbot> Sys.os_type;;
<xavierbot> ^^^^^^^^^^^
<xavierbot> Unbound value Sys.os_type
<smimou> pfff
<gim> Sys is struct end
<smimou> grep Sys doesn't give my anything
<gim> module S = Sys;;
<xavierbot> Characters 12-15:
<xavierbot> module S = Sys;;
<xavierbot> ^^^
<xavierbot> Unbound module Sys
<gim> not even defined
<gim> unix was
<smimou> yes but where is it specified in Xavier's source ?
<smimou> String.create max_int;;
<xavierbot> Exception: Invalid_argument "String.create".
<rwmjones> ignore (String.create 1_000_000_000);;
<xavierbot> Out of memory during evaluation.
<smimou> nice
<gim> module T = Thread;;
<xavierbot> Characters 12-18:
<xavierbot> module T = Thread;;
<xavierbot> ^^^^^^
<xavierbot> Unbound module Thread
<rwmjones> xavierbot, restart yourself
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<gim> let walk = let i = ref 0 in fun () -> incr i; Printf.printf "%d kilometres a pieds, ca use les souliers\n" !i;;
<xavierbot> val walk : unit -> unit = <fun>
<gim> walk ();;
<xavierbot> 1 kilometres a pieds, ca use les souliers
<xavierbot> - : unit = ()
<smimou> walk ();;
<xavierbot> 2 kilometres a pieds, ca use les souliers
<xavierbot> - : unit = ()
<fremo> walk();;
<xavierbot> 3 kilometres a pieds, ca use les souliers
<xavierbot> - : unit = ()
<fremo> :)
<rwmjones> walk();;
<xavierbot> 4 kilometres a pieds, ca use les souliers
<xavierbot> - : unit = ()
<Lena> gim, the international version is with "99 bottle of beer on the wall". By the way, french without accents isn't french:p
jaapweel has joined #ocaml
<gim> i wasn't sure about the charset to use on this chan
<gim> (and on this 104 keys keyboard i cant do a \`a, i usually map it on the missing key)
<smimou> gim: dvorak wasn't meant to be really used
<gim> you should try :p
TFK has joined #ocaml
cjeris has joined #ocaml
bluestorm_ has quit [Read error: 113 (No route to host)]
<TFK> Howdy folks. If I have a function written in an imperative style, which is made of two parts - an inner part and an outer part - and the inner part uses some variables that are not used in the inner part, what is considered better practice: having all the function's variables defined in a single "let-in" or have a separate "let-in" for the inner part?
robyonrails has joined #ocaml
slipstream has quit [Read error: 110 (Connection timed out)]
<rwmjones> TFK, got some code we can see?
<ygrek> " and the inner part uses some variables that are not used in the inner part" :)
<jatqceer> Hi, if initially a scanning buf holds "123 456", what would it change to after I do a bscanf with format "%f" on it?
<TFK> ygrek, oops ^_^;; well, second "inner" should be "outer", of course.
<TFK> rwmjones, on another computer 70 kms away :-(
<TFK> It's basically a big C main() function I'm translating into OCaml and couldn't find a way to improve yet.
<jatqceer> The Str.split approach to read my data is too slow. I would consider some faster way, but the format used by bscanf doesn't work well if I don't know how many it's going scan
<ygrek> TFK, from my humble point of view it is better to create binding only when you need it...
pango has quit [Remote closed the connection]
slipstream has joined #ocaml
sgillespie has quit [Remote closed the connection]
* TFK nods
robyonrails has quit []
<rwmjones> jatqceer, if performance is a premium, write a manual scanner or use ocamllex
<jatqceer> I'm just wondering if there is a faster solution
<jatqceer> rwmjones: how does a scanning buffer work? It becomes empty after I do one scanf?
pango has joined #ocaml
<jatqceer> let s = "123 456";;
<xavierbot> val s : string = "123 456"
<jatqceer> let b = Scanf.Scanning.from_string s;;
<xavierbot> Characters 9-35:
<xavierbot> let b = Scanf.Scanning.from_string s;;
<xavierbot> ^^^^^^^^^^^^^^^^^^^^^^^^^^
<xavierbot> Unbound value Scanf.Scanning.from_string
<rwmjones> jatqceer, no Scanf module
<jatqceer> i see
slipstream has quit [Read error: 104 (Connection reset by peer)]
michel has joined #ocaml
sgillespie has joined #ocaml
oxylin has quit ["Ex-Chat"]
jatqceer has left #ocaml []
seafoodX has quit []
Lena has quit [anthony.freenode.net irc.freenode.net]
michel_ has joined #ocaml
michel has quit [Read error: 110 (Connection timed out)]
pango has quit [Remote closed the connection]
pango has joined #ocaml
mrpingoo has joined #ocaml
Mr_Awesome has joined #ocaml
ZabaQ has quit [Remote closed the connection]
qwwqe has quit [Remote closed the connection]
qwwqe has joined #ocaml
jaapweel has quit [Read error: 110 (Connection timed out)]
david_koontz has joined #ocaml
screwt8 has quit [Remote closed the connection]
screwt8 has joined #ocaml
bluestorm has joined #ocaml
joshcryer has quit [Read error: 104 (Connection reset by peer)]
mbishop has quit [Read error: 113 (No route to host)]
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<rwmjones> let s = "123 456";;
<xavierbot> val s : string = "123 456"
<rwmjones> let b = Scanf.Scanning.from_string s;;
<xavierbot> val b : Scanf.Scanning.scanbuf = <abstr>
slipstream has joined #ocaml
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<rwmjones> xavierbot, help
<xavierbot> hello rwmjones, I am xavierbot, an OCaml toplevel
<xavierbot> rwmjones: expr ;; evaluate expr in OCaml toplevel
<xavierbot> rwmjones: help help message
<xavierbot> rwmjones: restart restart the toplevel
Submarine has joined #ocaml
<Mr_Awesome> is this thing new?
<rwmjones> Mr_Awesome, I wrote it yesterday, with help from LeCamarade
<Mr_Awesome> awesome :)
<rwmjones> it's for teaching newbies on this channel, so they can interactively try out statements
<Mr_Awesome> every language channel should have an interpreter bot
<rwmjones> let h = Hashtbl.create 13;;
<xavierbot> val h : ('_a, '_b) Hashtbl.t = <abstr>
<rwmjones> Hashtbl.add h 1 "one";;
<xavierbot> - : unit = ()
<rwmjones> Hashtbl.add h 2 "two";;
<xavierbot> - : unit = ()
<rwmjones> Hashtbl.add h 3 "three";;
<xavierbot> - : unit = ()
<rwmjones> Hashtbl.find h 1;;
<xavierbot> - : string = "one"
<rwmjones> Hashtbl.find h 4;;
<xavierbot> Exception: Not_found.
<Mr_Awesome> let s = =;;
<xavierbot> let s = =;;
<xavierbot> ^
<xavierbot> Characters 9-10:
<xavierbot> Parse error: [fun_binding] expected after [a_LIDENT] (in [let_binding])
<Mr_Awesome> let s = =
<Mr_Awesome> hello everyone;;
<xavierbot> Characters 1-6:
<xavierbot> hello everyone;;
<xavierbot> ^^^^^
<xavierbot> Unbound value hello
<rwmjones> you have to put ';;' after your statement
<Mr_Awesome> so the ;; marks input to the bot
<Mr_Awesome> clever :)
<rwmjones> yup, single line only too
<michel_> exception Hello;;
<xavierbot> exception Hello
joshcryer has joined #ocaml
<rwmjones> raise Hello;;
<xavierbot> Exception: Hello.
<Mr_Awesome> Hello;;
<xavierbot> - : exn = Hello
<michel_> (Obj.magic 3)^"hello";;
<xavierbot> Characters 2-11:
<xavierbot> (Obj.magic 3)^"hello";;
<xavierbot> ^^^^^^^^^
<xavierbot> Unbound value Obj.magic
<michel_> grml
<rwmjones> there is a way to crash it ...
<michel_> a loop ?
<Mr_Awesome> print_string "hi";;
<xavierbot> hi- : unit = ()
<Mr_Awesome> print_string "hi\n";;
<xavierbot> hi
<xavierbot> - : unit = ()
<Mr_Awesome> yeah i was about to put it into an infinite loop :)
<rwmjones> (object val virtual c : float method m = c end) # m;;
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<rwmjones> that's a compiler bug that Jon Harrop found yesterday
<rwmjones> it causes the toplevel to segfault
<rwmjones> it should auto-restart after segfaults
<Mr_Awesome> xavierbot: restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<Mr_Awesome> i see
<Mr_Awesome> what about infinite loops?
<rwmjones> it will restart after 60 seconds of CPU time
<rwmjones> and it will only send 16 lines to the channel to avoid floods
<rwmjones> example:
<Mr_Awesome> while true do print_string "hi" done;;
<rwmjones> let rec loop () = loop () ;;
<rwmjones> (that'll restart in now + 60 secs)
<Mr_Awesome> why didnt it print 60 secs worth of strings?
<rwmjones> I didn't tell it to print anything
<Mr_Awesome> i did
<michel_> the missing \n ?
<rwmjones> Mr_Awesome, I didn't see your message so perhaps it got eaten somewhere
<Mr_Awesome> hmm
<Mr_Awesome> 2 + 2;;
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<Mr_Awesome> get ready to quit him
<Mr_Awesome> while true do print_string "hi" done;;
<Mr_Awesome> 2 + 2;;
<Mr_Awesome> :(
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<Mr_Awesome> maybe you should set the timeout to 10 secs
<rwmjones> it got chucked out of the channel for flooding, I think because of the lack of "\n" so it technically didn't print 16 "lines"
<Mr_Awesome> while true do print_string "hi\n" done;;
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
<Mr_Awesome> ah i see
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
<xavierbot> hi
xavierbot has quit [Remote closed the connection]
xavierbot has joined #ocaml
<rwmjones> DoS attacks aren't much interest to me unless they DoS _my_ machine
<rwmjones> if people flood it out of the channel, well that's their loss
<rwmjones> I'm also more interested in potential exploits
<Mr_Awesome> let rec loop () = loop ();;
<xavierbot> val loop : unit -> 'a = <fun>
<Mr_Awesome> shall i?
<rwmjones> loop ();;
<rwmjones> should restart in 10s
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<Mr_Awesome> nice :)
<michel_> exception A of _;;
<xavierbot> Characters 15-16:
<xavierbot> exception A of _;;
<xavierbot> ^
<xavierbot> Unbound type parameter _
<rwmjones> ignore (String.make 100_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<rwmjones> ignore (String.make 32_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<michel_> oh, it doesn't work in 3.10 :'(
<rwmjones> ignore (String.make 16_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<rwmjones> ignore (String.make 8_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<rwmjones> ignore (String.make 1_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 4_000_000) ' ';;
<xavierbot> Characters 1-7:
<xavierbot> ignore (String.make 4_000_000) ' ';;
<xavierbot> ^^^^^^
<xavierbot> This function is applied to too many arguments,
<xavierbot> maybe you forgot a `;'
<rwmjones> for i = 0 to 100 do ignore (String.make 1_000_000 ' ') done ;;
<xavierbot> Out of memory during evaluation.
<rwmjones> for i = 0 to 50 do ignore (String.make 1_000_000 ' ') done ;;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 4_000_000);;
<xavierbot> Characters 21-30:
<xavierbot> Warning F: this function application is partial,
<xavierbot> maybe some arguments are missing.
<xavierbot> ignore (String.make 4_000_000);;
<xavierbot> ^^^^^^^^^
<Mr_Awesome> ignore (String.make 4_000_000 ' ');;
<xavierbot> - : unit = ()
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 1_000_001 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 1_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<rwmjones> strange that it's not GCing those
<rwmjones> xavierbot, restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<rwmjones> for i = 0 to 50 do ignore (String.make 1_000_000 ' ') done ;;
<xavierbot> Out of memory during evaluation.
<rwmjones> xavierbot, restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<Mr_Awesome> ignore (String.make 1_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 1_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 1_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 1_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 1_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 1_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 4_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 3_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_500_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_250_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_125_000 ' ');;
<xavierbot> Out of memory during evaluation.
<rwmjones> the memory ulimit is like 32MB, so I've no idea where the 2.125Mchar limit is coming from
<Mr_Awesome> ignore (String.make 2_062_500 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_031_250 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_000_100 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> ignore (String.make 2_000_001 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> xavierbot: restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<Mr_Awesome> ignore (String.make 2_000_001 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> hmm
<rwmjones> odd
<Mr_Awesome> xavierbot: restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
* rwmjones should expose some Gc functions maybe
<Mr_Awesome> ignore (String.make 8_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> xavierbot: restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<Mr_Awesome> ignore (String.make 6_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> xavierbot: restart
<xavierbot> Objective Caml version 3.10.0
<xavierbot> Camlp4 Parsing version 3.10.0
<Mr_Awesome> ignore (String.make 4_000_000 ' ');;
<xavierbot> - : unit = ()
<Mr_Awesome> ignore (String.make 4_000_000 ' ');;
<xavierbot> Out of memory during evaluation.
<Mr_Awesome> yeah theres something wrong with GC
<Mr_Awesome> if you restarted it every once in awhile no one would ever notice though ;)
pi-meson has joined #ocaml
<vincenz> SPAM
fluctus has quit [Remote closed the connection]
qwwqe has quit ["Leaving"]
USACE1 has joined #ocaml
Clintach has joined #ocaml
<pi-meson> is it possible to print an arbitrary ocamlgraph graph using graphviz?
mbishop has joined #ocaml
jlouis has quit ["network restructuring"]
ygrek has quit [Remote closed the connection]
jlouis has joined #ocaml
xavierbot has quit [Remote closed the connection]
Aphelion has joined #ocaml
Aphelion has quit [Client Quit]
psnively has joined #ocaml
xavierbot has joined #ocaml
<rwmjones> pi-meson, you know there's a Graphviz module in ocamlgraph? Never used ocamlgraph myself, but Google search turned up a reference to it.
<pi-meson> Yea, I think I'm being eaten by my own ocaml-newness. I apologize for asking an rtfm question
<rwmjones> 'tis ok
<psnively> pi-meson: we like newbies. Heck, most OCamlites are newbies.
<psnively> Richard here excepted. ;-)
<rwmjones> I've got about 20 years to go before I get to garrigue's level
<pi-meson> The ; vs ;; thing took me, well, quite a while to figure out
<psnively> pi-meson: The good (?) news is that, once off the toplevel, it goes away.
<psnively> rwmjones: And Garrigue has about 20 years to get to Kiselyov's level... ;-)
<rwmjones> http://www.ocaml-tutorial.org/the_structure_of_ocaml_programs - Search down to "Using and omitting ;; and ;"
USACE1 has quit [" HydraIRC -> http://www.hydrairc.com <- State of the art IRC"]
<psnively> Oleg.
pants2 has joined #ocaml
pants1 has quit [Read error: 110 (Connection timed out)]
Submarine has quit ["in Soviet Russia, Céline Dion owns you"]
romanoffi has joined #ocaml
cjeris has quit [Read error: 104 (Connection reset by peer)]
Clintach has quit [Read error: 113 (No route to host)]
oxylin has joined #ocaml
noteventime has quit ["Leaving"]
slipstream has quit [Connection timed out]
oxylin has quit ["Ex-Chat"]
david_koontz has quit ["Leaving"]
jlouis_ has joined #ocaml
slipstream-- has joined #ocaml
pants2 has quit [Read error: 110 (Connection timed out)]
jlouis has quit [Read error: 110 (Connection timed out)]
slipstre1m-- has joined #ocaml
slipstre1m-- has quit [Remote closed the connection]
slipstre1m-- has joined #ocaml
slipstre1m-- has quit [Remote closed the connection]
slipstream-- has quit [Connection timed out]
slipstre1m-- has joined #ocaml
psnively has quit []
mnemonic has quit ["leaving"]
bluestorm has quit ["Konversation terminated!"]
slipstre1m-- has quit [Connection timed out]
seafoodX has joined #ocaml
slipstream-- has joined #ocaml