How to reinterpret `item` as stream of `tt` in declarative macro?

In declarative macro after interpreting steam of tt as item it holds as single tt if it is passed further to another macro.

In this example you can see token! printed twice. That is explained by hypotheses made above. If item consisted of multiple tt there would be much more token! on the screen.

Is that possible to cancel reinterpretation as item and get original stream of tt somehow?


No. Once a tt is interpreted as something else, you can't go back.


That's pity.

Thanks for supporting Ukraine!

1 Like

You may want to use defile - Rust - it allows you to un-group things like item back into its constituent tts.

1 Like

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.