Copilot commented on code in PR #1922:
URL: https://github.com/apache/auron/pull/1922#discussion_r2704715713
##########
Cargo.toml:
##########
@@ -27,10 +27,95 @@ members = [
"native-engine/auron-memmgr",
]
+[workspace.lints.rust]
+# Pending processing (temporarily allow)
+unused_variables = "allow"
+dead_code = "allow"
+unused_imports = "allow"
+unused_must_use = "allow"
+deprecated = "allow"
+
[workspace.lints.clippy]
unwrap_used = "deny"
panic = "deny"
+# Pending processing (temporarily allow)
+# Unwrap/Error Handling
+unnecessary_unwrap = "allow"
+needless_question_mark = "allow"
+unnecessary_literal_unwrap = "allow"
+bind_instead_of_map = "allow"
+expect_fun_call = "allow"
+io_other_error = "allow"
+unnecessary_fallible_conversions = "allow"
+
+# Unsafe/Memory
+missing_transmute_annotations = "allow"
+declare_interior_mutable_const = "allow"
+borrow_interior_mutable_const = "allow"
+uninit_vec = "allow"
+macro_metavars_in_unsafe = "allow"
+ptr_arg = "allow"
+borrowed_box = "allow"
+
+# Iterator/Collection
+manual_flatten = "allow"
+iter_cloned_collect = "allow"
+into_iter_on_ref = "allow"
+box_collection = "allow"
+useless_vec = "allow"
+len_without_is_empty = "allow"
+len_zero = "allow"
+mem_replace_option_with_none = "allow"
+get_first = "allow"
+
+# Loop/Control Flow
+needless_range_loop = "allow"
+while_let_loop = "allow"
+while_let_on_iterator = "allow"
+explicit_counter_loop = "allow"
+
+# Format/String
+useless_format = "allow"
+uninlined_format_args = "allow"
+to_string_in_format_args = "allow"
+
+# Code Style/Redundancy (Part 1)
+needless_borrow = "allow"
+needless_return = "allow"
+redundant_closure = "allow"
+redundant_locals = "allow"
+redundant_pattern_matching = "allow"
+
+# Code Style/Redundancy (Part 2)
+unnecessary_cast = "allow"
+unnecessary_to_owned = "allow"
+useless_asref = "allow"
+clone_on_copy = "allow"
+unit_arg = "allow"
+manual_repeat_n = "allow"
+manual_div_ceil = "allow"
+
+# Condition/Logic
+collapsible_if = "allow"
+collapsible_else_if = "allow"
+if_same_then_else = "allow"
+match_like_matches_macro = "allow"
+explicit_auto_deref = "allow"
+bool_assert_comparison = "allow"
+
+# Naming/Structure/Remaining
+upper_case_acronyms = "allow"
+module_inception = "allow"
+too_many_arguments = "allow"
+should_implement_trait = "allow"
+extra_unused_lifetimes = "allow"
+crate_in_macro_def = "allow"
+int_plus_one = "allow"
+derived_hash_with_manual_eq = "allow"
+approx_constant = "allow"
+op_ref = "allow"
Review Comment:
The PR description states that auto-fixable lint issues are being resolved
via `cargo clippy --fix`, and many clippy warnings have indeed been fixed in
the code (e.g., `needless_return`, `redundant_closure`, `useless_format`,
`uninlined_format_args`). However, these same lints are configured as "allow"
in the workspace lint configuration with a comment "# Pending processing
(temporarily allow)".
This creates a confusing situation where the code has been fixed for these
lints, but they're still allowed. Consider either:
1. Removing the "allow" directives for lints that have already been fixed
throughout the codebase, or
2. Clarifying in the PR description and commit message that this is a
two-phase approach where fixes are applied first, but enforcement will come in
a future PR.
If the intent is to gradually enforce these lints, it would be beneficial to
track which lints still need fixes versus which are already clean.
```suggestion
op_ref = "warn"
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]