Conversation
481a155 to
11931ab
Compare
sylvestre
reviewed
Feb 25, 2025
11931ab to
892a033
Compare
|
GNU testsuite comparison: |
cf5aa13 to
5aa8a62
Compare
|
GNU testsuite comparison: |
5aa8a62 to
6d7f0d3
Compare
|
GNU testsuite comparison: |
There was a problem hiding this comment.
PR Overview
This pull request rewrites GNU test cases for expr to better track regressions and highlights issues with our current regex dependency. Key changes include:
- Renaming the error variant from InvalidContent(String) to InvalidBracketContent.
- Updating error handling and corresponding tests in syntax_tree.rs.
- Adjusting error message attributes in expr.rs to align with the new error variant.
Reviewed Changes
| File | Description |
|---|---|
| src/uu/expr/src/syntax_tree.rs | Renamed error variant usage and updated test assertions. |
| src/uu/expr/src/expr.rs | Modified the error variant declaration and its error message. |
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
Comments suppressed due to low confidence (1)
src/uu/expr/src/expr.rs:50
- [nitpick] The new static error message may reduce context for debugging. If dynamic error details are useful, consider reintroducing a parameterized variant to capture more specific information.
#[error("Invalid content of \{{\}}"]
|
GNU testsuite comparison: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I've rewritten all the GNU testcases of
gnu/tests/expr/expr.plin our testsuite, to more easily track potential regressions.Sadly, the remaining issues are all caused by our regex dependency (
rust-onig) which has a diverging behavior from GNU. This emphasizes the need to find another regex engine, as discussed in #1145