crabstick has quit [Read error: 110 (Connection timed out)]
aij has quit ["brb"]
aij has joined #ocaml
bluestorm has quit ["Konversation terminated!"]
love-pingoo has quit [Read error: 110 (Connection timed out)]
piggybox has joined #ocaml
Cygaal has joined #ocaml
piggybox_ has quit [Client Quit]
m3ga has joined #ocaml
ita has joined #ocaml
<ita>
hi there
<m3ga>
hi!
cmeme has quit [Excess Flood]
cmeme has joined #ocaml
crabstick has joined #ocaml
jedai has quit [Read error: 110 (Connection timed out)]
Cygaal has quit [Read error: 104 (Connection reset by peer)]
Cygaal has joined #ocaml
Smerdyakov has quit ["Leaving"]
<ita>
grr, i cannot find an example of writing a string into a file
Cygaal has quit [Remote closed the connection]
crabstick has quit [Read error: 110 (Connection timed out)]
<ita>
okay, now i do have it
ita_ has joined #ocaml
ita has quit [Read error: 110 (Connection timed out)]
ita_ has quit ["later"]
kelaouchi has quit [Remote closed the connection]
buluca has quit [Read error: 113 (No route to host)]
bluestorm has joined #ocaml
netx has joined #ocaml
crabstick has joined #ocaml
crabstick_ has joined #ocaml
schme` has joined #ocaml
ktne has joined #ocaml
crabstick has quit [Read error: 110 (Connection timed out)]
<flux>
that raise-mechanism does have the problem that intermediate cleanup functions will intervene..
schme has quit [Read error: 110 (Connection timed out)]
pango has quit [Remote closed the connection]
pango has joined #ocaml
G_ has joined #ocaml
G has quit [Read error: 110 (Connection timed out)]
Tetsuo has joined #ocaml
G_ is now known as G
ygrek has joined #ocaml
piggybox_ has joined #ocaml
piggybox has quit [Read error: 110 (Connection timed out)]
seafoodX has joined #ocaml
love-pingoo has joined #ocaml
m3ga has quit ["disappearing into the sunset"]
seafoodX has quit []
buluca has joined #ocaml
Cygal has joined #ocaml
Cygal is now known as Cygaal
jlouis_ has joined #ocaml
seafoodX has joined #ocaml
seafoodX has quit [Client Quit]
tty56 has joined #ocaml
jlouis has quit [Read error: 110 (Connection timed out)]
Liline has joined #ocaml
jedai has joined #ocaml
ygrek has quit [Remote closed the connection]
<bluestorm>
hm
<bluestorm>
i think there is a way to write some nativeint or int32 values using a special integer syntax (123L or something like that), but i can't find it in the manual
<bluestorm>
hm
<ktne>
hmm
<bluestorm>
the lexer says 32l is int32, 32L is int64, 32n is nativeint
<bluestorm>
32n;;
<xavierbot>
- : nativeint = 32n
<bluestorm>
:}
<bluestorm>
ktne: how is your parser going ? ^^
<ktne>
L UL ul s
<ktne>
us
<ktne>
some of the ones in f#
<ktne>
well the parser isn't doing well :)
<ktne>
it seems that i hate to add a few extra things
<ktne>
composition is not enough
<bluestorm>
hm
<ktne>
i guessi have to enclose all rules like this
<ktne>
(seq (Literal "sdf")) :>
<bluestorm>
"seq" ?
<ktne>
sequential
<bluestorm>
hum
<ktne>
like rule:= a b c
<bluestorm>
so is Literal "sdf" a sum type now ?
<ktne>
vs (optional (Literal "sdf"))
<bluestorm>
hm
<bluestorm>
i'd have seen optional as a higher order construct, over seq and :>
<bluestorm>
(hm or at :> level)
<ktne>
if you have a | b | c
<ktne>
then this translates into rule_a :> (optional rule_b) :> (optional rule_c)
<ktne>
function optional param match_rule -> if param is None then return match_rule else return param
<ktne>
basically (optional rule_b) checks whenever rule_a has been matched, if so it returns the result of the rule_a, otherwise it proceeds with matching rule_b
<ktne>
(optional rule_c) does the same
<ktne>
sequential rule -> if previous is matched then return (current rule is matched) else None
<ktne>
the sequential is the opposite of optional
<ktne>
optional is like OR, sequential is like AND
<ktne>
"rule:= a b c" would be (AND a) :> (AND b) :> (AND c)
<bluestorm>
hm
<ktne>
"rule := a | b | c" would be (OR a) :> (OR b) :> (OR c)
<bluestorm>
i see
<bluestorm>
hm
<ktne>
"rule := a {b|c}" would be (AND a) :> (MANY ((OR b) :> (OR c))
<bluestorm>
i see another possibility
<ktne>
{} means zero or more repetitions
<ktne>
what possibility?
<bluestorm>
you might have hm
<ktne>
ah and also one last addition
<ktne>
the function rules are eclosed in a NODE
<ktne>
"rule:= a b c" would be NODE ((AND a) :> (AND b) :> (AND c))
<bluestorm>
the rule type could be input -> output option
<ktne>
so that the return is a tree of rules not a list of matched rules
<bluestorm>
hm
<bluestorm>
i'll try to write a little something
<ktne>
or i could add the node inside AND and OR functions
<ktne>
or maybe it's better to wrap the entire rule in a node
<ktne>
this way i can solve node type identification too using a string
<ktne>
for example
<ktne>
"samplerule := a {b|c}" would be NODE "a sample rule" ((AND a) :> (MANY ((OR b) :> (OR c)))
<ktne>
where NODE is string -> rule_result
<ktne>
string -> (rule_result list)
<ktne>
or string * (rule_result list) actually
<ktne>
you see what i mean?
<ktne>
so i would get a tree of nodes tagged with strings (the string is the function name that generated the rule)
<ktne>
and each node spans from first byte of first rule in the node to last byte of last rule in the node
<zap>
Hello! Anybody knows where in Fedora is the ocamlfind or findlib utility? I have installed ocaml.rpm and it's not there...
<bluestorm>
hum
<bluestorm>
is there not a "findlib" package ?
<bluestorm>
(it's a shame rwjones isn't there, he could answer you for sure)
hsuh has joined #ocaml
<zap>
alas, no
<zap>
there's ocaml-findlib.fc8.rpm
<zap>
at least its mentioned somewhere in the net
<zap>
but no findlib in f7
cratylus has left #ocaml []
hsuh has left #ocaml []
hsuh has joined #ocaml
cpst has quit [Read error: 110 (Connection timed out)]
hsuh has left #ocaml []
pango has quit [Remote closed the connection]
pango has joined #ocaml
moglum has joined #ocaml
moglum has quit [Remote closed the connection]
Smerdyakov has joined #ocaml
|Jedai| has joined #ocaml
jedai has quit [Nick collision from services.]
|Jedai| is now known as jedai
bpalmer has joined #ocaml
crabstick has joined #ocaml
ita has joined #ocaml
crabstick_ has quit [Read error: 110 (Connection timed out)]
<ktne>
how can i get a pointer to a constructor?
<ktne>
i have several constructors that take one parameter
<ktne>
i would like to select the constructor based on a parameter
<love-pingoo>
I'm afraid you can't do it like that
<ktne>
hmm
<ktne>
why not?
<ktne>
isn'
<ktne>
isn't a constructor a normal function?
<love-pingoo>
you could have a function wrapping the constructor
<flux>
hm, why not?
<love-pingoo>
a constructor is not a function, indeed
<ktne>
hmm
<love-pingoo>
but for example (fun x -> Some x) is OK
<love-pingoo>
I don't remember why constructors are not functions... efficiency ?
<ktne>
type inference maybe?
<Smerdyakov>
You can pattern match on constructor applications. You can't pattern match on function applications.
<flux>
ktne, perhaps you mean something like ["magic", new a (* partial evaluation *); "DEFAULT", new b] and later (List.assoc constrs "magic") "parameter"
<ktne>
i need to create an object based on a constructor
<love-pingoo>
Smerdyakov: that's why functions are not constructors, but it doesn't really explain the other direction
<ktne>
that is sent as parameter
<Smerdyakov>
(This isn't to say that constructors can't be treated as functions like in SML.)
<Smerdyakov>
But this makes it clear that ktne asked the wrong question, as he only wanted one use of constructors that can be modeled easily with functions.
<love-pingoo>
ktne: the functional wrapper should fit your need, it's just not so concise
<ktne>
hmm
<ktne>
ok, i've used a function wrapper
<ktne>
i would have preffered a better way
<Smerdyakov>
ktne, try using SML. :-)
<ktne>
i'm using F#
<Smerdyakov>
Yeah, that's what you're using, and a better way is to use something else! :P
<bluestorm>
(it's maybe common for you that people read your name in some academic setting, but i'm not used to reading papers from still alive peoples yet)
<bluestorm>
hm
<bluestorm>
i think it was in the Singularity paper
<Smerdyakov>
Could be. I might be acknowledged.
<Smerdyakov>
You only read papers by dead people? You've missed a lot of cool stuff. :D
<bluestorm>
hm
<ita>
haha
<bluestorm>
i do not read papers very often
<bluestorm>
hm
<bluestorm>
actually i wanted to say something like "written by someone i kind of know" but there are some difficulties in that way
<bluestorm>
you could understand "it's the first time i can bother someone on IRC after seeing his name on a paper"
<Smerdyakov>
You write "hm" too much!
<ita>
hm ?
<bluestorm>
People might believe i'm thinking
<bluestorm>
(at least i do, when writing "hm")
<Smerdyakov>
I think such utterances are spam-like on IRC.
<mbishop>
I have a tendency to say "heh" quite a bit
<ita>
Smerdyakov: and the size does matter
crabstick_ has joined #ocaml
ygrek has joined #ocaml
crabstick has quit [Read error: 110 (Connection timed out)]
crabstick has joined #ocaml
crabstick_ has quit [Read error: 110 (Connection timed out)]
snearch has left #ocaml []
Demitar has quit [Read error: 113 (No route to host)]
zap has left #ocaml []
Cygaal has joined #ocaml
hsuh has left #ocaml []
piggybox_ is now known as piggybox
Cygaaal has quit [Connection timed out]
ygrek has quit [Remote closed the connection]
hsuh has joined #ocaml
hsuh has quit [Remote closed the connection]
G has joined #ocaml
mbishop has quit [Remote closed the connection]
slipstream-- has joined #ocaml
martin_ has joined #ocaml
martin_ is now known as mbishop
Demitar has joined #ocaml
slipstream has quit [Read error: 110 (Connection timed out)]
jedai has quit [Read error: 113 (No route to host)]
Liline has quit [Remote closed the connection]
pattern has quit [Read error: 104 (Connection reset by peer)]
pattern has joined #ocaml
jedai has joined #ocaml
cpst has joined #ocaml
jedai has quit [No route to host]
ita has quit [Remote closed the connection]
cpst_ has joined #ocaml
cpst has quit [Read error: 104 (Connection reset by peer)]