Taaus changed the topic of #ocaml to: http://caml.inria.fr/oreilly-book/
yangsx has joined #ocaml
yangsx has quit ["Client Exiting"]
smkl has quit [Read error: 110 (Connection timed out)]
smkl has joined #ocaml
DemiUni has joined #ocaml
gene9 has joined #ocaml
gene9 has quit ["Client Exiting"]
DemiUni has quit [Remote closed the connection]
gene9 has joined #ocaml
<Yurik> gene9: hi
<gene9> hi
gene9 has quit [Read error: 104 (Connection reset by peer)]
fcirinei has joined #ocaml
fcirinei has left #ocaml []
Yurik has quit [Remote closed the connection]
owll has joined #ocaml
Yurik has joined #ocaml
<Dybbuk> Howdy everybody!
<Yurik> Dybbuk: hi
owll has quit ["Client Exiting"]
<Dybbuk> I got some good 'Lazy' examples. I think I'm starting to get the hang of it.
<Yurik> Dybbuk: what for do you need lazy expressions?
<Dybbuk> Yurik: Oh, I don't know. I just thought it would be neat to play with.
<Dybbuk> Yurik: Actually, I do have one application I think it would be useful for...we're writing a search engine, and lazy evaluation could be useful there.
<Yurik> Dybbuk: ah
<Yurik> Dybbuk: OCaml really has interesting feature to play with (like camlp4 and so on)
<Yurik> s/feature/features/
<Dybbuk> Yurik: Yeah, I don't quite understand what camlp4 is yet...but I have seen a ton of stuff that I look forward to learning.
<Yurik> Dybbuk: well, may be, but I don't see what for :)
<Yurik> Dybbuk: camlp4 is a pre-processor-pretty-printer with very good facilities
<Yurik> Dybbuk: really tasty thing
<Dybbuk> Yurik: So what is it useful for?
<Yurik> Dybbuk: extending language for useful constructions, for example. you can change syntax of language quite easily but have OCaml inside :-)
<Dybbuk> I mean, do you have an example or a good webpage about it or anything?
<Dybbuk> Oh neat...
<Yurik> caml.inria.fr/camlp4/
<Yurik> or so
<Dybbuk> I think OCaml might be one of those languages that really takes off in popularity.
<Yurik> for example, in camlp4 distribution you can find revised syntax for OCaml, SML syntax and Lisp syntax :-))
<Dybbuk> Lisp syntax? Be still my heart! :)
<Yurik> like
<Yurik> (open Pcaml)
<Yurik> (open Stdpp)
<Yurik> (type (choice 'a 'b) (sum (Left 'a) (Right 'b)))
<Yurik> ;; Buffer
<Dybbuk> Hahaha, that is cool.
<Yurik> equal to
<Dybbuk> Ok, I'm going to check it out.
<Yurik> open Pcaml;
<Yurik> open Stdpp;
<Yurik> type choice 'a 'b =
<Yurik> [ Left of 'a
<Yurik> | Right of 'b ]
<Yurik> ;
<Dybbuk> Why aren't more people and projects using OCaml? It's easy and it's fast.
<Dybbuk> And it's powerful.
<Yurik> it's a language of my choice :-)
<Yurik> and other dummies program in C/Java and other imperative stuff ;))
<Dybbuk> Yeah.
<Dybbuk> Right now, we're a Perl and C shop.
<Dybbuk> Today I'm going to be arguing that it's time we moved into the 21st century, with a nice compiled, statically typed, semi-functional programming language.
<Dybbuk> Like, say, OCaml. :)
<Yurik> the most bad thing is that in my country I know only 2 OCaml programmers - my friend and me :)
<Yurik> :))
<Dybbuk> What country are you in?
<Yurik> Ukraine
<Dybbuk> Oh cool, do you like it there?
<Yurik> do I like my country? well, in fact i dunno :)
<Yurik> and nothing cool here :((
<Dybbuk> You mean aside from thousands of years of rich culture and history? :)
<Yurik> well, not aside, absolutely not. our country has quite rich culture and strange history :)
<Yurik> I mean economically it is not very good to live here :)
<Dybbuk> Yeah, I can understand that.
<Dybbuk> Why don't you leave?
<Yurik> Currently I can't get foreign passport
<Yurik> and have only local one
<Dybbuk> Ohh, damn. Well, you could always do contract work out of the country, right?
<Yurik> right
<Dybbuk> So what do you currently do for a living?
<Yurik> company in which I work does this
<Yurik> programming :)
<Dybbuk> Well heck, that's good. :)
<Yurik> :)
* Yurik is checkouting CVS version of ocaml
<Dybbuk> What kinds of features are they working on right now? Do you stay abreast of ocaml development?
<Yurik> i'm not in course, unfortunately :(
<Yurik> just fetching it to see what are the new features preparing
* Yurik looks at terminal.. it fetches very slow :(
<Yurik> My friend and I wanna make some proposal to Xavier and team for OCaml improvement, however
<Yurik> may be soon we'll prepare it
<Dybbuk> What kind of proposal?
<Yurik> proposal of what features needed in OCaml to be more ready for the masses
<Yurik> not very big proposal, however
<Yurik> the most important thing, I suppose, are "sticky" modules
<Yurik> it will be very useful for big projects
<Dybbuk> Another great thing would be to get the book published in English. :)
<Yurik> and the rest, too :-)
<Yurik> OCaml has book in English :)
<Yurik> I read it electronically
<Yurik> or you mean in printed form?
<Dybbuk> Printed form would be good.
<Yurik> I was mostly satisfied by reference manual and http://caml.inria.fr/oreilly-book/
<Dybbuk> Yes, they're both good.
<Dybbuk> That's how I've been learning.
<Dybbuk> Yurik: It looks like camlp4 has an easier way of doing lazy evaluation.
<Yurik> Dybbuk: what do you mean?
<Dybbuk> Yurik: The camlp4 streams stuff...the streams are lazy.
<Yurik> ah
samx has joined #ocaml
owll has joined #ocaml
samx has quit [Remote closed the connection]
gl has joined #ocaml
malc has joined #ocaml
owll has quit ["Client Exiting"]
malc has quit [carter.openprojects.net irc.openprojects.net]
Miwong has joined #ocaml
Miwong has quit [Client Quit]
malc has joined #ocaml
<Dybbuk> Ok, so what's the best way to 'uniq' a List?
* Yurik is back
<Yurik> Dybbuk: what do you mean by 'uniq'?
<Dybbuk> Yurik: Like, I have a list [ 5; 6; 7; 7 ] and I want it to just be [ 5; 6; 7 ]
<Dybbuk> Remove duplicates.
<Yurik> ÆÒ
<Yurik> sorry
<Yurik> ah
<Dybbuk> I basically have a list to add to another list, but I don't want dupes to show up. :)
<Yurik> not very difucult task
<Yurik> one moment
<Dybbuk> I was wondering if there was a built-in.
<Yurik> s/difucult/difficult/
<Dybbuk> l1 @ l2, but more like a union.
<Yurik> you can filter, using ref to remember filtered elts
<Dybbuk> Ok, I'll try that.
<malc> List.fold_left (fun accu elem -> if List.mem elem accu then accu else elem :: accu) []
<malc> sans stability
<Dybbuk> malc: Coool, thank you. I'll play with that.
<malc> n/p
<Dybbuk> Ok, I don't think I'm quite understanding fold_left.
<malc> Read manual, i must go fetch some sleep now...
<malc> ta-ta
malc has quit ["no reason"]
<Dybbuk> Ahh, I got it.
* Dybbuk had a folding epiphany!