<
malc_>
anyone on sparc here?
chessguy2 has quit [Connection timed out]
rillig has quit ["exit(EXIT_SUCCESS)"]
revision17_ is now known as Revision17
sponge45 has joined #ocaml
jacobolus has quit []
malc_ has quit ["leaving"]
jcreigh has joined #ocaml
danly has quit [Read error: 104 (Connection reset by peer)]
danly has joined #ocaml
jcreigh has quit ["while(1) { fork(); }"]
pango has quit [Remote closed the connection]
jacobolus has joined #ocaml
Smerdyakov has quit [Read error: 101 (Network is unreachable)]
Smerdyakov has joined #ocaml
Smerdyakov has quit [Nick collision from services.]
Smerdyakov has joined #ocaml
sponge45 has left #ocaml []
jacobolus has quit [Read error: 104 (Connection reset by peer)]
jacobolus has joined #ocaml
Smerdyakov has quit [Read error: 101 (Network is unreachable)]
Smerdyakov has joined #ocaml
szsz has joined #ocaml
jcreigh has joined #ocaml
jcreigh has quit ["while(1) { fork(); }"]
Smerdyakov has quit ["Despairing for his cupcakes, the master planned his egress."]
ramkrsna has joined #ocaml
tristram has joined #ocaml
sponge45 has joined #ocaml
szsz has left #ocaml []
pango has joined #ocaml
jacobolus has quit [Read error: 104 (Connection reset by peer)]
jacobolus_ has joined #ocaml
jacobolus_ is now known as jacobolus
sponge45 has left #ocaml []
mnemonic has joined #ocaml
Itkovian has joined #ocaml
<
mnemonic>
hi Itkovian
<
Itkovian>
hmm, that name sounds vaguely familiar
love-pingoo has joined #ocaml
<
mnemonic>
It's exactly what I was looking for
pango has quit [Remote closed the connection]
mnemonic has quit [Read error: 104 (Connection reset by peer)]
ramkrsna has quit [Read error: 110 (Connection timed out)]
ramkrsna has joined #ocaml
mnemonic has joined #ocaml
pango has joined #ocaml
revision17_ has joined #ocaml
Revision17 has quit [Read error: 110 (Connection timed out)]
Itkovian has quit []
Itkovian has joined #ocaml
mnemonic has quit ["leaving"]
<
Itkovian>
is there a way to get all the keys from a Map?
<
love-pingoo>
you can use iter
<
love-pingoo>
or rather, fold
mikeX has joined #ocaml
<
Itkovian>
a fold might work
love-pingoo has quit ["Connection reset by pear"]
<
Itkovian>
looking at the type, i doubt it
<
dylan>
let keys m =
<
dylan>
let f k _ accu = k :: accu in
<
dylan>
StrMap.fold f m []
mikeX_ has joined #ocaml
<
Itkovian>
but fold : ('a -> 'b -> 'b), so the value item and the accumulator list should have the same type, no?
<
dylan>
it's fold (key -> 'a ->
<
dylan>
it's fold (key -> 'a -> 'b -> 'b)
<
dylan>
That function I posted indeed works, btw.
<
Itkovian>
yes i know, but if you instantiate the functor, doesn't the key argument get absorbed in the instance type?
<
Itkovian>
yes, it works
<
dylan>
You want one that works for any instance of the Map.Make functor?
<
Itkovian>
nono, this one is fine
<
Itkovian>
I think I'm missing something
<
Itkovian>
as usual
<
Itkovian>
yes, ic it now
* Itkovian
slaps himself
<
Itkovian>
dylan: I you feel like it, you can show me how to make a general keys function for the Map.Make functor ...
mikeX has quit [Read error: 110 (Connection timed out)]
<
dylan>
well, you could take the fold function as an argument to keys
mikeX has joined #ocaml
mikeX_ has quit [Read error: 110 (Connection timed out)]
mnemonic has joined #ocaml
aref has joined #ocaml
ppsmimou has quit [Remote closed the connection]
slipstream has joined #ocaml
Itkovian has quit []
ppsmimou has joined #ocaml
slipstream-- has quit [Success]
finelemon has joined #ocaml
finelemo2 has quit [Read error: 110 (Connection timed out)]
smimou has joined #ocaml
cmeme has quit [Remote closed the connection]
<
jacobolus>
hi. what's the best way to read lines from a file into a list/array? do I want to use tail recursion and cons them onto a big list?
pango has quit [Remote closed the connection]
pango has joined #ocaml
Bigb[a]ng has quit [Read error: 110 (Connection timed out)]
cmeme has joined #ocaml
jacobolus has quit [Read error: 113 (No route to host)]
love-pingoo has joined #ocaml
jacobolus has joined #ocaml
mnemonic has quit ["leaving"]
cmeme has quit [Remote closed the connection]
pango has quit ["Leaving"]
cmeme has joined #ocaml
Revision17 has joined #ocaml
revision17_ has quit [Read error: 110 (Connection timed out)]
pango has joined #ocaml
Schmurtz has quit ["L'énergie semble manquer : dodo !"]
rillig has joined #ocaml
Itkovian has joined #ocaml
gribozavr has joined #ocaml
Smerdyakov has joined #ocaml
mnemonic has joined #ocaml
tristram has quit [Read error: 110 (Connection timed out)]
love-pingoo has quit ["Connection reset by pear"]
Itkovian has quit []
mnemonic has quit ["leaving"]
jacobolus has quit []
kuribas has joined #ocaml
smimou has quit ["bli"]
kuribas has quit ["ERC Version 5.0.2 $Revision: 1.726.2.10 $ (IRC client for Emacs)"]