Vincenz changed the topic of #ocaml to: http://www.icfpcontest.org -> join #ocaml team, contact Vincenz | http://icfpcontest.cse.ogi.edu/ -- OCaml wins | http://www.ocaml.org/ | http://caml.inria.fr/oreilly-book/ | http://icfp2002.cs.brown.edu/ | SWIG now supports OCaml| Early releases of OCamlBDB and OCamlGettext are available | Caml Weekly news http://pauillac.inria.fr/~aschmitt/cwn/
systems has quit ["Client Exiting"]
lus|wazze has quit ["Weird Al Yankovic - Frank's 2000 Inch TV - 'cuz "everybody in the town can hear those 90,000 watts of dolby sound!""]
taw has quit ["bye"]
reltuk has quit ["using sirc version 2.211+KSIRC/1.2.4"]
Smerdyakov has joined #ocaml
docelic is now known as docelic|sleepo
Smerdyakov has quit ["go"]
dodum has joined #ocaml
dodum has left #ocaml []
reltuk has joined #ocaml
lament has joined #ocaml
lament has quit ["I WILL NOT DISSECT THINGS UNLESS INSTRUCTED"]
lament has joined #ocaml
lament has quit ["I WILL NOT STRUT AROUND LIKE I OWN THE PLACE"]
rox has quit [asimov.freenode.net irc.freenode.net]
rox has joined #ocaml
docelic|sleepo is now known as docelic
systems has joined #ocaml
systems has quit [Read error: 110 (Connection timed out)]
Demitar has joined #ocaml
Demitar has quit ["There are bubbles in the air..."]
taw has joined #ocaml
<taw> is there some ocaml lint ?
<taw> i would like something that checks "let x = y in z", where x isn't used in z and other common spelling error candidates
<mrvn> Like gccs "Unused variable" warning?
<taw> yeah
<vegai> the compiler has warning flags at least
<vegai> don't know if it includes those warnings, though
<taw> i found that big part of my errors are typos that would be found by that
<vegai> taw: have you tried ocaml -W a?
<vegai> oops, that's '-w A'
<taw> doesn't help
lus|wazze has joined #ocaml
cDlm_ is now known as cDlm
reltuk has quit ["using sirc version 2.211+KSIRC/1.2.4"]
reltuk has joined #ocaml
cDlm_ has joined #ocaml
cDlm has quit [Killed (NickServ (Ghost: cDlm_!cdlm@lns-th2-5-82-64-68-218.adsl.proxad.net))]
cDlm_ is now known as cDlm
<mrvn> taw: use better/longer variable names. Vars like a, b, c are easily mistyped.
<taw> won't help
<taw> sources would grow 2x without solving the problem
<teratorn> ahah
<taw> lint is much better way
<teratorn> what's wrong with "unbound value error" ?
<mrvn> a value is unbound.
<teratorn> :/
<mrvn> you can#t just pick a value out of the blue.
<teratorn> that's not my meaning
<teratorn> i mean
<teratorn> taw: what's wrong with fixing it when it throws "unbound value"?
<taw> it doesn't throw even a warning
<taw> i want it to warn me when some "variable" is not used
<mrvn> Thats because your variables are so similar that a type error will still produce abound value.
<mrvn> Otherwise you have a logic error where unused variable would be some indication but not a cure.
<taw> lint is exactly for that
<teratorn> mrvn: no there's nothing wrong with let x = 1 in 3;;
<teratorn> but it's stupid
<taw> indicating where is some suspicious code
<taw> it may be correct, but is wrong so often that it really helps
<teratorn> it doesn't seem like it would be a very common thing
<taw> it is
<mrvn> yep. never head any ill effects from this
<teratorn> anyway, i don't know of a checker for that
<taw> not in so easy form
* teratorn away
<mrvn> Its a logic error that needs understanding of the code to properly detect.
<taw> and ocamllint could make a few other checks
<taw> lint is not or detecting errors
<teratorn> checking is good
<mrvn> let x = 1 in 3 is just its simplest form.
<taw> it's for detecting suspicious code
<taw> that's different thing, but very useful
<taw> usused bindings in pattern matching are one
<taw> there are often so many variables in it
<taw> that it's easy to make a mistake
<mrvn> taw: I guess ocaml optimizes unused variables in matchings out pretty good.
<taw> there are more such cases where code is "correct" but so suspicious that it almost ceratinly indicates an error
<taw> oh sure it does, but they indicate that something is wrong
<taw> if you didn't need it, you'd use _
<taw> if you named it, then there's likely a typo on right side
<mrvn> Thats a choice of style.
<taw> lint is about style :)
<taw> if (x = foo()) is also style problem ;)
<taw> oh, and exceptions
<mrvn> Why wuld you ever () that if?
<taw> if ocaml could infer what possible exception may be thrown by function
<taw> that would be wonderful
<taw> mrvn: that was typical c code
<mrvn> taw: yeah. Wished for that too. But only C++ does that.
<taw> "if (x = foo())" parses correct, but almost always is error, s/=/==/
<mrvn> taw: no, hardly ever.
<taw> in c
<taw> not ocaml here
<mellum> Heh, I also had a = versus == problem in ocaml once :)
<mrvn> if ((x = foo())) is very commong.
<taw> i heard something about exception inference for sml
<mrvn> in VC
<mrvn> -V
<taw> second () added for lint
<mrvn> gcc warns abou it too.
<taw> yeah
<mrvn> many people don#t do (())
<taw> they're asking for troubles
<taw> if (x=foo()) is quite rare
<taw> more often than not it's typo
* Riastradh puts parentheses -and- a '!= nil' (in Objective-C) there, always.
<mrvn> I allways do == NULL or != NULL or == 0 or == -1 or whatever in there. Its much easier to read and the compiler knows its the same.
<mellum> Riastradh: are you from apple, or why are you using ObjC? ;)
<Riastradh> mellum, I write apps/frameworks for OS X.
docelic is now known as docelic|away
Yurik_ has quit ["Client exiting"]
mattam_ has joined #ocaml
mattam has quit [Read error: 60 (Operation timed out)]
Yurik has joined #ocaml
<taw> hi Yurik
<Yurik> taw: hi
Yurik has quit ["Client exiting"]
docelic|away is now known as docelic
Yurik has joined #ocaml
cDlm has quit [Read error: 104 (Connection reset by peer)]
cDlm has joined #ocaml
mattam_ is now known as mattam
Smerdyakov has joined #ocaml
docelic is now known as docelic|away
cDlm_ has joined #ocaml
cDlm has quit [Read error: 104 (Connection reset by peer)]
cDlm_ is now known as cDlm
Smerdyakov has quit ["yeah well.. bye"]
mrvn_ has joined #ocaml
mrvn has quit [Read error: 110 (Connection timed out)]
docelic|away is now known as docelic
lament has joined #ocaml
taw has quit ["bye"]
cDlm_ has joined #ocaml
cDlm has quit ["Reconnecting"]
cDlm_ is now known as cDlm
lament is now known as lameAFK
lus|wazze has quit ["Weird Al Yankovic - Frank's 2000 Inch TV - 'cuz "everybody in the town can hear those 90,000 watts of dolby sound!""]
Kinners has joined #ocaml
cDlm_ has joined #ocaml
cDlm has quit [Read error: 54 (Connection reset by peer)]
cDlm_ is now known as cDlm
jao has joined #ocaml