Awesome! Mine are at https://github.com/zzamboni/adventofcode/tree/master/2018 (I’m running a bit behind, still on Day 7)
BTW thanks for your writing - I’ve been reading through https://beautifulracket.com/, it’s a great book.
I don’t think we can stop anytime, but only when we have a term in normal form. At that point the nondeterminism kicks in and we can observe the difference between applicative order and call-by-value. For example, when we have ((Y (lambda (fact) ...)) 5)
we have to reduce, regardless of whether we are in applicative order or call-by-value. But when we have just the Y-combinator ((λ (f) ___)
), it is a normal form, so we have a choice. Call-by-value would stop here, but applicative order has the option to reduce inside the λ, spin around the loop once, land on another term in normal form, and face another nondeterministic decision of whether to stop or not.
You can use Pygments in LaTeX, and Pygments supports Racket.
I got an Ada Lovelace splash screen on startup today, I thought Ada Lovelace day was in October. Anyone know why it was displayed today?
@mark.warren today’s her birthday
Ah cool, should have checked for the obvious.
@samth I should Google first, ask silly question second :grin:
@alama, this is awesome. Thanks for putting it together. I thought you should know that the logo is pretty large and it took a while for the page to load because of it.
Does anyone know why I would get this error: no module instance found: #<resolved-module-path:"/home/leif/racket/racket/collects/racket/private/list.rkt"> 0
context...:
namespace->module-instance70
copy-namespace-value
temp250
for-loop
[repeats 1 more time]
perform-require!78
/home/leif/racket/racket/share/pkgs/compatibility-lib/mzscheme/private/old-procs.rkt:47:4: make-namespace
.../racket/unit.rkt:998:20
"/home/leif/racket/racket/share/pkgs/pict-lib/pict/code.rkt": [running body]
temp37_0
for-loop
run-module-instance!125
for-loop
[repeats 1 more time]
run-module-instance!125
do-dynamic-require5
...
Also, I have the following code: https://gist.github.com/LeifAndersen/2334bd0bd1cd91f5c34443a7bef2e3d5
When i run racket paper.scrbl
. But not when I run it in DrRacket?
What’s more interesting is when I remove the pict/code
line in lang.rkt
(line 10), racket paper.scrbl
runs fine.
This almost feels like a syntax-module system issue @mflatt, @ryanc, or @michael.ballantyne
(I also get the same error when I run raco make paper.scrbl
.
usually that means you require
d something at compile time that isn’t required by the residual program but is needed
My post on the users’ mailing list seemed to have been blocked by Google. It contains an external link to a screenshot. Anyway to get around that?
That’s odd.
I mean, I required the pict/code
library at read time.
But it doesn’t show up in the expanded code.
(When expanded in DrRacket that is.)
@shu—hung I allowed it
Thank you!
(Sorry I just sent it without the link again a few seconds ago)
@mflatt It looks like this is an expandera bug, as it works as expected in Racket 6.12.
I’m testing a repair
In case anyone is interested: A #lang
-triggered dynamic-require
is correctly wrapped with a parameterize
to change to a root namespace, if necessary. But the call to the read-syntax
function is outside that parameterize
, so there’s a mismatch between the namespace used to load and the namespace in place for read-syntax
. That mismatch easily shows up when the read-syntax
from the reader
language loads another module to get its reader.