1 | [package] |
2 | name = "derive_more" |
3 | version = "0.99.17" |
4 | description = "Adds #[derive(x)] macros for more traits" |
5 | authors = ["Jelte Fennema <github-tech@jeltef.nl>" ] |
6 | license = "MIT" |
7 | repository = "https://github.com/JelteF/derive_more" |
8 | documentation = "https://jeltef.github.io/derive_more/derive_more/" |
9 | edition = "2018" |
10 | |
11 | readme = "README.md" |
12 | keywords = ["derive" , "Add" , "From" , "Display" , "IntoIterator" ] |
13 | categories = ["development-tools" , "development-tools::procedural-macro-helpers" , "no-std" ] |
14 | |
15 | include = [ |
16 | "src/**/*.rs" , |
17 | "Cargo.toml" , |
18 | "LICENSE" , |
19 | "README.md" , |
20 | "CHANGELOG.md" , |
21 | "tests/**/*.rs" , # debian packaging wants this |
22 | ] |
23 | autotests = true |
24 | |
25 | [lib] |
26 | name = "derive_more" |
27 | proc-macro = true |
28 | |
29 | [dependencies] |
30 | proc-macro2 = "1.0" |
31 | quote = "1.0" |
32 | syn = "1.0.3" |
33 | convert_case = { version = "0.4" , optional = true} |
34 | |
35 | [build-dependencies] |
36 | peg = { version = "0.5" , optional = true } |
37 | rustc_version = { version = "0.4" , optional = true } |
38 | |
39 | [badges] |
40 | github = { repository = "JelteF/derive_more" , workflow = "CI" } |
41 | |
42 | [features] |
43 | nightly = [] |
44 | add_assign = [] |
45 | add = [] |
46 | as_mut = [] |
47 | as_ref = [] |
48 | constructor = [] |
49 | deref = [] |
50 | deref_mut = [] |
51 | display = ["syn/extra-traits" ] |
52 | error = ["syn/extra-traits" ] |
53 | from = ["syn/extra-traits" ] |
54 | from_str = [] |
55 | index = [] |
56 | index_mut = [] |
57 | into = ["syn/extra-traits" ] |
58 | into_iterator = [] |
59 | iterator = [] |
60 | mul_assign = ["syn/extra-traits" ] |
61 | mul = ["syn/extra-traits" ] |
62 | not = ["syn/extra-traits" ] |
63 | sum = [] |
64 | try_into = ["syn/extra-traits" ] |
65 | generate-parsing-rs = ["peg" ] |
66 | testing-helpers = ["rustc_version" ] |
67 | is_variant = ["convert_case" ] |
68 | unwrap = ["convert_case" , "rustc_version" ] |
69 | # Feature that requires post-MSRV Rust version, |
70 | # of 1.46. We perform rustc version detection in the |
71 | # build script for features that require this. |
72 | # (Currently just `unwrap`.) |
73 | track-caller = [] |
74 | |
75 | default = [ |
76 | "add_assign" , |
77 | "add" , |
78 | "as_mut" , |
79 | "as_ref" , |
80 | "constructor" , |
81 | "deref" , |
82 | "deref_mut" , |
83 | "display" , |
84 | "error" , |
85 | "from" , |
86 | "from_str" , |
87 | "index" , |
88 | "index_mut" , |
89 | "into" , |
90 | "into_iterator" , |
91 | "iterator" , |
92 | "mul_assign" , |
93 | "mul" , |
94 | "not" , |
95 | "sum" , |
96 | "try_into" , |
97 | "is_variant" , |
98 | "unwrap" |
99 | ] |
100 | |
101 | [[test]] |
102 | name = "add_assign" |
103 | path = "tests/add_assign.rs" |
104 | required-features = ["add_assign" ] |
105 | |
106 | [[test]] |
107 | name = "add" |
108 | path = "tests/add.rs" |
109 | required-features = ["add" ] |
110 | |
111 | [[test]] |
112 | name = "as_mut" |
113 | path = "tests/as_mut.rs" |
114 | required-features = ["as_mut" ] |
115 | |
116 | [[test]] |
117 | name = "as_ref" |
118 | path = "tests/as_ref.rs" |
119 | required-features = ["as_ref" ] |
120 | |
121 | [[test]] |
122 | name = "boats_display_derive" |
123 | path = "tests/boats_display_derive.rs" |
124 | required-features = ["display" ] |
125 | |
126 | [[test]] |
127 | name = "constructor" |
128 | path = "tests/constructor.rs" |
129 | required-features = ["constructor" ] |
130 | |
131 | [[test]] |
132 | name = "deref" |
133 | path = "tests/deref.rs" |
134 | required-features = ["deref" ] |
135 | |
136 | [[test]] |
137 | name = "deref_mut" |
138 | path = "tests/deref_mut.rs" |
139 | required-features = ["deref_mut" ] |
140 | |
141 | [[test]] |
142 | name = "display" |
143 | path = "tests/display.rs" |
144 | required-features = ["display" ] |
145 | |
146 | [[test]] |
147 | name = "error" |
148 | path = "tests/error_tests.rs" |
149 | required-features = ["error" ] |
150 | |
151 | [[test]] |
152 | name = "from" |
153 | path = "tests/from.rs" |
154 | required-features = ["from" ] |
155 | |
156 | [[test]] |
157 | name = "from_str" |
158 | path = "tests/from_str.rs" |
159 | required-features = ["from_str" ] |
160 | |
161 | [[test]] |
162 | name = "index_mut" |
163 | path = "tests/index_mut.rs" |
164 | required-features = ["index_mut" ] |
165 | |
166 | [[test]] |
167 | name = "index" |
168 | path = "tests/index.rs" |
169 | required-features = ["index" ] |
170 | |
171 | [[test]] |
172 | name = "into" |
173 | path = "tests/into.rs" |
174 | required-features = ["into" ] |
175 | |
176 | [[test]] |
177 | name = "into_iterator" |
178 | path = "tests/into_iterator.rs" |
179 | required-features = ["into_iterator" ] |
180 | |
181 | [[test]] |
182 | name = "mul_assign" |
183 | path = "tests/mul_assign.rs" |
184 | required-features = ["mul_assign" ] |
185 | |
186 | [[test]] |
187 | name = "mul" |
188 | path = "tests/mul.rs" |
189 | required-features = ["mul" ] |
190 | |
191 | [[test]] |
192 | name = "not" |
193 | path = "tests/not.rs" |
194 | required-features = ["not" ] |
195 | |
196 | [[test]] |
197 | name = "sum" |
198 | path = "tests/sum.rs" |
199 | required-features = ["sum" ] |
200 | |
201 | [[test]] |
202 | name = "try_into" |
203 | path = "tests/try_into.rs" |
204 | required-features = ["try_into" ] |
205 | |
206 | [[test]] |
207 | name = "is_variant" |
208 | path = "tests/is_variant.rs" |
209 | required-features = ["is_variant" ] |
210 | |
211 | [[test]] |
212 | name = "unwrap" |
213 | path = "tests/unwrap.rs" |
214 | required-features = ["unwrap" ] |
215 | |
216 | [[test]] |
217 | name = "no_std" |
218 | path = "tests/no_std.rs" |
219 | required-features = [ |
220 | "add_assign" , |
221 | "add" , |
222 | "as_mut" , |
223 | "as_ref" , |
224 | "constructor" , |
225 | "deref" , |
226 | "deref_mut" , |
227 | "display" , |
228 | "from" , |
229 | "from_str" , |
230 | "index" , |
231 | "index_mut" , |
232 | "into" , |
233 | "mul_assign" , |
234 | "mul" , |
235 | "not" , |
236 | "sum" , |
237 | "try_into" , |
238 | "is_variant" , |
239 | ] |
240 | |
241 | [[test]] |
242 | name = "generics" |
243 | path = "tests/generics.rs" |
244 | required-features = [ |
245 | "add_assign" , |
246 | "add" , |
247 | "as_mut" , |
248 | "as_ref" , |
249 | "constructor" , |
250 | "deref" , |
251 | "deref_mut" , |
252 | "display" , |
253 | "from" , |
254 | "from_str" , |
255 | "index" , |
256 | "index_mut" , |
257 | "into" , |
258 | "mul_assign" , |
259 | "mul" , |
260 | "not" , |
261 | "try_into" , |
262 | "is_variant" , |
263 | ] |
264 | |
265 | [[test]] |
266 | name = "lib" |
267 | path = "tests/lib.rs" |
268 | required-features = [ |
269 | "add_assign" , |
270 | "add" , |
271 | "as_mut" , |
272 | "as_ref" , |
273 | "constructor" , |
274 | "deref" , |
275 | "deref_mut" , |
276 | "display" , |
277 | "from" , |
278 | "from_str" , |
279 | "index" , |
280 | "index_mut" , |
281 | "into" , |
282 | "mul_assign" , |
283 | "mul" , |
284 | "not" , |
285 | "try_into" , |
286 | "is_variant" , |
287 | ] |
288 | |
289 | [[example]] |
290 | name = "deny_missing_docs" |
291 | path = "examples/deny_missing_docs.rs" |
292 | required-features = [ |
293 | "add_assign" , |
294 | "add" , |
295 | "as_mut" , |
296 | "as_ref" , |
297 | "constructor" , |
298 | "deref" , |
299 | "deref_mut" , |
300 | "display" , |
301 | "from" , |
302 | "from_str" , |
303 | "index" , |
304 | "index_mut" , |
305 | "into" , |
306 | "mul_assign" , |
307 | "mul" , |
308 | "not" , |
309 | "try_into" , |
310 | "is_variant" , |
311 | ] |
312 | |