Kampfkarren / full-moon

A lossless Lua 5.1 parser
Mozilla Public License 2.0
382 stars 50 forks source link

Can't store references to nodes in visitor #206

Open tommaisey opened 2 years ago

tommaisey commented 2 years ago

Hi, I'm trying to do some analysis/searching of Lua code with full_moon and I find I can't easily store references to nodes in a Visitor. I was looking at the syn crate and they have annotated their Visitor trait with the lifetime of the AST, meaning that this is allowed. Is it something you'd consider for full_moon?

Kampfkarren commented 2 years ago

Possibly! I'm okay with this at first glance.