Upgrade to syn-0.14/quote-0.6#8
Conversation
|
Thank you for creating this crate! It's been exactly what I needed for this (proprietary) project I'm working on. Hope this PR helps -- if you could do a release after merging, that would be swell too. |
|
I've been wanting to upgrade for awhile, thanks! I'm not if you're familiar enough with the new syn/proc-macro2 infrastructure to know if follow-up work to improve error messages is doable/worthwhile? Do you expect that from just the upgrade, or is this mostly to reduce compile times? |
|
This has been released as 0.1.2. |
|
I've done upgrades in a bunch of projects. What kind of error message improvements were you looking for? Do you mean getting actual nice rustc errors for your generated source code? As far as I know, that is not yet supported by the current macro implementations. |
|
So I think I'm referring to this Spans and Error Reporting. Like I said, I haven't actually looked into it at all, I just have a vague recollection that it's a thing. |
|
I pretty much only use stable, and the more advanced error reporting definitely doesn't work there yet. The documentation does seem to imply that you can do much better with nightly... |
|
Yeah, that makes sense. I also don't think that this specific code needs much better error messages, it's specifically for a pretty trivial case -- mostly I was just curious. However, I am curious if the recent proc-macro stabilization includes this proc-macro2 api, meaning that everyone will be able to take advantage of it soon. This comment kind of suggests that everything is moving fast, which would be amazing. |
|
Yup, 1.30 should come with a whole bunch of goodies, though in my (limited) understanding that's less about better error messages and more about allowing procedural macros in more places (not just structs and enums) and allowing the macro to rewrite the original code rather than just augmenting it. |
|
yeah, I'm pumped. Thanks! |
No description provided.