Ahh ok, thank you that makes sense.
I didn't know about PLT_LINKLET_SHOW_CP0 before that is a nice look behind
the scene.
sorawe...@gmail.com schrieb am Sonntag, 21. März 2021 um 19:47:03 UTC+1:
> That’s not the job of the macro expander. And the Racket optimizer does
> reduce (if '#t (#%app n
That’s not the job of the macro expander. And the Racket optimizer does
reduce (if '#t (#%app not '#f) '#f) — in fact to #t.
If you use Racket CS, try running:
PLT_LINKLET_SHOW_CP0=1 racket file.rkt
where file.rkt is
#lang racket
(displayln (if #t (not #f) #f))
Here’s the optimized program:
;
The [WordCount] thread caused me to play around with the solutions to see
whether I could see anything else that can be tweaked, I tried a few things
but they didn't improve performance, but it was fun anyway.
Then I though I could try the macro stepper and look at the expansion of
[crowdsource
3 matches
Mail list logo