<bluestorm>
it would not be difficult to do something like that, tailored for your specific needs
<bluestorm>
(as you can see, my module implement the abs operation, but you could deduce it from compare, zero and sub)
<flux>
there will be a performance hit, though
<flux>
I'm not sure how big one
<bluestorm>
flux: i've done measurements and the answer is : not much for non-native (int and float) types
<tails>
if the function calls get inlined, then there's no problem
<bluestorm>
the problem is with the type-specific specialization of the generic functions
<bluestorm>
wich do not occur in a functorized settings, and for some specific codes provide a comfortable performance improvement
<tails>
well, thanks all, i might as well go see how F# implements type matching
tails has quit ["the printf() fanclub"]
<bluestorm>
...
<bluestorm>
brain-dead tentative spotted
Associat0r has joined #ocaml
Associat0r has quit [Read error: 104 (Connection reset by peer)]
mfp_ is now known as mfp
Associat0r has joined #ocaml
zimbatm has joined #ocaml
love-pingoo has quit [Read error: 110 (Connection timed out)]
general has joined #ocaml
<general>
Can anybody point me to resources where I can learn OCaml (along with some theory about functional programming)? I only know C and Python, and have only a layman's idea about how functional programming languages work.
<general>
bluestorm: Since you guys are OCaml programmers, I'd like to know where *you* learnt from. And another thing. I hope the OCaml language hasn't changed much, since a couple of those tutorials are pretty old (2001-2003).
<bluestorm>
general: none of these tutorials are really outdated
<bluestorm>
there has been little change to the language, but they concern quite advanced parts
<general>
That Jason Hickey book says it's from 2008.
<bluestorm>
yeah, it's a recent rework from an older tutorial
<general>
By the time I reach the advanced parts, I'm sure I'll have seen enough code to be able to comprehend the official reference. I'll be at this a long long time, if I start :)
<bluestorm>
if you're new to functional programming, you'll have a hard (and delightful) time with the basis of the language ( expressions, recursion, typing, pattern matching ) wich have not changed at all
<bluestorm>
ah, and you should not try to pick the object oriented part first, even if you're used to other object oriented languages : it's vastly different and probably quite difficult if you're not used to the rest of the language
<general>
As you say. Actually, I want to learn some sort of a functional language before my college begins, even a small part will do.
<general>
I'm torn between Haskell, Erlang and OCaml.
<general>
Oh, and Lisp.
<bluestorm>
hm
<bluestorm>
depends on how much different from what you know you want it to be
<bluestorm>
i think OCaml is a good choice
<general>
Just different enough from C++ and Java. In India, they don't touch FP in college.
<general>
All they want to do is produce code monkeys for offshoring jobs.
<bluestorm>
Haskell is too different imho : you'll have to get all the idea of functional programming that are inside OCaml, plus some more due to purity (monads) and lazyness, all at the same time
<bluestorm>
on the other hand Erlang is simpler (no static typing and poor pattern matching), but you get less benefits from learning it at the same time :p , and it specialized in a, well, specialized area, concurrent programming
<general>
I heard about OCaml when a guy turned up with a raytracer in some 100 lines. Pretty neat, that :)
love-pingoo has joined #ocaml
<bluestorm>
i think OCaml is a good place to start. If you get the basis, you'll be able to learn Erlang quickly, and it will reduce the effort of learning Haskell
<general>
Okay then. I'll check out all those books and find out what fits me. Thanks :)
general has left #ocaml []
Morphous_ is now known as Amorphous
LordMetroid has quit [Connection timed out]
filp has quit ["Bye"]
pango has quit [Remote closed the connection]
marmotine has joined #ocaml
pango has joined #ocaml
LordMetroid has joined #ocaml
zbrown has left #ocaml []
arquebus has joined #ocaml
arquebus has quit [Remote closed the connection]
\banlist is now known as masterlinux
silentbicycle has joined #ocaml
silentbicycle has left #ocaml []
tomh has joined #ocaml
Associat0r has quit [Read error: 104 (Connection reset by peer)]