You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
That's strange, I wonder if that's actually better than Option! It's more ergonomic, but it feels like it would have the same problems as something like null.
I've not used it just looked at the code[1], but it gets represented as something like <unspecifed>:0:0. In syn`, one of the things spans gets used for is things like macro expansion, and saying where textually names are resolved, so it isn't entirely about tracking position information, so the tradeoffs might be different there.
That said, if you are doing code transforms, it might be useful to have a way to track in the ast whether a token came from user code, or was synthesized by the tool.
[1] I've only looked at the code when not being used as a proc-macro (i.e. the fallback code in proc-macro2), so the representation in the compile might be different.
It feels really unergonomic to be unwrapping every single call.
The text was updated successfully, but these errors were encountered: