#haskell - Fri 23 Feb 2007 between 00:00 and 00:08

NY Lost Funds



malsynedmonochrom: and the latter has the benefit of actually being useful in a real source file.
OK, it's settled. i'm totally doing that and not even feeling guilty.
SamBanyway, it gives better error messages than fromJust
monochromA large part of programming is about exploiting facts.
When I was a kid, I contemplated on "how paranoid should I be in my code?"
donsdoh, just missed emk
i like the quote on his latest blog entry, "Dont worry if you dont understand the details" :-)
should be our motto here.
monochromFor example, I had a chain of functions f, g, h, ... f passed its number parameter to g, g then passed the same number to h, ... They were all intended to just work for positive integers. Must I repeat the safeguard against non-positive integers at all stages?
beschmihttp://shim.haskellco.de/trac/shim/attachment/wiki/ScreenShots/vim-shim.png
lambdabotTitle: ScreenShots: vim-shim.png - shim - Trac, http://tinyurl.com/29r7ah
donsooh!
vim shim!!
beschmi++
beschmidons: it's just a quick hack for now ;)
donsthat's pretty sweet.
should i dive in then?
being a vim user
kscaldefdoes Double distinguish 0 and -0?
dibblego> 0::Double == -0::Double
lambdabotParse error
actionjcreigh ponders why the semantics of the x86 DIV instruction must be so convoluted...
jcreighponders why the semantics of the x86 DIV instruction must be so convoluted...
dons> 0 == ((-0) :: Double)
lambdabotTrue
kscaldef> 0.0 == -00
lambdabotTrue
dons?check \x -> let _=x :: Double in x == - (-x)
lambdabotOK, passed 500 tests.
donsi'm surprised that worked
kscaldefhmm... okay, that's not my bug
> 0.0 == -0.0
lambdabotTrue
nmessengerdons: that's an interesting way to annotation params without lhs annotations.
annotate*
jcreighDo doubles just have a sign bit?
monochromAfter joining the school-of-thought of proof-your-programs-correct, I feel no guilt in omitting all checks (except at the outermost interface facing malicious parties). I have written down in the specification that f,g,h expect positive integers, I have proved that all calls observe it, nothing to worry.
donsnmessenger: yeah :-) old QuickCheck trick
Pseudonymjcreigh: Because it was complicated 30 years ago.
dbremnermonochrom - then you might like this http://ftp.stratus.com/vos/doc/papers/RobustProgramming.ps
PseudonymThat's the reason for everything in the x86.

Page: 2 9 16 23 30 37 44 51 58 65 72 79 86 93 100 107 114 121 128 135 142 149 156 163 170 177 184 191 198 205 

IrcArchive

NY Lost Funds