mbishop_ has quit [Read error: 104 (Connection reset by peer)]
batdog has joined #ocaml
coucou747 has joined #ocaml
Kopophex has quit ["Leaving"]
batdog has quit []
johnnowak has joined #ocaml
coucou747 has quit [Read error: 113 (No route to host)]
Associat0r has joined #ocaml
johnnowak has quit []
coucou747 has joined #ocaml
coucou747 has quit [Read error: 104 (Connection reset by peer)]
eelte has joined #ocaml
filp has joined #ocaml
filp has quit [Client Quit]
Snark has joined #ocaml
mbishop has joined #ocaml
Jedai has joined #ocaml
eelte has quit [Read error: 110 (Connection timed out)]
eelte has joined #ocaml
filp has joined #ocaml
filp has quit [Client Quit]
jonas_e has joined #ocaml
pango has quit [Remote closed the connection]
pango has joined #ocaml
guillem has joined #ocaml
Jedai has quit [Read error: 113 (No route to host)]
hkBst has joined #ocaml
Yoric[DT] has joined #ocaml
Linktim has joined #ocaml
asmanur has joined #ocaml
bluestorm has joined #ocaml
bluestorm has quit ["Konversation terminated!"]
bluestorm has joined #ocaml
Jedai has joined #ocaml
johnnowak has joined #ocaml
Yoric[DT] has quit [Read error: 113 (No route to host)]
gene9 has joined #ocaml
gene9 has left #ocaml []
Linktim has quit [Read error: 104 (Connection reset by peer)]
Linktim has joined #ocaml
Linktim has quit [Remote closed the connection]
johnnowak has quit []
Yoric[DT] has joined #ocaml
Linktim has joined #ocaml
asmanur has quit [Read error: 110 (Connection timed out)]
munga has quit ["Leaving"]
Jedai has quit [Read error: 113 (No route to host)]
bluestorm has quit ["Konversation terminated!"]
chessguy has joined #ocaml
petchema has quit [Remote closed the connection]
<chessguy>
i don't get it. defining recursive functions in ocaml has a different syntax from defining other functions?
<Yoric[DT]>
yep
<chessguy>
that's...interesting.
<Yoric[DT]>
There's a good reason to that.
<chessguy>
for optimiaztion reasons?
<Yoric[DT]>
let f = ....
<Yoric[DT]>
let f = ....
<orbitz>
chessguy stop followign me!!!
<Yoric[DT]>
With this extract, I have defined two functions f.
<Yoric[DT]>
(well, two symbols, not necessarily functions)
<Yoric[DT]>
now, my second symbol may use f -- in which case this f refers to the first one
<chessguy>
Yoric[DT]: oh, so it's to be able to establish multiple cases
<orbitz>
no
<Yoric[DT]>
It can be used for that (with extfun).
<orbitz>
Yoric[DT]: i'm not sure if that erason is really that good fo a reason
<Yoric[DT]>
But mostly, it's used to implement inheritance among modules.
<Yoric[DT]>
Or to replace existing functions by functions with the same overall behaviour but additional debugging/assertion/etc.
<chessguy>
hm, ocaml looks like a very interesting hybrid between functional and OO programming. i just wish its syntax wasn't so ugly
* Yoric[DT]
slaps chessguy with a wet trout.
<Smerdyakov>
chessguy, most OCaml programmers don't use the OO features.
<Yoric[DT]>
I actually like the syntax very much.
asmanur has joined #ocaml
<Yoric[DT]>
Except the useless OO part, that is :)
<chessguy>
Yoric[DT]: it could be worse, i suppose
<Yoric[DT]>
What are you comparing with?
<chessguy>
haskell
<Yoric[DT]>
Ah, ok.
<Yoric[DT]>
Have you looked at twt?
<chessguy>
never heard of it
<Yoric[DT]>
Since OCaml's syntax may be customized, there are several variants.
<Yoric[DT]>
You can load libraries at compile-time (for the pre-processor) to completely alter the syntax.
<Yoric[DT]>
twt is one such library
<chessguy>
wow, interesting
<Yoric[DT]>
It implements bi-dimensional syntax for OCaml.
<chessguy>
probably not a good idea to learn ocaml with such a library though
<chessguy>
that is, if you're learning ocaml, you should probably learn the main syntax first
jlouis has quit [Remote closed the connection]
<Yoric[DT]>
probably
<vixey>
I don't think it matters
<orbitz>
Yoric[DT]: is twt using functors for that or some other mechanism?
<vixey>
You probably wouldn't erase any preconceptions one might have though
<Yoric[DT]>
orbitz: not that I remember
<Yoric[DT]>
It's Camlp4.
<chessguy>
vixey: you mean preconceptions from knowing haskell first?
<orbitz>
oh ok
<Yoric[DT]>
So, yeah, the Camlp4 module may be functorized, but that's hardly exceptional.
<orbitz>
Yoric[DT]: oh no i was just wondering if you were refering to functors when saying youc an generate libraries at compiel tiem or camlp4
pango has quit [Remote closed the connection]
pango has joined #ocaml
flux has quit [Read error: 54 (Connection reset by peer)]
jlouis has joined #ocaml
flux has joined #ocaml
Linktim_ has joined #ocaml
<hcarty>
twt is done as a separate preprocessor, from what I understand
<hcarty>
No camlp4
guyzmo has quit [Remote closed the connection]
<Yoric[DT]>
hcarty: is it ?
<Yoric[DT]>
You're right.
<chessguy>
@pl f b a = h (d (l a - l b - 1) a))
<chessguy>
oops, wrong channel
Linktim has quit [Read error: 110 (Connection timed out)]
batdog_ has joined #ocaml
<hcarty>
I think there was some chatter on the mailing list about it being possible, with camlp4 3.10+, to do the same thing using camlp4. I don't know if anything has started with that.
sporkmonger has joined #ocaml
sporkmonger has quit [Read error: 104 (Connection reset by peer)]
sporkmonger has joined #ocaml
sporkmonger has quit [Client Quit]
<chessguy>
it surprises me that the OO features of ocaml aren't used much. i would have expected that it would be really handy when lightweight records aren't powerful enough
sporkmonger has joined #ocaml
<asmanur>
chessguy: actually, most of the time, they are
<chessguy>
asmanur: yeah, that's interesting to me, because haskell records suck
<vixey>
in ocaml they can be mutable
<asmanur>
chessguy: the only code that I know which use the OO features is Camlp4 and the bindings to OO library such as gtk
<chessguy>
vixey: "can be" as in optionally?
<vixey>
yes
<Smerdyakov>
chessguy, ya know, it couldn't hurt to just go read enough of the OCaml manual to understand what the basic features are.
<chessguy>
yeah, i started skimming through it
Linktim- has joined #ocaml
Linktim_ has quit [Read error: 110 (Connection timed out)]
batdog_ has quit []
Linktim_ has joined #ocaml
Linktim- has quit [Read error: 110 (Connection timed out)]
Linktim- has joined #ocaml
Linktim_ has quit [Read error: 60 (Operation timed out)]
<hcarty>
chessguy: The OO in OCaml is very handy and nice to work with in my opinion. There are those who use it quite often. However, for many tasks, the module system is easier and/or cleaner.
<chessguy>
i see
<hcarty>
The types can become rather long and complex when working with the object system in OCaml.
<orbitz>
hah
<orbitz>
that's ptutign it lightly!
<hcarty>
That said, there are trade offs. For some code, using OCaml's OO makes adding new functionality easier. For other code, the module system is easier.
<hcarty>
Jason Hickey's book has some good information on both the OO and module system
jeremiah has quit [Read error: 104 (Connection reset by peer)]
Ched- has left #ocaml []
jonas_e has left #ocaml []
love-pingoo has quit ["Connection reset by pear"]
jeremiah has joined #ocaml
<Associat0r>
#fsharp
<bluestorm>
#gotohell :-'
<RobertFischer>
bluestorm: I'm not sure, but I *think* it's a sin to use GOTO in #ocaml.
asmanur has quit [Remote closed the connection]
<RobertFischer>
:)
<bluestorm>
hmm
<bluestorm>
what's the call/cc way please ? :p
<vixey>
(hell '())
<RobertFischer>
match you | x -> hell(x)
<flux>
superfluous parenthesis!
<RobertFischer>
flux: Point.
<RobertFischer>
I just can't break myself of them.
<orbitz>
RobertFischer: know anything about twitters arch?
<RobertFischer>
orbitz: Not really. There's been a lot of talk about it, but I really don't care much.
<Associat0r>
sorry guys
<orbitz>
ah i'm curious how well it follows RoR methodology since people always point at it as the "look at waht RoR can do!" project
eelte has quit [Read error: 110 (Connection timed out)]
coucou747 has joined #ocaml
<RobertFischer>
orbitz: And it's killing RoR's reputation with its crappy performance.
<RobertFischer>
And instability.
<orbitz>
oh really? i thoguht ti was super stable?
<RobertFischer>
Twitter?
<RobertFischer>
Dude.
<orbitz>
yeah
<RobertFischer>
No way.
<RobertFischer>
At all.
<RobertFischer>
They've had to turn off the IM functionality for over a month now.
<RobertFischer>
And the error screen is so common that peoplea re joking that Twitter should put ads on it.
<orbitz>
"Twitter achieved approximately 98% uptime in 2007, or about 3 full days of downtime.[22][23] Twitter's downtime was particularly noticeable during events popular with the technology industry, such as the 2008 Macworld Conference & Expo keynote address.[24][25]"
<RobertFischer>
2007 was before they hit their hockey stick.
<orbitz>
teh real question is: how do enough people think twitter is wroth using
<orbitz>
stupidest web service ever
<RobertFischer>
It's actually pretty awesome. Super simple.
<RobertFischer>
I didn't get it either when I first tried it out.
<RobertFischer>
Something happened when I started following about 100~150 people. Suddenly I got it.
<orbitz>
hah
<orbitz>
someone on YC relates it to be west coast vs east coast
<orbitz>
west coast people just want lots of people to call friends whereas east coast tend to have a few firends with more direct communication
<RobertFischer>
orbitz: There's some of that on there. People who announce that they love all their Twitter friends just make me sad.
<orbitz>
the defintino of 'friend' has been paifnully molested in teh last decade
<RobertFischer>
No kidding.
<RobertFischer>
I use it more as a way to track/develop my network (I've gotten a couple of contracts off Twitter already), and to replace office banter (since I'm telecommuting).
<RobertFischer>
It's also a nice way to spam people with open questions without annoying them.
<RobertFischer>
Or sharing things that you want to tell someone, but you don't much care who.
<RobertFischer>
I used to post that crap to my blog, but people didn't appreciate it much -- I'd lose a couple of readers each time I did that.
<orbitz>
hrm, any good idioms for how to conditionally do things whena program has a whoel ton of config options?
<jonafan>
RobertFischer, are you the reason i listen to coverville
<RobertFischer>
jonafan: Probably not. You probably listen to it because it's awesome.
<jonafan>
oh, right
<RobertFischer>
jonafan: But I might be the person who introduced it to you. :)
<orbitz>
i heard you threatened him to listen to it
<jonafan>
you used to have a bunch of podcasts on your blog
<RobertFischer>
jonafan: Yeah. I might put them back on there, but a lot of them had gone away.
<RobertFischer>
And I didn't want to maintain that list.
<jonafan>
yeah
<jonafan>
i always have that problem with my bookmarks
<jonafan>
then i go back and try to remember why i bookmarked something and it's a completely different page!
<RobertFischer>
Yeah, that stinks.
<bluestorm>
hehe, that was cool : i was talking to a friend who wanted to use lisp for a little script because caml don't have a "cond", wich is handy to handle many-branch conditionnals
<flux>
I would use ocaml for all sorts of cool stuff, if only there was a syntax structure that solves the halting problem and prove poincare conjecture..
* flux
now starts waiting for bluestorm to produce some code
<bluestorm>
:D
<flux>
hm, wouldn't the "when" syntax fix that case better
<flux>
I suppose it's too verbose for him
<bluestorm>
flux: have you seen the idea on the mailing-list to use camlp4 to basically do the deforestation optimisation ?
<flux>
because it'd be only one step from match () with | () when ..
<flux>
bluestorm, nope
<flux>
bluestorm, subject?
<bluestorm>
hmm
Associat0r has quit []
<bluestorm>
« optimization of sequence of List.map and inlining »
<flux>
looking for it.. but in the meantime I found patterns announcement, and it provides some sort of pattern matching for objects :-o
<flux>
quite cool
<bluestorm>
yeah, the patterns annoucement is quite neat, i just began to look at the code
<flux>
(possibly even useful)
<bluestorm>
and it's not crystal clear :-'
<bluestorm>
(seems Yallop likes the tricky challenges anyway)
<bluestorm>
but it's interesting
<bluestorm>
(n+k patterns ! what the hell ?)
<bluestorm>
dinner time
<flux>
ah, there is one thing: no support for pattern guards at the moment
<flux>
I wonder if anyone is ever going to fix that Date: NaN-NaN-NaN-thing
<flux>
the archives didn't yet get to the point of discussing using camlp4 for deforestation
<flux>
but yeah, maybe some annotation would be possible
<flux>
let deforestate a = List.map f l in let deforestate a = List.map g a for instance?
<flux>
somehow List.map would need to be hardcoded into the semantics of deforestate, though.. maybe.
<flux>
perhaps it could be fully generic, by using the first parameter of function as the 'deforestating' function