Skip to content

How to generate a comment from macro argument #91

Answered by GoogleFeud
vekexasia asked this question in Q&A
Discussion options

You must be logged in to vote

Comments are always attached to a node, so you'll have to either:

  • Also provide a node to the macro, the macro will expand to the node and add the comment above
  • Create an empty statement and add the comment to it
  • Find the node above the macro call (harder than it sounds) and append a trailing comment to it

Playground

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by vekexasia
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants