mfurr changed the topic of #ocaml to: OCaml 3.08.2 available! | Archive of Caml Weekly News: http://sardes.inrialpes.fr/~aschmitt/cwn/ | A free book: http://cristal.inria.fr/~remy/cours/appsem/ | Mailing List: http://caml.inria.fr/bin/wilma/caml-list/ | Cookbook: http://pleac.sourceforge.net/
palomer has quit ["Leaving"]
goomba has quit [Read error: 110 (Connection timed out)]
smimou has quit ["?"]
CosmicRay has quit [Remote closed the connection]
cjohnson has quit ["trout."]
cognominal has joined #ocaml
Skal has quit ["Client exiting"]
zzorn_afk has quit ["zzzzz"]
<dan2> hmm
<dan2> anybody have an example of read in use
<Smerdyakov> What is that?
<det> I think he means an example of OCaml's equivalent of read()
<dan2> yes
<Smerdyakov> Which is what?
<dan2> in C, reads a file descriptor into some sort of buffer offset x, length y
<Smerdyakov> No, what is it in OCaml?
<dan2> something goofy
<dan2> val read : file_descr -> string -> int -> int -> int
<dan2> I can't actually get to the data
<dan2> it just reads bytes
<dan2> because strings are immutable no?
<det> Why dont you reference the documentation for read?
<dan2> I did
<dan2> interesting
<dan2> if you set a string to a variable
<dan2> and feed it to read
<dan2> it actually puts the data there
<Smerdyakov> OCaml strings are mutable.
<dan2> didn't know htat
<vincenz> hi
<vincenz> anyone familiar with camlp4?
<dan2> Smerdyakov: am I able to ignore exceptions in ocaml...
<Smerdyakov> dan2, what do you mean?
<dan2> Smerdyakov: basically I'm creating an application that I have a realtime audio app pipe to
<dan2> Smerdyakov: it reads... if it can't write (EWOULDBLOCK) chucks the data
<Smerdyakov> dan2, I think you could have clarified without bringing in irrelevant details of the application....
<dan2> Smerdyakov: I just explained
<Smerdyakov> dan2, no, you didn't.
<dan2> <dan2> Smerdyakov: it reads... if it can't write (EWOULDBLOCK) chucks the data
<dan2> I'm referring to EWOULDBLOCK
<Smerdyakov> dan2, that sure doesn't parse as a sensible OCaml question for me.
<dan2> do I need to have ocaml try thing around it even if I'm ignoring hte exception
<Smerdyakov> What do you mean by "ignoring the exception"? Do you mean only some informal _intent_ of yours that is not reflected in the code?
<dan2> I want to ignore an exception
<dan2> completely
<dan2> I don't want anything in the application to deal with
<dan2> it
<dan2> I just want to let it go by
<Smerdyakov> What does is it mean to "ignore an exception"? Define it precisely.
<dan2> in C++, to not catch it
<det> If you dont catch the exception, it will halt your program
<dan2> s#catch#try/catch#
<Smerdyakov> Which will cause a top-level signal handler to catch it and abort your program, in a sensible system.
<Smerdyakov> And that's the same way OCaml works. There is a top-level, program-aborting exception handling for anything that goes completelty uncaught.
<vincenz> noone?
<det> vincenz, "Is anyone familiar with camlp4" is a really poor question
<dan2> det: what happens if I wrap the call in ignore()
<det> vincenz, You will almost certainly get better results by just asking your question
picard has joined #ocaml
<det> dan2, ignore has nothing to do with exceptions
<dan2> ok
<Smerdyakov> dan2, ignore is a function you could define yourself: let ignore _ = ()
<vincenz> basically I have a absyn datatype
<vincenz> I was hoping to use camlp4 to automatically generate a printer for absyn
goomba has joined #ocaml
<picard> if I make 2 constant constructors a = H | T;; and b = H | F;; is there any way to specify which one should be used during assignemt?
<Smerdyakov> No. You have shadowed the first H with the definition of the second.
<picard> Smerdyakov: is there something like namespaces in C++ to help avoid this problem?
<det> picard, either choose new names or put them in sub modules
<Smerdyakov> Sure. The module system
<picard> Smerdyakov: great thanks
<Smerdyakov> (Much better than namespaces)
<Smerdyakov> Though I would think you'd prefer to pick unique constructor names and avoid the problem.
<det> vincenz, Not that it was any kind of guarentee, it is just a rule of thumb for getting help on IRC :)
<Smerdyakov> vincenz, you can probably write a parser for datatype definitions yourself and generate the printers with your own stand-alone program.
<det> Camlp4 seems like a nicer way of doing it since you get the parsing for free and the code can be inline in your program rather than a seperate file
<det> vincenz, I was thinking of doing something similar for SML. Except instead of generating a pretty printer, I want to generate an efficient serializer from the datatype description
<vincenz> Smerdyakov: too much hassle
<Smerdyakov> det, I've done that for a subset of SML (not general purpose)
<det> Smerdyakov, Oh, nice!
<det> Smerdyakov, I would be very interested in the code!
<Smerdyakov> det, do you think it's non-trivial? I don't think there's anything interesting there.
<det> Smerdyakov, Still easier than spending time on it yourself
<Smerdyakov> Then it seems you would be very interested in the end product, but not necessarily the code. :)
<det> A little bit of both :)
* vincenz is doing an old icfp for fun
<vincenz> :P
<vincenz> parsing/lexing done
<Smerdyakov> vincenz, you should say "ICFP contest." ICFP is an academic conference.
<vincenz> I know
<vincenz> it's shorthand
<Smerdyakov> It's bad shorthand. The conference takes abbreviation precedence over the contest.
<vincenz> ...
<vincenz> sue me
kinners has joined #ocaml
__DL__ has joined #ocaml
vezenchio has joined #ocaml
gim_ has joined #ocaml
gim has quit [Read error: 60 (Operation timed out)]
kinners has quit ["leaving"]
CosmicRay has joined #ocaml
gim_ has quit [Read error: 110 (Connection timed out)]
gim_ has joined #ocaml
CosmicRay has quit ["Client exiting"]
grirgz has quit [Read error: 110 (Connection timed out)]
ipr has quit ["ircII EPIC4-1.2.9 -- Are we there yet?"]
Banana has quit [Remote closed the connection]
a-zwei has joined #ocaml
m3ga has joined #ocaml
bzzbzz has quit ["leaving"]
a-zwei has left #ocaml []
monochrom has quit ["Few people understand understanding."]
Snark has joined #ocaml
m3ga has quit ["disappearing into the sunset"]
skaller has joined #ocaml
skaller has left #ocaml []
Herrchen has joined #ocaml
Skal has joined #ocaml
cognominal has quit [Read error: 60 (Operation timed out)]
<mflux> btw, continuing to the earlier, about + and +., that isn't even inconvenient. what is inconvenient is using operator + with int, Int32 and Int64 in the same module ;)
<mflux> unless someone has a good hint for that
zzorn has joined #ocaml
Skal_ has joined #ocaml
Skal has quit [Read error: 60 (Operation timed out)]
<mrvn> Doing math with Int32/64 is tiresome.
* Snark prefers bigints
grirgz has joined #ocaml
<grirgz> plop
smimou has joined #ocaml
Submarine has joined #ocaml
cognominal has joined #ocaml
Snark is now known as xp
xp is now known as Snark
<Nutssh> 'open module XXXX in .... ' Or, if thats not standard, use submodules/include to get the same thing.
madroach has joined #ocaml
__mattam__ has joined #ocaml
mlh has joined #ocaml
madroach has quit ["leaving"]
goomba has quit [Read error: 104 (Connection reset by peer)]
cjohnson has joined #ocaml
juhammed_ has joined #ocaml
juhammed has quit [Read error: 104 (Connection reset by peer)]
Msandin has joined #ocaml
Herrchen has quit ["bye"]
Msandin has quit [Read error: 60 (Operation timed out)]
ntk has left #ocaml []
vezenchio has quit ["We learn from history that we learn nothing from history"]
grirgz has quit ["Free Software For Ever"]
pango__ has joined #ocaml
pango__ has quit [Client Quit]
pango has joined #ocaml
pango_ has quit [Read error: 60 (Operation timed out)]
mrvn_ has joined #ocaml
kassandre has joined #ocaml
<kassandre> hi ! how are you ?
<Smerdyakov> What is this? Some kind of JOKE?
<kassandre> why ?
<Smerdyakov> Because.
<kassandre> ok ...
<kassandre> where do you come from ?
<Smerdyakov> USA
mrvn has quit [Read error: 110 (Connection timed out)]
<kassandre> ok, i'm from france .. i love USA !
<kassandre> in wich state do you live ?
<Smerdyakov> California
<kassandre> oh yeah ! that must be cool !
<kassandre> los angeles ?
<Smerdyakov> No, Berkeley.
<kassandre> ok .. i don't know this town
<kassandre> did you ever been to los angeles ?
<Smerdyakov> Yes.
<kassandre> and how was it ?
<Smerdyakov> I didn't see much. It wasn't so great. Terrible traffic.
<kassandre> ah .. ok
<Submarine> hi Smerdyakov
<kassandre> and did you ever been to new-york ?
<kassandre> hello !
<Submarine> "have you ever been to"
<Smerdyakov> Submarine, hello; you shouldn't interrupt the interview!
<Smerdyakov> kassandre, yes. New York is even worse! Unfriendly people everywhere.
<kassandre> oh yes ?! I wasn't thinking this !
<kassandre> maybe nextsummer i'll go there
<kassandre> and which city do you reaaly like in USA ?
<Smerdyakov> Pittsburgh and Boston are my favorites. :)
<kassandre> ok ! i hope i will go there one day !
<kassandre> what kind of music do you like ?
<Smerdyakov> Various. I'm not really a music-o-phile.
<kassandre> ok. do you know french bands or singers ?
<Smerdyakov> Only Air.
<Snark> what a shame... xchat chose to color Submarine in blue...
<kassandre> that's exactly the answer i was waiting hihi ! i love Air !!
<kassandre> they are successful in USA ... more than in france
jourdechance has quit [Remote closed the connection]
<kassandre> so ... i have to go .. bye
<kassandre> see you !
<Smerdyakov> OK
kassandre has quit ["using sirc version 2.211+KSIRC/1.3.10"]
Sonarman has joined #ocaml
humasect has joined #ocaml
cognominal has quit [Remote closed the connection]
cognominal has joined #ocaml
monochrom has joined #ocaml
mbh has joined #ocaml
Submarine has quit ["Leaving"]
gim_ is now known as gim
smimou has quit [Read error: 113 (No route to host)]
smimram has joined #ocaml
xol has joined #ocaml
cjohnson has quit [Read error: 110 (Connection timed out)]
mlh has quit ["Chatzilla 0.9.66 [Mozilla rv:1.7.5/20041107]"]
* Smerdyakov notices a new feature in Coq that must have appeared with some apt-get upgrade.
<Smerdyakov> It keeps track of known values of hypotheses in some cases!
<__mattam__> like, it caches some things ?
<Smerdyakov> __mattam__, why aren't you in #hcoop? We were just talking about your broken web site!
<Smerdyakov> In old Coq, if you destruct a value of inductive type, you lose any connection between the old value and the constructor you found out it uses.
<Smerdyakov> A single round of syntactic substitution replaces all old occurrences.
<Smerdyakov> It looks like the new version keeps around the old value and the equivalence.
Sonarman has quit ["leaving"]
Snark has quit ["Leaving"]
<__mattam__> ok
Morphous has joined #ocaml
mfurr has joined #ocaml
Sonarman has joined #ocaml
Amorphous has quit [Client Quit]
xol has quit ["banana"]
mlh has joined #ocaml
Sonarman has quit ["leaving"]
det has quit ["Terminated with extreme prejudice - dircproxy 1.0.5"]
det has joined #ocaml
smimram has quit ["?"]
humasect has quit [Read error: 104 (Connection reset by peer)]
humasect has joined #ocaml
_shawn has joined #ocaml
shawn_ has quit [Connection timed out]
Skal_ has quit ["Client exiting"]
__DL__ has quit [Remote closed the connection]