Factor out parts of syntax templates

Are you familiar with define-syntax-class?

If you define a syntax class named helper, then you could use that to the right of a : in various patterns, e.g. stuff:helper. Then you can use stuff.x, where x is one of various attributes you supply from helper.

The syntax-parse intro has some examples.

3 Likes