<ayrnieu>
ozzloy - dependent on machine numbers, probably; perhaps minus a few bits. ocaml documentation will say. If you want bignums, it offers them.
<ayrnieu>
it also has Int32 and Int64 types.
<ozzloy>
i just tested it to be 2^30
<ozzloy>
positive
<ayrnieu>
uh, OK.
<ozzloy>
thanks again though
<dan2>
wow, I've need rlwrap for quite some time
<dan2>
ayrnieu: thanks
<dan2>
;)
m3ga has quit ["disappearing into the sunset"]
<Mr_Awesome>
does no one realize that ocamlbrowser has this?
shawn has quit [Read error: 110 (Connection timed out)]
shawn has joined #ocaml
pango_ has quit [Remote closed the connection]
pango_ has joined #ocaml
Mr_Awesome has quit ["and the Awesome Level drops"]
Snark has joined #ocaml
rillig has joined #ocaml
pango_ has quit [Remote closed the connection]
yondalf has joined #ocaml
yondalf_ has joined #ocaml
pango_ has joined #ocaml
yondalf has quit [Read error: 145 (Connection timed out)]
b00t has quit [No route to host]
pango_ has quit [Remote closed the connection]
pango has joined #ocaml
pango has quit [Remote closed the connection]
pango has joined #ocaml
Leonidas has joined #ocaml
b00t has joined #ocaml
bluestorm has joined #ocaml
YankeeWhite has joined #ocaml
<YankeeWhite>
Objective Caml room? wow!
<YankeeWhite>
downloading like 30 University of Washington ML language lectures and i think it's all OCaml
<YankeeWhite>
<3
dibblego has quit ["Leaving"]
yondalf__ has joined #ocaml
yondalf_ has quit [Read error: 110 (Connection timed out)]
smimou has joined #ocaml
Yankee|White has joined #ocaml
pango has quit [Remote closed the connection]
YankeeWhite has quit [niven.freenode.net irc.freenode.net]
ppsmimou has quit [niven.freenode.net irc.freenode.net]
Yankee|White is now known as YankeeWhite
pango has joined #ocaml
yondalf has joined #ocaml
yondalf__ has quit [Read error: 145 (Connection timed out)]
ppsmimou has joined #ocaml
yondalf has quit [Read error: 131 (Connection reset by peer)]
yondalf has joined #ocaml
pango_ has joined #ocaml
pango has quit [Remote closed the connection]
yondalf has quit [Read error: 145 (Connection timed out)]
yondalf has joined #ocaml
triple_ has joined #ocaml
yondalf_ has joined #ocaml
yondalf has quit [Read error: 145 (Connection timed out)]
<pango_>
there's also support for rational numbers, complex numbers, large numbers,... when people say "math function" they often mean "transcendantal function", but there's more to math than that...
Leonidas has quit ["An ideal world is left as an exercise to the reader"]
<ozzloy>
pango_: from the parameters of the assignment, they want real rational numbers only
<ozzloy>
pango_: is it 5 am where you are?
<pango_>
more like 2pm :)
<ozzloy>
so you're in europe?
<pango_>
yes
<ozzloy>
france maybe? that'd be cool
<ozzloy>
cuz ocaml has french connections somehow, yes?
<pango_>
well, the inria is a french institution, yes
<pango_>
I'm not sure the advantage for learning ocaml is as big as you make it... While some resources are only available in french, there's sufficient resources in english, japanese, etc... by now it seems
<pango_>
and when I was at uni, over ten years ago, I barely used ocaml... I (re)learned about the language mostly by myself since then
b00t has quit [No route to host]
<ozzloy>
pango_: oh i wasn't thinking of it like that
<ozzloy>
just the france idea being related to ocaml
<pango_>
you could say it's related to the british too... http://en.wikipedia.org/wiki/Robin_Milner... and many more... Languages, and ideas in general, usually do not appear out of void
<ozzloy>
cool
<TFK>
Is there anything built-in to convert a string to a list?
<pango_>
a list of what
<TFK>
a list of chars, for example
<pango_>
not in standard lib
<TFK>
And a list of ints?
<pango_>
of ints ?
<TFK>
You implied that some string->list conversions do exist.
<pango_>
yes, like Str.split to split string in a string list, given a delimiter
<TFK>
Oh, I see.
<pango_>
but to access characters, the most straightforward way in ocaml is s.[index], much like arrays
<pango_>
that said, a char list can be convenient, sometimes
<pango_>
writing a string_to_char_list function isn't that difficult
<TFK>
True.
<TFK>
How come strings weren't made a class?
<pango_>
what for ?
<TFK>
str#length is shorter than String.length str, no?
<bluestorm>
hum
<bluestorm>
TFK:
<bluestorm>
open String;;
<bluestorm>
print_int (length str);
<TFK>
And polute my the top namspace?
<bluestorm>
hum
<TFK>
-my
<bluestorm>
i don't do that
<bluestorm>
but you may want to
<bluestorm>
if you find String.x too long to write
<TFK>
Nah. But I wonder why OO wasn't taken advantage of in this case.
<bluestorm>
hum
<bluestorm>
i don't see the advantage of OO here
<bluestorm>
string is something static
<bluestorm>
a module is good
<bluestorm>
no need for inheritance or delayed name resolution or something like that
<TFK>
hum indeed.
<pango_>
to continue bluestorm idea, let sl = String.length ... print_int (sl str)
<pango_>
not that I use String.length often enough to care either ;)
<TFK>
True.
<TFK>
But I wonder: would it have been possible to make, for example, a unified iteration protocol for lists, strings, arrays with OO?
<bluestorm>
hm
<pango_>
like, what you get with HoF already ?
<pango_>
or functors ?
<bluestorm>
this would have needed some kind of underlying generalisation
<TFK>
What's HoF?
<pango_>
high order functions
<bluestorm>
TFK: ocaml native data are lower level than that, i think
<TFK>
pango_, but there is List.map and Array.map and whatnot.
<bluestorm>
a unified iteration protocol require you to think the access of your data structure in a very general way
<bluestorm>
how can you unify array and list ?
<bluestorm>
they do not have the same use
<pango_>
TFK: yes, of course
<TFK>
You can access them by index (O(n) for lists, but still possible).
<pango_>
TFK: and then when you know that the different datastructures have different complexities for access, etc, using a generic access on top of that is just feeding lies
<pango_>
extlib API on the other hand provides enumerations to iterate over the different kinds of sets it implements...
<TFK>
No, it's just adding another abstraction, which might leak. But all abstractions leak.
<pango_>
it's specially bad for datastructures that are supposed to be basic
<pango_>
because you usually know why you're using a list over an array, or the reverse
<TFK>
Still, it would be nice to accept "just an iterable" once in a while.
<TFK>
Or not :-)
<bluestorm>
hum i think the way it's actually handled is good
<bluestorm>
the function ask for the datastructure it should use
<bluestorm>
and if you have something different, just convert it by hand
<pango_>
use functorization... it's not plain luck that List.map and Array.map have the same name ;)
<mellum>
What's the problem with "fold"? It does just that.
<TFK>
BTW, you guys might be interested in http://www.spoj.pl/, OCaml (among many other good languages) is severely underrepresented there.
<TFK>
LablGTK is the prefered GUI toolkit for OCaml, right?
Foxyloxy has quit ["Sausages!"]
<smimou>
TFK: yes
<bluestorm_aw>
hum
<bluestorm_aw>
btw
<bluestorm_aw>
do you think there is some people doing ocaml interested by Qt ?
<buluca>
bluestorm_aw: maybe...
<buluca>
bluestorm_aw: butthere should be someone interested in writing bindings for qt!
<TFK>
I think more people may be more interested in wxWidgets, but I gather that the existing binding is kinda on a proof-of-concept level.
<buluca>
first I will try to use lablgtk2
<buluca>
btw, it would be useful to have libraries that read glade files run-time
<buluca>
currently it's only possible to compile them to ocaml
rillig has quit ["exit(EXIT_SUCCESS)"]
<TFK>
What's the recomended OCaml editor/IDE?
<ayrnieu>
tfk - 'the'? Emacs.
<TFK>
And the second best? ;-)
<ayrnieu>
Ask a better question.
<TFK>
OK. What is a recomended OCaml editor/IDE, which is neither emacs nor vim?
<ayrnieu>
If you mean "what OCaml IDEs does #OCaml recommend other than emacs or vi?", I don't recommend any. Someone else may answer you.
<TFK>
I have time :-)
<ayrnieu>
why don't you try some of the IDEs that people have made for O'Caml, then, and determine their suitability yourself?
<dark_light>
TFK, i use gedit for real editing and vi to quick edits or remote edits
<TFK>
Well, I'm trying to use Camelia (currently in editor-only capacity), and trying to figure how to copmile Cameleon2 on Windows. Maybe it'll even work ;-)
<dark_light>
and i am very happy with gedit :)
<TFK>
I might have been, had I been using Linux... I'm also looking at SciTe, if its website ever loads o_O
<ayrnieu>
oh, windows? I suggest UltraEdit to such people, as an alternative to emacs+vi.
<TFK>
lol @ "such people"
<TFK>
But thanks, will look into it
<buluca>
I only use Emacs + Tuareg
<ayrnieu>
I'd never assume that someone uses !unix; it's rude.
<buluca>
windows? ohh... sorry
<TFK>
Mmm, shareware?
<TFK>
ayrnieu, I think most of the world's PC users use !unix, so rude or not, it's pretty probable.
RSi_ is now known as RSi
<ayrnieu>
tfk - I don't care about "most of the world's PC users".
<TFK>
Then your target audience is very narrow.
<ayrnieu>
sure, supposing that I had one.
<ayrnieu>
My non-assumption remains.
<TFK>
You don't have one? Don't you write software?
<TFK>
Or do you write only for private usage?
<Kzzch>
I think you can use emacs under cygwin
<TFK>
emacs works quite well in a "pure" Windows environment.
<Kzzch>
i'd have to second bulucas suggestion though. i'm using aquamacs with taureg, i love it
ceztko has joined #ocaml
<ceztko>
hi!
<TFK>
hulo
<ceztko>
ALL: is it fleasible to use ocaml shared objects in C/C++ projects? Thanks