Skip to content

Conversation

@Sharktheone
Copy link
Member

No description provided.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR applies stricter Clippy linting rules across the entire codebase, making code more idiomatic and consistent with Rust best practices. The changes focus on improving code quality through automated linting suggestions.

Key Changes:

  • Replaced lazy_static! with standard library LazyLock (Rust 1.80+)
  • Changed function parameters from owned to borrowed types to avoid unnecessary clones
  • Replaced expect() with unwrap() consistently (with added panic documentation)
  • Added const qualifiers to functions that can be evaluated at compile time
  • Used Self instead of explicit type names in implementations
  • Simplified pattern matching and control flow
  • Added panic documentation to functions using unwrap() or expect()
  • Added workspace-level lints configuration to Cargo.toml files

Reviewed changes

Copilot reviewed 148 out of 159 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/engine.rs Changed parameters to references, removed unnecessary clone
src/bin/*.rs Replaced expect() with unwrap() in binary executables
crates/gosub_webinterop/src/**/*.rs Changed visibility from pub(crate) to pub, added Eq derives, used Self
crates/gosub_webexecutor/src/**/*.rs Renamed Error to WebExecutorError, added const qualifiers
crates/gosub_web_platform/src/**/*.rs Changed methods to take &self instead of &mut self, added documentation
crates/gosub_vello/src/**/*.rs Used Self in implementations, added const qualifiers
crates/gosub_shared/src/**/*.rs Replaced lazy_static! with LazyLock, added Eq derives, added const
crates/gosub_css3/src/**/*.rs Extensive refactoring of match expressions, simplified control flow
crates/gosub_net/src/**/*.rs Changed DNS resolver signatures, renamed error types
crates/*/Cargo.toml Added [lints] workspace = true to inherit workspace-level lints

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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