Cargo.toml 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. [workspace]
  2. members = ["lib", "macros", "tools/uniffi-bindgen"]
  3. default-members = ["lib", "macros"]
  4. resolver = "2"
  5. [profile.release]
  6. lto = true
  7. [patch.crates-io]
  8. blake2 = { path = "patches/blake2" }
  9. # Commented lints are currently unstable and we want to try them ASAP.
  10. [workspace.lints.rust]
  11. deprecated_safe = "warn"
  12. explicit_outlives_requirements = "warn"
  13. #fuzzy_provenance_casts = "warn"
  14. #impl_trait_overcaptures = "warn"
  15. #lossy_provenance_casts = "warn"
  16. macro_use_extern_crate = "warn"
  17. meta_variable_misuse = "warn"
  18. missing_abi = "warn"
  19. missing_docs = "warn"
  20. missing_unsafe_on_extern = "warn"
  21. #multiple_supertrait_upcastable = "warn"
  22. #must_not_suspend = "warn"
  23. non_ascii_idents = "warn"
  24. #non_exhaustive_omitted_patterns = "warn"
  25. non_local_definitions = "warn"
  26. redundant_lifetimes = "warn"
  27. single_use_lifetimes = "warn"
  28. unit_bindings = "warn"
  29. unnameable_types = "warn"
  30. unreachable_pub = "warn"
  31. unsafe_op_in_unsafe_fn = "warn"
  32. unstable_features = "warn"
  33. unused_crate_dependencies = "warn"
  34. unused_extern_crates = "warn"
  35. unused_macro_rules = "warn"
  36. unused_qualifications = "warn"
  37. unused_results = "warn"
  38. [workspace.lints.rustdoc]
  39. missing_crate_level_docs = "warn"
  40. private_doc_tests = "warn"
  41. unescaped_backticks = "warn"
  42. # Commented lints are in a newer Clippy version or tied to unstable and we want
  43. # to try them ASAP.
  44. #
  45. # The following groups are enabled by default:
  46. #
  47. # - Correctness
  48. # - Suspicious
  49. # - Style
  50. # - Complexity
  51. # - Perf
  52. [workspace.lints.clippy]
  53. # Pedantic
  54. pedantic = "warn"
  55. similar_names = { level = "allow", priority = 1 }
  56. too_many_lines = { level = "allow", priority = 1 }
  57. # Restriction
  58. alloc_instead_of_core = { level = "warn", priority = 1 }
  59. allow_attributes = { level = "warn", priority = 1 }
  60. allow_attributes_without_reason = { level = "warn", priority = 1 }
  61. arithmetic_side_effects = { level = "warn", priority = 1 }
  62. as_pointer_underscore = { level = "warn", priority = 1 }
  63. as_underscore = { level = "warn", priority = 1 }
  64. big_endian_bytes = { level = "warn", priority = 1 }
  65. create_dir = { level = "warn", priority = 1 }
  66. cfg_not_test = { level = "warn", priority = 1 }
  67. dbg_macro = { level = "warn", priority = 1 }
  68. default_numeric_fallback = { level = "warn", priority = 1 }
  69. deref_by_slicing = { level = "warn", priority = 1 }
  70. doc_include_without_cfg = { level = "warn", priority = 1 }
  71. empty_drop = { level = "warn", priority = 1 }
  72. empty_enum_variants_with_brackets = { level = "warn", priority = 1 }
  73. empty_structs_with_brackets = { level = "warn", priority = 1 }
  74. error_impl_error = { level = "warn", priority = 1 }
  75. exit = { level = "warn", priority = 1 }
  76. filetype_is_file = { level = "warn", priority = 1 }
  77. float_arithmetic = { level = "warn", priority = 1 }
  78. float_cmp_const = { level = "warn", priority = 1 }
  79. fn_to_numeric_cast_any = { level = "warn", priority = 1 }
  80. format_push_string = { level = "warn", priority = 1 }
  81. host_endian_bytes = { level = "warn", priority = 1 }
  82. impl_trait_in_params = { level = "warn", priority = 1 }
  83. indexing_slicing = { level = "warn", priority = 1 }
  84. infinite_loop = { level = "warn", priority = 1 }
  85. integer_division = { level = "warn", priority = 1 }
  86. integer_division_remainder_used = { level = "warn", priority = 1 }
  87. lossy_float_literal = { level = "warn", priority = 1 }
  88. map_with_unused_argument_over_ranges = { level = "warn", priority = 1 }
  89. min_ident_chars = { level = "warn", priority = 1 }
  90. missing_assert_message = { level = "warn", priority = 1 }
  91. mixed_read_write_in_expression = { level = "warn", priority = 1 }
  92. module_name_repetitions = { level = "allow", priority = 1 }
  93. multiple_inherent_impl = { level = "warn", priority = 1 }
  94. multiple_unsafe_ops_per_block = { level = "warn", priority = 1 }
  95. mutex_atomic = { level = "warn", priority = 1 }
  96. needless_raw_strings = { level = "warn", priority = 1 }
  97. non_zero_suggestions = { level = "warn", priority = 1 }
  98. panic = { level = "warn", priority = 1 }
  99. partial_pub_fields = { level = "warn", priority = 1 }
  100. pathbuf_init_then_push = { level = "warn", priority = 1 }
  101. print_stderr = { level = "warn", priority = 1 }
  102. print_stdout = { level = "warn", priority = 1 }
  103. pub_without_shorthand = { level = "warn", priority = 1 }
  104. rc_buffer = { level = "warn", priority = 1 }
  105. rc_mutex = { level = "warn", priority = 1 }
  106. redundant_type_annotations = { level = "warn", priority = 1 }
  107. ref_patterns = { level = "warn", priority = 1 }
  108. renamed_function_params = { level = "warn", priority = 1 }
  109. rest_pat_in_fully_bound_structs = { level = "warn", priority = 1 }
  110. semicolon_inside_block = { level = "warn", priority = 1 }
  111. single_char_lifetime_names = { level = "warn", priority = 1 }
  112. std_instead_of_core = { level = "warn", priority = 1 }
  113. str_to_string = { level = "warn", priority = 1 }
  114. string_add = { level = "warn", priority = 1 }
  115. string_slice = { level = "warn", priority = 1 }
  116. string_to_string = { level = "warn", priority = 1 }
  117. suspicious_xor_used_as_pow = { level = "warn", priority = 1 }
  118. tests_outside_test_module = { level = "warn", priority = 1 }
  119. todo = { level = "warn", priority = 1 }
  120. try_err = { level = "warn", priority = 1 }
  121. undocumented_unsafe_blocks = { level = "warn", priority = 1 }
  122. unimplemented = { level = "warn", priority = 1 }
  123. unnecessary_safety_comment = { level = "warn", priority = 1 }
  124. unnecessary_safety_doc = { level = "warn", priority = 1 }
  125. unnecessary_self_imports = { level = "warn", priority = 1 }
  126. unneeded_field_pattern = { level = "warn", priority = 1 }
  127. unseparated_literal_suffix = { level = "warn", priority = 1 }
  128. unused_result_ok = { level = "warn", priority = 1 }
  129. unused_trait_names = { level = "warn", priority = 1 }
  130. unwrap_used = { level = "warn", priority = 1 }
  131. use_debug = { level = "warn", priority = 1 }
  132. verbose_file_reads = { level = "warn", priority = 1 }
  133. # Cargo
  134. cargo = "warn"
  135. cargo_common_metadata = { level = "allow", priority = 1 }