Skip to content

fix: resolve remaining clippy pedantic warnings (71→0)#139

Merged
ajianaz merged 1 commit into
developfrom
fix/clippy-pedantic-part2
Jun 2, 2026
Merged

fix: resolve remaining clippy pedantic warnings (71→0)#139
ajianaz merged 1 commit into
developfrom
fix/clippy-pedantic-part2

Conversation

@ajianaz
Copy link
Copy Markdown
Collaborator

@ajianaz ajianaz commented Jun 2, 2026

Completes #84 — zero clippy::pedantic warnings remaining.

Summary: All 71 remaining pedantic warnings resolved:

  • Fixed: clone_from, let...else, self by value, match arm merge
  • Allowed with reason: too_many_lines (4), struct_excessive_bools (2), format_push_string (28), format_collect (2), float_cmp (4 tests), unnecessary_wraps, items_after_statements, ref_option, doc_backticks, casts (2), struct_field_names

Checks: 224 tests ✅, clippy pedantic 0 warnings ✅, fmt clean ✅

Changes:
- providers.rs: remove unnecessary Result wrapper
- review.rs: allow struct_excessive_bools, cast_possible_truncation
- scan.rs: let...else pattern, allow too_many_lines, format_collect
- upload.rs: allow items_after_statements, cast_precision_loss
- loader.rs: let...else pattern, allow too_many_lines + casts
- schema.rs: clone_from() for merge_into, allow float_cmp in tests
- cache.rs: allow format_collect
- llm.rs: allow struct_field_names, too_many_lines, format_push_string, doc_backticks
- review.rs: let...else pattern
- scanner.rs: allow unnecessary_wraps, format_push_string
- types.rs: self by value, merge match arms, allow float_cmp
- compact.rs: allow format_push_string
- pretty.rs: allow format_push_string
- sarif.rs: merge identical match arms
- main.rs: allow too_many_lines, struct_excessive_bools, ref_option
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 2, 2026

🔍 Cora AI Code Review

Blocked — critical issues found.

🔴 Error (1)

  • src/engine/types.rs:100 — The match arm for "suggestion" | "info" was removed and folded into the wildcard _ arm. While functionally equivalent for the values shown, this makes the mapping of the string "suggestion" to IssueType::Suggestion implicit rather than explicit. If a new IssueType variant is added in the future, the wildcard would silently swallow "suggestion" and "info" instead of mapping them correctly. More importantly, the explicit match on known strings served as documentation of valid input values.

Review powered by cora-cli · BYOK · MIT

@ajianaz ajianaz merged commit 3d9371a into develop Jun 2, 2026
7 checks passed
@ajianaz ajianaz deleted the fix/clippy-pedantic-part2 branch June 2, 2026 08:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant