Open Flaise opened 9 years ago
How would you feel about the printer inserting a semicolon in cases like these?
It would be surprising behavior because r
and s
are separated by a newline but as long as it's valid Javascript it's good for my use case.
I'm using Recast for macro evaluation by replacing nodes of the AST with other sub-ASTs. I've found a situation where it doesn't generate valid Javascript:
Output:
It appears that Recast doesn't know what to do when the
loc
objects refer to different sources of input. I can make it work by doing this:Output:
But it would be nice if Recast knew what to do for this edge case.
Using: Node 4.1.1 recast 0.10.34