<adrien>
hcarty: I was asking because deriving did not work on my computer, I should spend more time on it but I don't have that much (well, I guess I could find some...)
Edward_ has quit []
<adrien>
hcarty: but it doesn't matter a lot for me: I'm already generating code from .x (xdr, for sun/onc rpc) and it's easy to add that
mjonsson has quit [Remote host closed the connection]
ulfdoz has quit [Read error: Operation timed out]
Yoric has joined #ocaml
ftrvxmtrx has quit [Quit: Leaving]
<gildor>
thelema: no, type-conv need only ocaml-nox
<gildor>
+camlp4 off course
Modius has quit [Ping timeout: 272 seconds]
ftrvxmtrx has joined #ocaml
Yoric has quit [Quit: Yoric]
as has joined #ocaml
Amorphous has quit [Ping timeout: 252 seconds]
as_ has joined #ocaml
as is now known as Guest3129
as_ has quit [Client Quit]
as has joined #ocaml
Guest3129 has quit [Ping timeout: 240 seconds]
Amorphous has joined #ocaml
linux-m00n has joined #ocaml
as has quit [Quit: leaving]
verte has joined #ocaml
verte has left #ocaml []
Snark has joined #ocaml
Yoric has joined #ocaml
ikaros has joined #ocaml
ikaros has quit [Quit: Leave the magic to Houdini]
ikaros has joined #ocaml
ttamttam has joined #ocaml
ttamttam has left #ocaml []
chee has quit [Ping timeout: 252 seconds]
barismetin has joined #ocaml
_andre has joined #ocaml
avsm has joined #ocaml
chee has joined #ocaml
th5 has joined #ocaml
init1 has joined #ocaml
goncalo has joined #ocaml
ftrvxmtrx has quit [Quit: Leaving]
ftrvxmtrx has joined #ocaml
init1 has quit [Quit: Lost terminal]
linux-m00n has quit [Ping timeout: 276 seconds]
init1 has joined #ocaml
init1 has quit [Client Quit]
init1 has joined #ocaml
th5 has quit [Quit: th5]
grettke has joined #ocaml
init1 has quit [Quit: Lost terminal]
init1 has joined #ocaml
_unK has joined #ocaml
Yoric has quit [Read error: Connection reset by peer]
Yoric has joined #ocaml
Yoric has quit [Read error: Connection reset by peer]
Yoric has joined #ocaml
mjonsson has joined #ocaml
Modius has joined #ocaml
f[x] has quit [Ping timeout: 272 seconds]
mjonsson has quit [Remote host closed the connection]
f[x] has joined #ocaml
ccasin has joined #ocaml
aliudalius has joined #ocaml
joewilliams_away is now known as joewilliams
jakedouglas has joined #ocaml
<aliudalius>
could somebody give me a quick explanation about how caml, ocaml, and standard ml differ?
<flux>
doubtful, but there exists a page that compares standard ml and ocaml
<aliudalius>
caml.inria.fr <-- reading now
<rwmjones>
aliudalius: caml is essentially an older version of ocaml. Standard ML is a fairly different language, but ML was a common influence behind SML, OCaml and other languages.
<rwmjones>
if you want details, that's going to take a book to explain :-)
<rwmjones>
aliudalius: btw, people use "caml" and "ocaml" interchangably
<rwmjones>
refering to ocaml
<aliudalius>
rwmjones: thanks, that clears it up a bit - especially that laspt tidbit.
<rwmjones>
but there is something else called CAML which was the predecessor
<aliudalius>
last*
<aliudalius>
so, if nobody feels the need to field this question, I completely understand (as I don't want to be a bother), but if someone cares to lionize the language, why ocaml? Over say, CL, Haskell, Python, Ruby, and so on?
<flux>
it's a statically typed practical-oriented language
<rwmjones>
it's practical and safe
<kaustuv>
In comparsion with CL, OCaml has algebraic datatypes and pattern matching, which is much friendlier than car/cdr or destructure macros. In comparison with Haskell, OCaml's runtime behaviour, especially space usage, is much easier to predict. Vs. Python and Ruby, OCaml wins because it's far far more performant, and in some ways better suited for writing functional programs. Ruby and to an extent Python and CL win if you are allergic to
<kaustuv>
types and think metaprogramming is a panacea.
<gildor>
once compiled there are always very few runtime errors
<gildor>
the same behavior with C/Perl/Python/Ruby requires a lot more stricter policy regarding input/output of functions
<gildor>
with OCaml, the compiler checks most of the problem at compile time
joewilliams is now known as joewilliams_away
<gildor>
however, I think that Haskell is also nice
<kaustuv>
In any case, there are no universal answers about language choice. Zealotry about languages is about as useful as zealotry in religion.
<kaustuv>
Well, except that we can all agree, I think, that COBOL sucks
aliudalius has quit [Ping timeout: 252 seconds]
<gildor>
kaustuv: COBOL sucks, as an ex-COBOL "so called" expert, I cannot agree
<gildor>
;-)
chee has quit [Ping timeout: 252 seconds]
<gildor>
COBOL is a punishment but it has some nice features
<gildor>
features ~= the most unparseable thing I have ever seen
<gildor>
like internal CICS section (better than camlp4)
<kaustuv>
You like writing things like: PERFORM LoopBody WITH TEST VARYING LoopCount BY 2 UNTIL LoopCount GREATER THAN 5 ?
<hcarty>
adrien: I'm hoping to give deriving a try in the coming weeks/months - if I get it working I'll let you know
<gildor>
kaustuv: this is tongue-in-cheek, but remember that COBOL remains one of the major language in the world
<flux>
how cool would that be, if there was COBOL syntax for O'Caml. or Haskell.
<gildor>
hell on earth ;-)
aliudalius has joined #ocaml
<gildor>
COBOL remain an heavily not typed system
<gildor>
I think that PHP has a better type system
<kaustuv>
<:COBOL< KILL ME NOW. >>
joewilliams_away is now known as joewilliams
ftrvxmtrx has quit [Read error: Connection reset by peer]
avsm is now known as avsm^afk
<kaustuv>
Uh, how did I get on the oasis-bugs mailing list?
<gildor>
you mean you want to receive update on a bug you submitted or on all bugs ?
<gildor>
kaustuv: ^^^
ftrvxmtrx has joined #ocaml
<kaustuv>
Preferably neither, though only on my bugs is OK. However, I just got an e-mail about the bug that ygrek just submitted that has nothing to do with me.
<gildor>
you probably ask to monitor the whole BTS
<ygrek>
when do people get sane and stop using random non-compatible ridden with backward compatibility quirks and platform-dependent crutches shell crap for build systems?
<flux>
ygrek, I guess when they start using real programming languages for build systems..
<adrien>
flux: set -x would give a readable call
<flux>
in a way ocamlbuild is a way towards that
<flux>
adrien, in make?
<flux>
I don't even know why it doesn't echo the line
<adrien>
ah, ok, I thought it was shell script
<flux>
ah, PKG_SILENT made that happen
jakedouglas has quit [Quit: Leaving.]
<flux>
bah, now I have lwt uninstalled and cannot install it anymore
julm has joined #ocaml
<adrien>
xD
<flux>
hmph, I tried to reproduce it, but of course I accidentally had applied the fixing command line argument as well
ccasin has quit [Quit: Leaving]
ygrek has quit [Ping timeout: 245 seconds]
<adrien>
last time I had to use patches in godi was really painful =)
<hcarty>
With luck, the oasis-related tools and infrastructure will help smooth all of this out
chee has quit [Ping timeout: 252 seconds]
<adrien>
I still want to build a compile/test-farm where you submit a package and it gets compiled on a variety of systems (OS and archs) whenever something is changed
<adrien>
(along with deps =) )
<flux>
I wonder if godi is going to make use of oasis somehow
<hcarty>
adrien: CPAN provides that I believe, including running any available test suite
<adrien>
hmmm, interesting
<hcarty>
I think the CPAN client can also report user build + test results
<hcarty>
That may be a nice option to have in oasis(db), along with some form of reporting based on those results.
<adrien>
lack of time means I would probably "require" everything to be done via oasis (not necessarily -db)
ygrek has joined #ocaml
<adrien>
btw, if someone makes that, I can join at least a fast quad-core with 4GB of ram (maybe more soon) and enough disk space, another computer (slower dual-core) and maybe another quad-core
<hcarty>
Here as well, sadly
<adrien>
processing power shouldn't be a problem at least
Snark has quit [Quit: Ex-Chat]
<adrien>
something I want to have and that cpan probably doesn't do is: compile and test _each_ commit: as an early-warning system ;-)
<adrien>
like, you commit, push, and three minutes later, you get a mail telling your commit broke 3 packages and doesn't compile on 2 machines =)
oriba has joined #ocaml
noj has quit [*.net *.split]
noj has joined #ocaml
<hcarty>
adrien: That would be quite cool
<hcarty>
I saw a post recently about a local auto-test-on-commit for Perl modules
<hcarty>
With git
<hcarty>
Something testing across multiple architectures and OSs would be very cool
<hcarty>
Testing with that level of granularity, that is
<flux>
hmm.. how do you 'fork' in lwt?
<flux>
I was expecting there'd be a function like val spawn : (unit -> 'a Lwt.t) -> unit Lwt.t somewhere
<hcarty>
flux: As in a Unix.fork?
<flux>
hcarty, well, not really, rather like Thread.create
<hcarty>
Ah
<hcarty>
In that case, I don't know :-) I'm still waiting/hoping for a project where I can take advantage of Lwt
<flux>
I sort of have one, and I don't want to use Thread/Event
<flux>
but Lwt apparently doesn't completely fit the model of writing such programs I have in my head :)
<flux>
ah, Lwt.ignore_result
<flux>
the name is sort of descriptive, yes, but I'd rather have picked inspiration for naming the function from the first line of documentation: You should use this function if you want to start a thread.. ;-)
lpereira has quit [Ping timeout: 272 seconds]
yezariaely has joined #ocaml
<yezariaely>
how do I solve the problem of cross calling functions, e.g. s.th. like let x = (y) let y =(x) of course this example is not very good, but I hope it shows the problem
<adrien>
ever seen something like 'let rec x = ... and y = ...' ?
<yezariaely>
adrien: ah yeah sure! I remember. thx
<adrien>
=)
ygrek has quit [Ping timeout: 245 seconds]
<hcarty>
Has anyone here used the ocamlnet FTP client modules?
<hcarty>
The documentation looks a little ominous with regard to how reliable it is
<adrien>
doesn't sound too good, right
<adrien>
why do you need ftp? (do you really need it?)
<hcarty>
I don't really - I could use the libcurl bindings for example. I need to query a remote file's size
<hcarty>
I could use libcurl for the download, not sure about a file size check
lpereira has joined #ocaml
init1 has quit [Quit: Quitte]
easy4 has quit [Quit: easy4]
easy4 has joined #ocaml
<gildor>
hcarty, adrien: I plan to create an "install" submodule for OASIS
<gildor>
i.e. OASIS install ocaml-fileutils will download and build ocaml-fileutils and its dependencies
<gildor>
the "early-warning system" can be seen as OASIS register (tell OASIS to consider a local directory rather than OASIS-DB) + OASIS upgrade (rebuild everything)
<gildor>
for example, I am upstream of ocaml-fileutils, so I don't want to use the version from OASIS-DB
<gildor>
cd programmation/ocaml-fileutils
ftrvxmtrx has joined #ocaml
<gildor>
OASIS register
<gildor>
I already have another package "ocaml-gettext" that build depends on "ocaml-fileutils"
<gildor>
I change something in my local copy (the one in programmation/ocaml-fileutils)
<gildor>
OASIS upgrade
oriba has quit [Quit: Verlassend]
<gildor>
will rebuild ocaml-gettext because of the change
<gildor>
concerning patching
<hcarty>
gildor: Oh, that sounds really cool
<gildor>
I plan to provide a downloadable "quilt" repository on OASIS-DB
<gildor>
so you can download an apply series of patches from OASIS-DB (and OASIS-DB will take care of sending it upstream, if you upload a new patch)
<gildor>
hcarty: thanks, for now this is just something written in the technical specification
yezariaely has quit [Quit: Leaving.]
<gildor>
hcarty: one day this will be the reality
<adrien>
can't wait for it =)
<gildor>
nor do i
Yoric has joined #ocaml
ulfdoz has joined #ocaml
_andre has quit [Quit: *puff*]
sepp2k has quit [Quit: sepp2k]
Yoric has quit [Quit: Yoric]
jakedouglas has joined #ocaml
ikaros has quit [Quit: Leave the magic to Houdini]
Fisherman has joined #ocaml
<Fisherman>
Hello
<hcarty>
Fisherman: Hello
julm has quit [Ping timeout: 255 seconds]
<Fisherman>
Is there a way to specify what variant type I mean?
<gildor>
Fisherman: could you give us an example, I am not sure to understand
<Fisherman>
yes
<Fisherman>
type this = Foo | Bar;; type that = Baz | Bar;;
<gildor>
if it is at the same level, no luck
<Fisherman>
How can I express that I mean Bar as in 'this'
<Fisherman>
really?
<gildor>
if it is in different module, that is ok
<Fisherman>
Okay
<Fisherman>
Thank you
<gildor>
e.g. file A.ml type this = Foo | Bar file B.ml type that = Baz | Bar -> A.Bar or B.Bar
<Fisherman>
I just started learning ocaml
<gildor>
another possibility is to use polymorphic variant
<Fisherman>
I read about that, but I got confused :)
<adrien>
they're mostly like regular variants but more relaxed, you can use them mostly like regular ones
<adrien>
maybe if you tell us what you wanted to achieve and why you wanted to reuse the variant we could help you more
<gildor>
type this = [ `Foo | `Bar];; type that = [ `Baz | `Bar ];;
<gildor>
# let f_this = function `Foo | `Bar -> true;;
<gildor>
but this is very relaxed, it means that you use anything named `Bar with f_this
lpereira has quit [Quit: Leaving.]
<Fisherman>
I thought it would make sense to use the same name for two similar variants
ulfdoz has quit [Ping timeout: 240 seconds]
<adrien>
it's a "limitation" of ocaml: if you have twice the same name, ocaml can't guess which type the variant comes from: "this" or "that" (from your example 14 minutes ago)
<Fisherman>
yes, but I think it would be nice if you could specify the type if ocaml can't infer it
<Fisherman>
like this:Bar
<Fisherman>
maybe
<adrien>
well, it's not so much that it can't, but that the most recent definition will "shadow" the previous one(s)
<adrien>
but polymorphic variants can work nicely here: they let you define a type, supertypes, supersupertypes, with common subsets
<adrien>
I need to go to bed, good night
<Fisherman>
good night adrien
julm has joined #ocaml
<gildor>
Fisherman: the basic reasoning (IMHO) is that you don't frequently have twice the same variant in a single module
<gildor>
another possibility (BTW)
<gildor>
type this = .... let f_this = function Bar | Baz -> true;; type that = Foo | Bar;; ...
<gildor>
if you put the function in the middle, the shadowing is not yet there