Kyuuhachi/syn_derive

Cant build on stable

Closed this issue · 1 comments

vldm commented
 --> /_/.cargo/registry/src/github.com-1ecc6299db9ec823/syn_derive-0.1.5/src/lib.rs:1:12
  |
1 | #![feature(proc_macro_diagnostic)]

Hi, i want to use your crate, but found that currently it is depend on nightly compiller because it uses
proc_macro::Diagnostic.

Maybe it would be a good idea to rewrite error handling using proc-macro2-diagnostics - it allows you using Diagnostic in stable code, with few limitations.

Or if you just need panics with span you can use proc-macro-error.

If you think any of this idea is good, i can work on PR that.

Yeah, I mostly use nightly and sometimes forget that not everyone does. Sorry 'bout that.

Switched to proc-macro-error in v0.1.6 — kinda surprised that it needs String instead of nightly's &str, but otherwise a very straightforward change.