dddddd has quit [Remote host closed the connection]
lf94 has quit [Ping timeout: 268 seconds]
lf94 has joined #racket
libertyprime has quit [Ping timeout: 250 seconds]
libertyprime has joined #racket
sauvin has joined #racket
libertyprime has quit [Ping timeout: 245 seconds]
<gonz_>
jcowan: To be honest, I think "the up-front cost of static typing" is mostly imagined, but having a debate about it here probably wouldn't be very fruitful.
orivej has joined #racket
libertyprime has joined #racket
<aeth>
depends on what you're trying to do
libertyprime has quit [Ping timeout: 246 seconds]
jao has joined #racket
jao has quit [Ping timeout: 250 seconds]
caltelt_ has quit [Ping timeout: 245 seconds]
<aeth>
there are also two kinds of static typing that are sometimes at odds: types for performance and types for reliability
Sgeo_ has quit [Read error: Connection reset by peer]
Sgeo_ has joined #racket
Sgeo_ has quit [Read error: Connection reset by peer]
Sgeo_ has joined #racket
jao has joined #racket
orivej has quit [Ping timeout: 246 seconds]
libertyprime has joined #racket
jao has quit [Ping timeout: 246 seconds]
emacsomancer has quit [Ping timeout: 244 seconds]
ZombieChicken has quit [Ping timeout: 256 seconds]
ZombieChicken has joined #racket
jao has joined #racket
jao has quit [Ping timeout: 245 seconds]
<jcowan>
aeth: I agree that there are two purposes, but can you explain how they are at odds?
<jcowan>
gonz_: As between Scala and Python, I know which one I'd rather write on the whiteboard during an interview.
<gonz_>
Why not APL?
<bremner>
assuming you actually want the job?
<gonz_>
I don't write Scala, but I can only assume that it's like Haskell in that you generally start off with the type signature, because it's a natural place to start
<gonz_>
And you're modeling with data anyway, which is better done with types
<gonz_>
If we're basing our language choices on what works on a whiteboard without any way to run the code, I'm sure Python fits the bill really well.
<gonz_>
But maybe it's not a great way to make language choices, even in contexts where you can be irresponsible.
YuGiOhJCJ has joined #racket
ZombieChicken has quit [Ping timeout: 256 seconds]
vraid has joined #racket
iyzsong has joined #racket
dddddd has joined #racket
emacsomancer has joined #racket
orivej has joined #racket
ng0 has joined #racket
peddie has quit [Ping timeout: 264 seconds]
jdormit[m] has quit [Ping timeout: 252 seconds]
clacke[m] has quit [Ping timeout: 250 seconds]
BitPuffin has quit [Ping timeout: 252 seconds]
colelyman has quit [Ping timeout: 252 seconds]
Sgeo_ has quit [Read error: Connection reset by peer]
<bremner>
(of course they are both quite silly functions)
<greghendershott>
bremner: Possibly your DrRacket Language settings are slower than the equivalent `racket-error-context` level in racket-mode.
<bremner>
maybe syntactic-test-suite coverage?
brendyyn has joined #racket
<greghendershott>
Maybe. Or even "preserve stack trace" or the "debugging ones".
<greghendershott>
All that stuff "instruments" your program, which can be slower. idk 400%, but slower.
<bremner>
"No debugging" is roughly competitive
<greghendershott>
i.e. It rewrites your program into a "better stack-trace-able" or "interactive debug-able" program. The rewrite can be pretty extensive.
<greghendershott>
That's why in racket-mode you can set `racket-error-contxt` to something like 'low or 'medium. And if you get an error with a weak location, you can C-u C-c C-c to run with 'high.
<greghendershott>
i.e. default to low, and conveniently crank it up for just one run, if/as needed
<greghendershott>
That might be a neat thing to have in DrR, too, idk
<greghendershott>
Maybe some keystroke in DrR could pop up that lang settings dialog, and you can change any of them temporarily, and when you click OK it Runs.
<greghendershott>
That would make it even more flexible in that regard than racket-mode
<bremner>
are you thinking of exposing new knobs, or just making it more convenient to twak them?
<bremner>
s/twak/tweak.
<bremner>
(also, thanks for the explanation, I think I understand the difference now)
<dzoe>
I encountered strange behaviour with srcdoc.
<dzoe>
If I (define something empty) and export it via (provide something), I can modify it later on and it works as expected (some list gets filled there after setting things up).
<dzoe>
But if I (provide (thing-doc something ...)), I can only see '() if I refer to that something in modules that (require) this one.
<dzoe>
How can I do something like thing-doc but without basically exporting constatnt compile-time value in there?
<dzoe>
(Didn't look into the transforms (thing-doc) actually does, but I suspect it does some renaming behind the scenes)
sleepnap has joined #racket
jao has joined #racket
iyzsong has quit [Ping timeout: 258 seconds]
brendyyn has quit [Read error: Connection reset by peer]
brendyyn has joined #racket
endformationage has joined #racket
Boarders has joined #racket
<Boarders>
I asked this yesterday but had to leave, in dr-racket does anyone know the key command to get the previously entered thing in the interpreter?
<lavaflow>
up arrow maybe? dunno
<vraid>
ctrl-up?
dan_f has joined #racket
ym555 has quit [Ping timeout: 264 seconds]
<Boarders>
vraid: that does it, thanks so mcuh
ym555_ has joined #racket
<Boarders>
much*
<vraid>
yw
ym555_ has quit [Ping timeout: 252 seconds]
tilpner has quit [Quit: WeeChat 2.4]
tilpner has joined #racket
<aeth>
jcowan: Types for performance and types for reliability are at odds in the sense that sometimes reliability hurts runtime performance. I guess the other way works, too, if you have the compiler assume without checking that foo is type uint32_t.
<jcowan>
Oh, yes, I see; it's not specific to types. "If it doesn't need to work I can make it go as fast as you want."
dan_f has quit [Quit: dan_f]
vraid has quit [Quit: Leaving]
dan_f has joined #racket
Boarders has left #racket [#racket]
ym555_ has joined #racket
jao has quit [Ping timeout: 264 seconds]
vraid has joined #racket
fanta7531 has joined #racket
dan_f has quit [Quit: dan_f]
<greghendershott>
jcowan: There exist applications (or portions thereof) where, "If it doesn't work fast enough, I don't need to make it correct because no one will use it". No?
dan_f has joined #racket
<greghendershott>
Also, I think it's reasonable to remove a contract from a function in a hot loop, if you're satisfied it is correct, and/or protected by contracts in a bigger context.
<greghendershott>
We could debate what "satisfied" needs to mean, for different people and project requirements.
<greghendershott>
I just don't think it's hard rule that all functions must have contracts. If that's what you were saying. But maybe you weren't.
<greghendershott>
Also, although contracts on a function can check its return value(s), it is not uncommon for people not to do that (use `any`) for performance reasons.
<greghendershott>
Is that always wrong?
<jcowan>
I'm saying that if you need a contract in a certain place, because you cannot prove it will not fail, then you need it there in production too.
<jcowan>
That's what I started with the "life jackets in port / at sea" metaphor.
<jcowan>
Nobody has ever made a Scheme runtime (that I know of) that just goes off the rails on a type error like (car x) where x => 32.
<jcowan>
(Of course that's a trivial case of a contract.)
pera has joined #racket
<technomancy>
there are many cases where you can apply contracts at only the edge of a system during production, because you have gained confidence during development (when the code is frequently charging) that correct inputs result in correct internal data.
dan_f has quit [Quit: dan_f]
dan_f has joined #racket
ym555_ has quit [Ping timeout: 250 seconds]
ym555_ has joined #racket
dan_f has quit [Quit: dan_f]
ubLIX has joined #racket
pera has quit [Ping timeout: 252 seconds]
dan_f has joined #racket
pera has joined #racket
FreeFull has joined #racket
Boarders has joined #racket
<Boarders>
does anyone know in dr racket how I minimise the interactions window?
<bremner>
Ctrl-E toggles it
<Boarders>
thanks!
<Boarders>
do you know a good resource where I can look up this sort of thing?