1 | [package] |
2 | name = "derive_utils" |
3 | version = "0.14.1" #publish:version |
4 | edition = "2021" |
5 | rust-version = "1.56" |
6 | license = "Apache-2.0 OR MIT" |
7 | repository = "https://github.com/taiki-e/derive_utils" |
8 | keywords = ["enum" , "macros" , "derive" ] |
9 | categories = ["development-tools::procedural-macro-helpers" , "rust-patterns" ] |
10 | exclude = ["/.*" , "/tools" ] |
11 | description = "" " |
12 | A procedural macro helper for easily writing derive macros for enums. |
13 | " "" |
14 | |
15 | [package.metadata.docs.rs] |
16 | targets = ["x86_64-unknown-linux-gnu" ] |
17 | |
18 | [package.metadata.cargo_check_external_types] |
19 | # The following are external types that are allowed to be exposed in our public API. |
20 | allowed_external_types = [ |
21 | "proc_macro2::*" , |
22 | "quote::*" , |
23 | "syn::*" , |
24 | ] |
25 | |
26 | [lib] |
27 | doc-scrape-examples = false |
28 | |
29 | # Note: proc-macro2, quote, and syn are public dependencies. |
30 | [dependencies] |
31 | proc-macro2 = "1.0.60" |
32 | quote = "1.0.25" |
33 | syn = { version = "2" , features = ["full" ] } |
34 | |
35 | [dev-dependencies] |
36 | example_derive = { path = "examples/example_derive" } |
37 | rustversion = "1" |
38 | trybuild = { git = "https://github.com/taiki-e/trybuild.git" , branch = "dev" } # adjust overwrite behavior |
39 | |
40 | [lints] |
41 | workspace = true |
42 | |
43 | [workspace] |
44 | resolver = "2" |
45 | members = ["examples/example" , "examples/example_derive" ] |
46 | |
47 | # This table is shared by projects under https://github.com/taiki-e. |
48 | # It is not intended for manual editing. |
49 | [workspace.lints.rust] |
50 | improper_ctypes = "warn" |
51 | improper_ctypes_definitions = "warn" |
52 | missing_debug_implementations = "warn" |
53 | non_ascii_idents = "warn" |
54 | rust_2018_idioms = "warn" |
55 | single_use_lifetimes = "warn" |
56 | unreachable_pub = "warn" |
57 | # unsafe_op_in_unsafe_fn = "warn" # Set at crate-level instead since https://github.com/rust-lang/rust/pull/100081 is not available on MSRV |
58 | [workspace.lints.clippy] |
59 | all = "warn" # Downgrade deny-by-default lints |
60 | pedantic = "warn" |
61 | as_ptr_cast_mut = "warn" |
62 | default_union_representation = "warn" |
63 | inline_asm_x86_att_syntax = "warn" |
64 | trailing_empty_array = "warn" |
65 | transmute_undefined_repr = "warn" |
66 | undocumented_unsafe_blocks = "warn" |
67 | # Suppress buggy or noisy clippy lints |
68 | bool_assert_comparison = { level = "allow" , priority = 1 } |
69 | borrow_as_ptr = { level = "allow" , priority = 1 } # https://github.com/rust-lang/rust-clippy/issues/8286 |
70 | doc_markdown = { level = "allow" , priority = 1 } |
71 | float_cmp = { level = "allow" , priority = 1 } # https://github.com/rust-lang/rust-clippy/issues/7725 |
72 | manual_assert = { level = "allow" , priority = 1 } |
73 | manual_range_contains = { level = "allow" , priority = 1 } # https://github.com/rust-lang/rust-clippy/issues/6455#issuecomment-1225966395 |
74 | missing_errors_doc = { level = "allow" , priority = 1 } |
75 | module_name_repetitions = { level = "allow" , priority = 1 } |
76 | similar_names = { level = "allow" , priority = 1 } |
77 | single_match = { level = "allow" , priority = 1 } |
78 | single_match_else = { level = "allow" , priority = 1 } |
79 | struct_excessive_bools = { level = "allow" , priority = 1 } |
80 | struct_field_names = { level = "allow" , priority = 1 } |
81 | too_many_arguments = { level = "allow" , priority = 1 } |
82 | too_many_lines = { level = "allow" , priority = 1 } |
83 | type_complexity = { level = "allow" , priority = 1 } |
84 | |