Fork me!
This is a demonstration of a pure-rust library to generate syntax diagrams for macro_rules!().

Diagrams are generated fully automatically from rust-source as Scalable Vector Graphics, using customizable CSS for layout.

Paste a macro_rules!()-block into the text-area on the left; modify them as you wish. A wasm-blob will generate a syntax-diagram as an SVG in the area below.
If you found a bug, a quirk or a macro that doesn't parse but should, please report it liberally.

Here are some examples:
As an exercise: Load the verify!()-example; ensure that the layout-optimization is enabled; in the last pattern, change the name from `submac` to `submac2` and `args` to `args2`; notice the new layout.