* olasd
is eager to ditch those lousy fedora 8's...
rossberg has joined #ocaml
<orbitz>
olasd: i have no idea what is going on here. avsm is teh one who maintains the homebrew opam package though, so perhaps he can help. Shoot a message to caml-list
<orbitz>
olasd: maybe deps are wrong? is there an ocaml xml-light you can install?
Kakadu has quit [Ping timeout: 255 seconds]
ttamttam has quit [Read error: Connection reset by peer]
ttamttam has joined #ocaml
ttamttam has quit [Read error: Connection reset by peer]
ttamttam has joined #ocaml
tane has joined #ocaml
mye has quit [Quit: mye]
dwmw2_gone is now known as dwmw2
ontologiae has joined #ocaml
eikke has quit [Ping timeout: 264 seconds]
_andre has joined #ocaml
Kakadu has joined #ocaml
ollehar has quit [Ping timeout: 245 seconds]
mcclurmc has joined #ocaml
ollehar has joined #ocaml
thomasga has joined #ocaml
ollehar1 has joined #ocaml
ontologiae has quit [Ping timeout: 256 seconds]
ggole has joined #ocaml
ollehar1 has quit [Ping timeout: 252 seconds]
weie has joined #ocaml
awm22 has quit [Quit: Leaving.]
<olasd>
ok; building opam-latest instead of 1.0.0 seems to fix the issue
<olasd>
or sidestep it, at least
yacks has quit [Ping timeout: 264 seconds]
awm22 has joined #ocaml
martin_ has joined #ocaml
martin_ is now known as emj_
<emj_>
Hello. I'm having some trouble with pa_ounit. Cannot seem to run my tests (generated ounit_tests does not exist). Anyone had trouble with this?
awm22 has quit [Quit: Leaving.]
<orbitz>
emj_: Does a simple case work for you?
<emj_>
orbitz: No, I can build the test project as long as I don't add a call to "OUnit.run_test_tt_main ounit_tests()".
<emj_>
orbitz: (Building with oasis.)
eikke has joined #ocaml
yacks has joined #ocaml
awm22 has joined #ocaml
<companion_cube>
graphviz is so awesome <3
emj_ has quit [Remote host closed the connection]
cgaebel has joined #ocaml
ontologiae has joined #ocaml
mye has joined #ocaml
mye has quit [Client Quit]
ollehar1 has joined #ocaml
troydm has quit [Quit: What is hope? That all of your wishes and all of your dreams come true? (C) Rau Le Creuset]
troydm has joined #ocaml
<zorun>
companion_cube: well, maybe awesome for some parts, but not *so* awesome :)
<flux>
a graph layour library for ocaml would be even more awesome :)
<flux>
(with support for incremental layouting, including modifications)
<companion_cube>
zorun: it could be better, I guess, but it's still pretty cool
<companion_cube>
especially since printing graphs is soooo simple
hkBst has quit [Read error: Connection reset by peer]
hkBst has joined #ocaml
hkBst has quit [Changing host]
hkBst has joined #ocaml
travisbrady has joined #ocaml
travisbrady has quit [Ping timeout: 260 seconds]
adrien_o1w is now known as adrien_oww
mye has joined #ocaml
darkf has quit [Quit: Leaving]
travisbrady has joined #ocaml
q66 has joined #ocaml
ollehar1 has quit [Ping timeout: 252 seconds]
notk0 has joined #ocaml
<notk0>
hello
<notk0>
I had a function that returned a type that was of the form
<notk0>
a'*b'
<notk0>
now I changed it to list of something that is a list of tuples as well * (a*b)
<notk0>
when I do let (listm (a,b)) = call foo
<notk0>
I get a type error
<notk0>
is it a problem with my syntax?
mye has quit [Quit: mye]
travisbrady has quit [Ping timeout: 264 seconds]
hkBst has quit [Read error: Connection reset by peer]
hkBst has joined #ocaml
travisbrady has joined #ocaml
cago has left #ocaml []
Kakadu has quit [Quit: Page closed]
Kakadu has joined #ocaml
awm22 has quit [Quit: Leaving.]
Kakadu has quit []
Kakadu has joined #ocaml
<notk0>
hello
<notk0>
I am working with OCaml compiler Lambda type, and I was wondering how can Ocaml determine if a value inside a match corresponds to a constant constructor, or a non constant constructor block?
<ousado>
notk0: re your previous question, how about a small example demonstrating the problem?
<notk0>
ousado: I am going to code it later today I hope, I don't have an actual problem...
<notk0>
ousado: oh you're talking about my other question?
<ousado>
yes
<notk0>
ousado: I managed to fix it, but I didn't understand the problem, I was just messing with parantheses until I fixed it
<notk0>
ousado: I must have used an incorrect paranthesis or something that made the type be correctly infered I think
<notk0>
ousado: I think I'll have the older code Ill try to find it and compare the two versions and see where I did wrong
<ollehar>
can I add a method to an immediate object after creation? like with record copy {bla with ...}
<flux>
notk0, hmm, did you not solve it by let (listm, (a, b)) = call foo?
<flux>
notk0, "," is an essential part of the tuple syntax..
<thelema_>
ollehar: I don't think OCaml allows you to do this; immediate objects don't have an associated class, so the inherit keyword doesn't work, and every other way I can think ends up re-implementing the method dispatch
<notk0>
flux: I see the problem now,I put paranthesis arround the second argument
<notk0>
flux: wait I don't see yet, give me some more time
<flux>
to construct a tuple you do this: (4, (3, 2))
<flux>
which is the same (barring surrounding operators/precedence) as 4, (3, 2)
<ollehar>
thelema_: ok, thanks
<notk0>
ok I am confused
<flux>
which is not the same as 4, 3, 2 :)
<flux>
and to deconstruct that you do let (a, (b, c)) = (4, (3, 2))
rwmjones has quit [Read error: Operation timed out]
<notk0>
ok the problem was the cast, it seems to work now flux
<notk0>
the problem was I did a (something, ( (a,v)::c,d):type
<notk0>
but I added that trying to fix it in the first place
<notk0>
does anyone know how OCaml determines the type of a value inside a match, if it's a constant constructor or not?
<notk0>
does it use the last bit?
<notk0>
if it's 0 it treats it as an index to the constructor list, else it treats it as a pointer?
<flux>
notk0, lowercase symbol is a binding, uppercase binding or a literal is a value to match
<flux>
this will not work as someone might expect: let a = 42 in match 44 with a -> (* a is now 44 here *)
<notk0>
what I mean is if I do match foo with | A -> 1 | B(i) -> i
<notk0>
how can it determine if foo is a constant constructor, or a non constant one?
<notk0>
at runtim
<notk0>
runtiem
<notk0>
runtime, sorry
<flux>
hmm.. you want to know if foo is a variable or a literal?
<flux>
I'm confused :)
<flux>
why does it need to know what foo is?
<flux>
it simply takes whatever foo is, a value or a literal, and then matches that
<notk0>
I am talking about the ocaml compiler, it was a Lambda type, and in the case of matches/switches it has a list of constructors and a list of blocks
<flux>
ok. well have you looked at what the ocaml compiler -dlambda outputs?
<notk0>
flux: but how does it know if it matches in the constructor list or blocks list?
<flux>
I'm afraid my knowledge of the lambda representation is zilch
<flux>
you know about value tagging?
<notk0>
flux: I am not sure, what is value tagging?
<flux>
if you have a value, say, 42 in ocaml, its tag bit (lowest bit) is 1. if you have a value that doesn't fit into one machine word (say, a string), you have a pointer to it, and the tag bit is 0
<flux>
not sure if this is relevant to what you're looking for :)
<notk0>
I heard about that
<notk0>
flux: I think it is relevant
<notk0>
flux: so I know if a vale is constant (say a number) or some complex type, a pointer?
<flux>
yes
<notk0>
flux: isn't it 0 for values, 1 for "complex typeS"
<notk0>
flux: that is exactly related to my question, I need to check if a value is a constant or not
<flux>
notk0, I'm not sure, but I think it makes more sense for it to be 1 for values, as with '0' you can just directly dereference the pointer
<flux>
notk0, look at the Obj module
<notk0>
if a value is an int that is higher than what it can be represented without the byte, it will point to a pointer?
<notk0>
why you can directly dereference the pointer with 0?
<notk0>
don't you have to do >> in both cases?
<flux>
no
<flux>
because stuff in memory is aligned
<flux>
when you allocate stuff, you never get an address with last bit 1
<notk0>
but a pointer is 32 bits no? ( on a 32 bit machine )? the last bit
<notk0>
oh I understand the pointer is alligned to 4?
<flux>
and if you do dereference such a value, you may pay a penalty
<notk0>
but those are still different pointers?
<flux>
or it can actually crash
<notk0>
hm
<flux>
(on certain architectures)
<notk0>
doesn't that depend on the
<notk0>
yeah
<flux>
notk0, also look at the section in the ocaml documentation about C interfacing
<ousado>
also integers are 31 bit on 32bit architectures and 63 bit on 64 bit ones
<notk0>
flux: well I will look at it, I just kinda needed to know that now
<flux>
notk0, good luck :)
<notk0>
makeblock (2 , immutable) (5) this is the custom string representation of a Block constructor, it allocated the value 2 (the index 2 of the constructor) with the result 5
<notk0>
flux: thank you, that clears up some things
<notk0>
so in ocaml you can't have ints with a value higher than 31 bits?
<notk0>
or it has object types to represent higher values?
<flux>
on 32-bit architectures and barring the module Int32, correct
<ousado>
yes
rwmjones has joined #ocaml
<notk0>
but the "primite" types ints, that I use in normal code, such as let i = 5; are on 31 bits on 32 bit architectures?
<ousado>
yes
<notk0>
oh ok thank you
<notk0>
so if I do max 31 bit + 1, it will overflow instead of storing it in a pointer?
<flux>
yes
<notk0>
oh ok thank you
<notk0>
flux: do you know where I can read about value tagging? I tried to google but don't find anything specific
<flux>
notk0, well, try searching for material on how to write C bindings for ocaml
<notk0>
flux: I will thank you
<flux>
notk0, it's only really relevant in that situation..
<flux>
and possibly not even then
<flux>
thanks to the C interface functions/macros
<flux>
notk0, why is this relevant to you, btw?
<notk0>
flux: or when writing an alternative ocaml compiler that relies on the internal ocaml compiler
<notk0>
lol
<flux>
ok
<flux>
good luck :)
<notk0>
flux: related to an assignment on compilation :D
<notk0>
thank you :D
<ousado>
the integer overflow thing always reminds me of that retarded article that ranks so high on google that probably everyone reading this knows what I mean ..
<notk0>
ousado: I don't
srcerer_ is now known as srcerer
hkBst has quit [Quit: Konversation terminated!]
Kakadu has quit []
ttamttam has quit [Quit: ttamttam]
<pippijn>
ousado: fefe's?
cdidd has quit [Read error: Operation timed out]
<ousado>
no that 'ocaml language sucks' one
<ousado>
pippijn: ^
<pippijn>
ah
eikke has quit [Ping timeout: 258 seconds]
<tane>
the guy who wrote it stated in 1999 that java was dead
<ousado>
ah pippijn - don't forget to make your camlp4 (de)serializer public , please ;)
<pippijn>
oh yeah
<pippijn>
thanks for reminding me :)
<pippijn>
I need a todo list somewhere..
mika1 has quit [Quit: Leaving.]
ttamttam has joined #ocaml
RagingDave has joined #ocaml
rwmjones has quit [Read error: Operation timed out]
Kakadu has joined #ocaml
travisbrady has quit [Quit: travisbrady]
travisbrady has joined #ocaml
rwmjones has joined #ocaml
beckerb has quit [Ping timeout: 245 seconds]
Neros has joined #ocaml
<companion_cube>
hmmm, I wonder whether a Graph equivalent of BatSeq would be useful
<thelema_>
graph?
<companion_cube>
well, a graph data structure
<companion_cube>
but that you can produce lazily
<companion_cube>
(either because it's too big, or because producing the whole graph is too costly if you just want to explore a few nodes)
<companion_cube>
and besides, a very abstract and generic mapping to/from graphs may be extremely useful
<thelema_>
lazy graph data structure can be useful in many cases
anderse has joined #ocaml
<companion_cube>
aww, I have to write it now :D
ollehar has quit [Ping timeout: 246 seconds]
smondet has joined #ocaml
anderse has quit [Quit: anderse]
so has quit [Quit: +++]
so_ is now known as so
<companion_cube>
looks hard to build such a graph
anderse has joined #ocaml
awm22 has joined #ocaml
ontologiae has quit [Ping timeout: 255 seconds]
Cyanure has joined #ocaml
mcclurmc has quit [Ping timeout: 264 seconds]
eikke has joined #ocaml
Kakadu has quit [Read error: Connection reset by peer]
Kakadu has joined #ocaml
pkrnj has joined #ocaml
travisbrady has quit [Quit: travisbrady]
Yoric has joined #ocaml
<notk0>
hello, suppose I have the following code:
<notk0>
. .. | Constructor( a,b,c) ->
<notk0>
let (a,c) = ....
ottbot has quit [Ping timeout: 256 seconds]
<notk0>
then the constructor c has it's meaning hidden?
<orbitz>
let (a, c) will rebind the values a, and c
<orbitz>
so the one you pull from the ctor will not be visible inside the let
<notk0>
it seems in my code that if you do
<notk0>
let (a,c) = foo or (a,c)
<notk0>
the second c is still available at that time
<orbitz>
at what time?
<orbitz>
the a and c on the right fo the = are from your ctor
<notk0>
the c on the right
<notk0>
let (a,c) = if something then foo else (a,c)
<orbitz>
yes, (a, c) there ar the avlues from your ctor obviously
<notk0>
the one in the else is still the original definition, and it makes sense I guess since it wasn't yet defined
<orbitz>
of course, what other meaning could they have?
<notk0>
anyway thank you, that makes sense
<notk0>
it doesn't seem possible for them to have another meaning
travisbrady has joined #ocaml
zbroyar has joined #ocaml
ggole has quit [Quit: Ex-Chat]
pkrnj has quit [Quit: Computer has gone to sleep.]
<wmeyer>
hi
<orbitz>
hi
<ousado>
hi
<orbitz>
hi
<wmeyer>
hi
<orbitz>
hi
<wmeyer>
hi hi
<wmeyer>
:-)
<wmeyer>
just got back from work
<adrien>
hi
<wmeyer>
hi
<orbitz>
hi
Neros has quit [Read error: Connection reset by peer]
Neros_ has joined #ocaml
<wmeyer>
hi
<orbitz>
opam is so nice
<wmeyer>
yep, it's a major breakthrough
<orbitz>
yeah, absolutely fantastic
<wmeyer>
i can say feels so much stable
<orbitz>
wmeyer: attendign OUD this year?
<adrien>
when is it and where?
<orbitz>
avsm is a pro, my merge request not in queue 10 minutes!
<orbitz>
adrien: Sept, Boston
<adrien>
hah, pretty far for me :P
<orbitz>
where are you based?
<adrien>
paris ;-)
<orbitz>
ah
<orbitz>
I'm trying to get my work to pay for it
<orbitz>
i have to be in boston that weekend anyways
<wmeyer>
orbitz: sounds good, when exactly?
<wmeyer>
adrien: so you part of OUPS?
<wmeyer>
we have Non-Disfunctional programmers meeetups
<wmeyer>
mostly OCaml
<wmeyer>
in CB
<pippijn>
nice name
<wmeyer>
pippijn: yeah
<adrien>
wmeyer: well, went last time and I might have to do a talk next time :P
<wmeyer>
adrien: great!
<wmeyer>
you sure you want to talk and not just drink beer?!
pkrnj has joined #ocaml
<wmeyer>
Cambridge has a great ale, actually
<adrien>
don't talk about drinking, please ='(
<orbitz>
wmeyer: 22 - 24 i think
<orbitz>
well
<adrien>
tomorrow beer and other alcohols
<orbitz>
i'm asusming OUD is part of CUFP again
* pippijn
is in shanghai
<adrien>
wednesday wine and I don't know what
<adrien>
thursday beer
<wmeyer>
pippijn: great!
<orbitz>
tuesday tequila?
<pippijn>
it's a rollercoaster
<adrien>
friday, can't remember; saturday probably some more drinking :P
<adrien>
orbitz: that sounds pretty good ;-)
<wmeyer>
:)
<pippijn>
tequila on every day that starts with a t
<wmeyer>
make sure you have enough salt and lemon
<wmeyer>
;)
<wmeyer>
pippijn: i tend to agree, Shanghai is a bit crowdy from what i heard, but i loved food and culture
<adrien>
:-)
<pippijn>
I had dinner for 310 yuan today
<pippijn>
kind of beyond my budget
<wmeyer>
pippijn: that's for korean BBQ in Chengdu
<pippijn>
korean bbq in shanghai is cheaper than that
<wmeyer>
but with full table
<pippijn>
more like 200
<wmeyer>
nope, i am talking about the best offer
<pippijn>
ah, well, yeah
<wmeyer>
yes it's about 180 in Chengdu
<wmeyer>
but 300 is over the top :-)
ttamttam has quit [Remote host closed the connection]
<wmeyer>
sorry, but that's pretty expensive to me although still would like to have it
<wmeyer>
have you been to Lijiang?
<pippijn>
it was way too expensive
<pippijn>
and the food wasn't even that special
<pippijn>
it was in tianzifang
<pippijn>
that's one of the most expensive areas in shanghai
<pippijn>
saturday, I had soup
<pippijn>
for 251 rmb :P
<wmeyer>
pippijn: wooha
<pippijn>
(I also had 4 other dishes)
<pippijn>
but it was at the "soup expert"
<wmeyer>
that's bad
<pippijn>
that was actually nice food
<pippijn>
in the same place as the korean bbq
<wmeyer>
it's £25 for soup?! you are more crazy than me actually
<pippijn>
well, yesterday I had a big plate full of noodles for 12 rmb
<wmeyer>
no, i enjoyed eating on the street too
<wmeyer>
especiall hand made noodles
<pippijn>
I enjoy it more, actually
<pippijn>
oh yes, these were hand made
<pippijn>
xinjiang restaurant
<wmeyer>
the ones stretched etc on your eyes?
<pippijn>
yes
<wmeyer>
i am talking about this ones
<wmeyer>
these*
<wmeyer>
yeah, they are nice
<pippijn>
I have a favourite in shanghai
<pippijn>
a favourite xinjiang restaurant
<pippijn>
I think I'll go there on wednesday
<wmeyer>
you have to go sichuan province
_andre has quit [Quit: leaving]
<wmeyer>
never had bad experience
<wmeyer>
orbitz: i think i might try to convince my employer sponsor the trip -- might be difficult, I want to go for POPL but it's probably not the most interesting for them
<orbitz>
does your employer do functional programming?
<orbitz>
I have to submit a talk for my employer to pay
<wmeyer>
can't really tell ;) i have some collegues that know how to program in Haskell
<pippijn>
can't tell = NDA?
<wmeyer>
actually my co-worker is long time haskell hacker
<orbitz>
ah
<wmeyer>
he is great
<orbitz>
I work for a rather large Erlang shop. Trying to sneak some ML in though :)
<wmeyer>
he did some work back in 90 about typing and FFI interface for Haskell.
<wmeyer>
Erlang is a gray area for me :-)
<adrien>
J!
<wmeyer>
yes J is nice, APL is really nice
<wmeyer>
i tried
<orbitz>
I'd actually love to take a J class
<wmeyer>
very compact
<wmeyer>
not much time in my shedule to start doing J