yefo.akira
2017-12-1 10:12:36

Aaaah, found the -M switch. Found even the -h switch that now seems stupid I didn’t think about it yesterday. Probably that should be in the tutorial.


apg
2017-12-1 19:34:58

that reminds me, @ben any update on my PR (https://github.com/racket/slideshow/pull/11)


ben
2017-12-1 19:38:26

It still looks good to me, lets merge it


ben
2017-12-1 19:38:51

do you want to squash any of the commits?


leif
2017-12-1 20:19:24

Is there any good way to learn about the mechanics of for-label or the label phase in general? Namely, I’m wondering what scribble actually gets out of using the macro expander to build hyperlinks.


leif
2017-12-1 20:19:40

(As opposed to just using the bindings at, say, phase 0.)


slack1
2017-12-1 20:35:15

Does anyone jot down their thoughts in a Jupyter-like notebook solution?


notjack
2017-12-1 20:42:57

@leif I think scribble’s use of the label phase was because submodules didn’t exist yet, and if they did scribble would have used them instead


leif
2017-12-1 21:01:46

@notjack That was @michael.ballantyne and I first thought. But there seems to be some major differences here.


leif
2017-12-1 21:02:01

Like, 1. phases allow for an interleaved execution that submodules just don’t.


leif
2017-12-1 21:02:52

And 2. It seems like the label phase is the only way in Racket to declare a module (and possibly visit it) while getting the bindings statically without instantiating it.


leif
2017-12-1 21:59:50

Also, this combination of features confuses me: https://gist.github.com/LeifAndersen/0fe797a827db037a39a5574d1e90ada9


leif
2017-12-1 21:59:52

leif
2017-12-1 22:00:16

Like, why on earth does begin-for-syntax blocks get top-level like semantics. :disappointed:


leif
2017-12-1 22:00:19

(Thanks to @michael.ballantyne for finding it.)


mflatt
2017-12-1 22:28:05

@leif While a begin-for-syntax form is being expanded at phase N, there will be no expansion of forms at level N–1, so there’s no need to run code at phase N; it can be compiled as a group. As soon as you go back to expanding at level N–1 after a begin-for-syntax, expansion may involve macros that run at phase N, so the begin-for-syntaxed code needs to have been run. That explains why the use of g in the last example can’t be a macro use. At the time time, you’d really like for mutually recursive define-for-syntaxed functions to work, and that’s why the second example compiles: the expanded/run begin-for-syntax assumes that not-yet-bound identifiers refer to values.


mflatt
2017-12-1 22:30:59

It’s true that for-label imports binding without setting up an invocation/visit dependency. I don’t know whether submodules could achieve the same goal, but I think probably an extra ingredient of some sort is needed – and for-label (which I think of as phase +∞) might be as simple as any other extra ingredient.


wander4096
2017-12-1 22:44:19

@wander4096 has joined the channel


leif
2017-12-1 23:07:32

@mflatt That makes sense, thanks.


ben
2017-12-2 02:51:39

ping @apg do you mind if I squash & merge, or do you want to keep the commits separate?


apg
2017-12-2 02:57:00

Whatever you typically do is totally fine by me.