proc-macro-error 0.4.12

Almost drop-in replacement to panics in proc-macros
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
error[E0599]: no method named `FIRST_ARG_MUST_EITHER_BE_SPAN_OR_IMPLEMENT_TO_TOKENS` found for reference `&Foo` in the current scope
 --> $DIR/misuse.rs:8:5
  |
8 |     abort!(Foo, "BOOM");
  |     ^^^^^^^^^^^^^^^^^^^^ method not found in `&Foo`
  |
  = note: the method `FIRST_ARG_MUST_EITHER_BE_SPAN_OR_IMPLEMENT_TO_TOKENS` exists but the following trait bounds were not satisfied:
          `&Foo : proc_macro_error::__export::DoubleSpanToTokens`
  = help: items from traits can only be used if the trait is implemented and in scope
  = note: the following traits define an item `FIRST_ARG_MUST_EITHER_BE_SPAN_OR_IMPLEMENT_TO_TOKENS`, perhaps you need to implement one of them:
          candidate #1: `proc_macro_error::__export::DoubleSpanToTokens`
          candidate #2: `proc_macro_error::__export::DoubleSpanSingleSpan2`
          candidate #3: `proc_macro_error::__export::DoubleSpanSingleSpan`
  = note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info)