2018-12-02 22:27:37 +03:00
|
|
|
error: `proc-macro` crate types cannot export any items other than functions tagged with `#[proc_macro_derive]` currently
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/pub-at-crate-root.rs:8:1
|
2018-12-02 22:27:37 +03:00
|
|
|
|
|
2019-03-09 15:03:44 +03:00
|
|
|
LL | / pub mod a {
|
2018-12-02 22:27:37 +03:00
|
|
|
LL | | use proc_macro::TokenStream;
|
|
|
|
LL | |
|
|
|
|
LL | | #[proc_macro_derive(B)]
|
|
|
|
... |
|
|
|
|
LL | | }
|
|
|
|
LL | | }
|
|
|
|
| |_^
|
|
|
|
|
|
|
|
error: functions tagged with `#[proc_macro_derive]` must currently reside in the root of the crate
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/pub-at-crate-root.rs:12:5
|
2018-12-02 22:27:37 +03:00
|
|
|
|
|
|
|
|
LL | / pub fn bar(a: TokenStream) -> TokenStream {
|
2019-03-09 15:03:44 +03:00
|
|
|
LL | |
|
2018-12-02 22:27:37 +03:00
|
|
|
LL | | a
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: functions tagged with `#[proc_macro_derive]` must be `pub`
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/pub-at-crate-root.rs:19:1
|
2018-12-02 22:27:37 +03:00
|
|
|
|
|
|
|
|
LL | / fn bar(a: proc_macro::TokenStream) -> proc_macro::TokenStream {
|
2019-03-09 15:03:44 +03:00
|
|
|
LL | |
|
2018-12-02 22:27:37 +03:00
|
|
|
LL | | a
|
|
|
|
LL | | }
|
|
|
|
| |_^
|
|
|
|
|
|
|
|
error: aborting due to 3 previous errors
|
|
|
|
|