Skip to content

Conversation

@kemitix
Copy link
Contributor

@kemitix kemitix commented Oct 27, 2024

Description

Moves the creation of an array of TextProcessor objects, that includes the contruction of a Regex to the outside of a loop. The array is only ever user by reference, so reusing a single instance will produce the same effects.

Motivation and Context

The Lints CI check is failing due to the creation of the same Regex within a loop.

How Has This Been Tested?

The change is within the integration tests, and those continue to pass.

Screenshots / Logs (if applicable)

image

Types of Changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (no code change)
  • Refactor (refactoring production code)
  • Other

Checklist:

  • My code follows the code style of this project.
  • I have updated the documentation accordingly.
  • I have formatted the code with rustfmt.
  • I checked the lints with clippy.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@kemitix kemitix requested a review from orhun as a code owner October 27, 2024 16:53
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 42.88%. Comparing base (99b78b5) to head (eaafe2d).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #937   +/-   ##
=======================================
  Coverage   42.88%   42.88%           
=======================================
  Files          21       21           
  Lines        1712     1712           
=======================================
  Hits          734      734           
  Misses        978      978           
Flag Coverage Δ
unit-tests 42.88% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Owner

@orhun orhun left a comment

Choose a reason for hiding this comment

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

Thanks!

@orhun orhun merged commit 0fabf22 into orhun:main Oct 29, 2024
@kemitix kemitix deleted the fix-regex-lint branch October 29, 2024 07:31
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