Skip to content

Fix clippy::semicolon_if_nothing_returned warnings#224

Merged
Brooooooklyn merged 2 commits intomainfrom
copilot/fix-semicolon-if-nothing-returned
Oct 15, 2025
Merged

Fix clippy::semicolon_if_nothing_returned warnings#224
Brooooooklyn merged 2 commits intomainfrom
copilot/fix-semicolon-if-nothing-returned

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Oct 14, 2025

This PR fixes two clippy::semicolon_if_nothing_returned warnings to ensure consistent formatting across the codebase.

Changes

Added semicolons to statements that return nothing (unit type ()) in two locations:

  1. crates/fspy_preload_unix/src/interceptions/spawn/exec/mod.rs - Added semicolon after pre_exec.run()? in the exec handler
  2. crates/fspy/src/command.rs - Added semicolon after the self.envs assignment statement

Why

The clippy lint semicolon_if_nothing_returned encourages consistent formatting by requiring semicolons on statements that don't return a value. This makes the code more readable and follows Rust's style conventions.

Before:

pre_exec.run()?

After:

pre_exec.run()?;

Testing

  • All existing tests pass (71 tests)
  • Verified with cargo clippy --workspace -- -W clippy::semicolon_if_nothing_returned - no warnings remain
Original prompt

Fix clippy::semicolon_if_nothing_returned warnings


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Co-authored-by: Brooooooklyn <3468483+Brooooooklyn@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix clippy::semicolon_if_nothing_returned warnings Fix clippy::semicolon_if_nothing_returned warnings Oct 14, 2025
Copilot AI requested a review from Brooooooklyn October 14, 2025 03:18
@Brooooooklyn Brooooooklyn marked this pull request as ready for review October 15, 2025 07:22
Copilot AI review requested due to automatic review settings October 15, 2025 07:22
Copy link
Copy Markdown
Contributor

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 fixes two clippy::semicolon_if_nothing_returned warnings by adding semicolons to statements that return the unit type ().

Key Changes

  • Added semicolons to two statements that don't return values to comply with Rust style conventions
  • Ensures consistent formatting across the codebase

Reviewed Changes

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

File Description
crates/fspy_preload_unix/src/interceptions/spawn/exec/mod.rs Added semicolon after pre_exec.run()? call
crates/fspy/src/command.rs Added semicolon after .collect() assignment

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@Brooooooklyn Brooooooklyn merged commit dd43e1e into main Oct 15, 2025
8 checks passed
@Brooooooklyn Brooooooklyn deleted the copilot/fix-semicolon-if-nothing-returned branch October 15, 2025 07:22
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.

3 participants