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!)
smimou has quit ["bli"]
garulfounix has quit [Remote closed the connection]
pcc has joined #ocaml
love-pingoo has quit ["Connection reset by pear"]
pantsd has joined #ocaml
pcc has left #ocaml []
zarvok has joined #ocaml
jao has quit []
jeffs has joined #ocaml
pantsd has quit ["Leaving."]
eumenides has quit [Read error: 104 (Connection reset by peer)]
Submarine has quit ["Leaving"]
zarvok has quit ["BitchX-1.1-final -- just do it."]
jeffs has quit [Read error: 104 (Connection reset by peer)]
pango_ has quit ["Client exiting"]
bluestorm_ has joined #ocaml
<G> rwmjones_away: hey, can you poke me when you return?
smimou has joined #ocaml
kelaouchi has quit [Read error: 104 (Connection reset by peer)]
kelaouchi has joined #ocaml
slipstream-- has joined #ocaml
bluestorm_ has quit ["Konversation terminated!"]
slipstream has quit [Read error: 110 (Connection timed out)]
tree has joined #ocaml
tree_ has quit [Read error: 104 (Connection reset by peer)]
love-pingoo has joined #ocaml
what3 has quit [Read error: 104 (Connection reset by peer)]
olegfink has quit [Read error: 104 (Connection reset by peer)]
olegfink has joined #ocaml
jao has joined #ocaml
pantsd has joined #ocaml
sgillespie has joined #ocaml
<sgillespie> quick question
<sgillespie> if the function i am using is expecting 'a, how can I use it as an int?
<haelix> sgillespie: you want to use the function as an int ?
<sgillespie> the return value
<haelix> so you're function takes any as its argument
<haelix> what does it returns, then ?
<haelix> s/you're/your/
<sgillespie> I'm using Hashtbl.find
<sgillespie> val add : ('a, 'b) t -> 'a -> 'b -> unit
<haelix> (sorry for playing hard brick wall, there are some obvious grey areas in your questions)
<sgillespie> understood
G_ has joined #ocaml
<sgillespie> guess it returns unit?? I'm still having a hard time understanding that notation
<haelix> that is to say it returns nothing :)
<haelix> the "normal language" way of understanding it
<sgillespie> oh...heh, wrong signature
<haelix> is that it is afunction that takes three arguments, of interdependant types:
<sgillespie> silly me
<sgillespie> ('a, 'b) t -> 'a -> 'b
<haelix> ok
<haelix> two arguments
<sgillespie> yeah
<haelix> one of type ('a, 'b) t
<haelix> another one of type 'a
<haelix> it will then return a value of ty 'b
<haelix> I guess 'a is the key type
<haelix> and 'b the value type
<haelix> (for the hash table)
<haelix> so
<haelix> first, build an hashtable of (whatever_key_type_most_likely_string, int) t
<haelix> and the functionwill return you ints
<haelix> did a brick fell on top of your head ?
<sgillespie> gnuscreen was confusing me
<sgillespie> okay
<sgillespie> i think i had it all wrong from the beginning
<sgillespie> so for the argument ('a, 'b') t
<sgillespie> so i could pass
<haelix> well
<haelix> if you're actually using the hash table
<haelix> there's no such thing as a ('a, 'b) t
<sgillespie> yeah, confused myself again...that should be the hashtable
<haelix> 'a and 'b have been replaced by the actual key and value types
<haelix> for isntace
<haelix> (string, int) t
<sgillespie> okay
<sgillespie> so on...val create : int -> ('a, 'b) t...doesn't look like I can choose my types...right?
<flux> sure you can
<haelix> hmmm
G has quit [Connection timed out]
<haelix> I'm confused by this function signature, now !
<flux> let h : (int, int) Hashtbl.t = Hashtbl.create ()
<flux> uh, create 10 of course
<flux> but often you don't need to do that
<sgillespie> ok
<flux> let's say you enter (in ocaml toplevel) let h = Hashtbl.create 10
<flux> you'll get this in response: val h : ('_a, '_b) Hashtbl.t
<flux> when you do Hashtbl.find h "foo" the type of h is bound to (string, '_a) Hashtbl.t
<flux> when you do Hashtbl.find h "foo" = 42 the type of h is bound to (string, int) Hashtbl.t
<flux> do you don't usually need to explicitly tell the type (unless you're creating, say, a record, which has a field of such type)
<flux> ('_a is a type sort of like "first type that is used")
<sgillespie> okay
<sgillespie> this sounds doable
<haelix> flux: that's what I had intuitively guessed
<haelix> but that is surprising
<haelix> I wasn't aware that mutable types could have their type "refined"
<haelix> with usage
<sgillespie> thats pretty nice
<sgillespie> i really appreciate the help
sgillespie has quit ["leaving"]
pantsd has quit [Read error: 113 (No route to host)]
G_ is now known as G
eumenides has joined #ocaml
noteventime has joined #ocaml
schme` has joined #ocaml
G_ has joined #ocaml
eumenides has quit [Read error: 104 (Connection reset by peer)]
G has quit [Connection timed out]
ayrnieu has joined #ocaml
qwr has quit [Remote closed the connection]
schme`` has joined #ocaml
cjeris has joined #ocaml
schme` has quit [Connection timed out]
ygrek has joined #ocaml
noteventime has quit [Remote closed the connection]
eumenides has joined #ocaml
noteventime has joined #ocaml
ygrek has quit []
schme`` is now known as schme
aminorex has joined #ocaml
curtosis has joined #ocaml
schme has quit [Connection timed out]
pango has quit [Remote closed the connection]
pango has joined #ocaml
ygrek has joined #ocaml
bluestorm_ has joined #ocaml
schme has joined #ocaml
nearfar has joined #ocaml
<nearfar> my windows xp ocaml installation has some problems. the gui opens and closes (crashes?) immediately.
ygrek has quit [Remote closed the connection]
mikeX has joined #ocaml
gunark has joined #ocaml
<gunark> does anyone have experience using the OCaml fftw bindings?
<gunark> I got everything compiled and installed, bug I'm getting: The external function `fftw_import_wisdom_iter' is not available
<gunark> fftw doesn't even have a function with that name in the API...
ygrek has joined #ocaml
<hcarty> gunark: I haven't used the fftw bindings, but that may be some C wrapper function that is part of the fftw bindings
<gunark> it is...
<Smerdyakov> gunark, let me guess: You're trying to do this from the toplevel?
<gunark> well, the fftw distro includes a test.ml
<gunark> so i'm just doing
pango has quit [Remote closed the connection]
<gunark> ocaml fftw2.cma test.ml
<Smerdyakov> Yup. You would be well-served reading the manual page on the top-level.
<gunark> oi...
<gunark> see i went through all this a few months ago
<gunark> got it all working
<gunark> but it's been 6+ months
<gunark> and half of what i read in the manual, i've forgotten
<Smerdyakov> A pity... your error message isn't in their list of common errors, though it's very common here.
<gunark> any hints?
<gunark> or pointers?
<Smerdyakov> The punchline is that you need to build a custom top-level with your C objects linked in.
<gunark> ok that sounds vaguely familliar... ocamlmktop and such
<gunark> woohoo
<gunark> that worked
<gunark> thanks
pango has joined #ocaml
nearfar has quit [Remote closed the connection]
<gunark> ah for fucks sake
<gunark> i don't understand this toplevel linking business...
<gunark> I build a toplevel, and now the toplevel only works when I launch it from one directory, but not when I move it to another
<gunark> so I suspec it's using ./ for links to some things
<gunark> but for the love of me I can't figure out how/what
curtosis has quit ["Leaving"]
<gunark> oooh....
<gunark> looks like I have to specify the -I for the toplevel...
mikeX_ has joined #ocaml
ygrek has quit [Remote closed the connection]
benny has joined #ocaml
Submarine has joined #ocaml
mikeX has quit [Read error: 110 (Connection timed out)]
olegfink has quit [Read error: 104 (Connection reset by peer)]
benny_ has quit [Read error: 110 (Connection timed out)]
malc_ has joined #ocaml
ygrek has joined #ocaml
pango has quit [Remote closed the connection]
pango has joined #ocaml
mikeX_ is now known as mikeX
eumenides has quit [Read error: 104 (Connection reset by peer)]
mikeX_ has joined #ocaml
ygrek_ has joined #ocaml
pango has quit [Remote closed the connection]
pango has joined #ocaml
ygrek has quit [Remote closed the connection]
mikeX has quit [Read error: 110 (Connection timed out)]
<mbishop> Who was it looking for a generic print the other day? I see oleg's site has one
pantsd has joined #ocaml
<ygrek_> mbishop, thanks!
ygrek_ has quit []
pantsd has quit [Read error: 113 (No route to host)]
pantsd has joined #ocaml
mikeX has joined #ocaml
mikeX_ has quit [Read error: 110 (Connection timed out)]
the_dormant has joined #ocaml
the_dormant has quit []
love-pingoo has quit ["Connection reset by pear"]
pantsd has quit ["Leaving."]
G_ is now known as G
mikeX_ has joined #ocaml
mikeX has quit [Read error: 110 (Connection timed out)]
descender has quit [Read error: 113 (No route to host)]
mikeX_ is now known as mikeX
bluestorm_ has quit ["Konversation terminated!"]
Submarine has quit ["Leaving"]
cjeris has quit []
smimou has quit ["bli"]
noteventime has quit ["Leaving"]
<mbishop> tsuyoshi: you have your updated forking map code anywhere? (you've changed it since the blog post...right?)
tehdeuce has joined #ocaml