@@ -83,9 +83,10 @@ pub fn profiled(meta: TokenStream, input: TokenStream) -> TokenStream {
83
83
84
84
/// Makes it possible to use a type as a NativeScript.
85
85
///
86
- /// ## Required attributes
86
+ /// ## Type attributes
87
87
///
88
- /// The following attributes are required on the type deriving `NativeClass`:
88
+ /// The behavior of the derive macro can be customized using attributes on the type
89
+ /// deriving `NativeClass`. All type attributes are optional.
89
90
///
90
91
/// ### `#[inherit(gdnative::api::BaseClass)]`
91
92
///
@@ -97,9 +98,10 @@ pub fn profiled(meta: TokenStream, input: TokenStream) -> TokenStream {
97
98
/// Inheritance from other scripts, either in Rust or other languages, is
98
99
/// not supported.
99
100
///
100
- /// ## Optional type attributes
101
+ /// If no `#[inherit(...)]` is provided, [`gdnative::api::Reference`](../gdnative/api/struct.Reference.html)
102
+ /// is used as a base class. This behavior is consistent with GDScript: omitting the
103
+ /// `extends` keyword will inherit `Reference`.
101
104
///
102
- /// Behavior of the derive macro can be customized using attribute on the type:
103
105
///
104
106
/// ### `#[user_data(gdnative::user_data::SomeWrapper<Self>)]`
105
107
///
@@ -134,7 +136,10 @@ pub fn profiled(meta: TokenStream, input: TokenStream) -> TokenStream {
134
136
///
135
137
/// See documentation on `Instance::emplace` for an example on how this can be used.
136
138
///
137
- /// ## Optional field attributes
139
+ ///
140
+ /// ## Field attributes
141
+ ///
142
+ /// All field attributes are optional.
138
143
///
139
144
/// ### `#[property]`
140
145
///
0 commit comments