We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0c11db8 commit fc096f1Copy full SHA for fc096f1
src/2018/transitioning/modules/macros.md
@@ -44,7 +44,11 @@ This moves `macro_rules` macros to be a bit closer to other kinds of items.
44
45
## Procedural macros
46
47
-When using procedural macros to derive traits, you could have written:
+When using procedural macros to derive traits, you will have to name the macro
48
+that provides the custom derive. This generally matches the name of the trait,
49
+but check with the documentation of the crate providing the derives to be sure.
50
+
51
+For example, with Serde you would have written
52
53
```rust,ignore
54
// Rust 2015
@@ -66,8 +70,6 @@ use serde_derive::{Serialize, Deserialize};
66
70
struct Bar;
67
71
```
68
72
69
-Note that the macros you have to import have the same name as the traits you want to derive.
-
73
74
## More details
75
0 commit comments