Stty: implemented hex and octal parsing for rows and columns
3 out of the 5 stty GNU tests are now passing and was taking a look at why the stty-row-col test was now failing. The issue was that the row and column options are able to accept hex and oct values and the parser we were using did not support the parsing of those values. This change makes the stty-row-col tests now pass.
I have modified the parser helper function and added tests that compare the output of the uutils implementation to the gnu implementation.
I'd mentioned here do this in an utility file and re-use it in all the places we should parse such integers
Good idea, I added a helper in the parser folder to be able to reuse that logic
GNU testsuite comparison:
Skipping an intermittent issue tests/tail/overlay-headers (passes in this run but fails in the 'main' branch)
GNU testsuite comparison:
Skip an intermittent issue tests/tail/overlay-headers (fails in this run but passes in the 'main' branch)
GNU testsuite comparison:
Skipping an intermittent issue tests/misc/tee (passes in this run but fails in the 'main' branch)
GNU testsuite comparison:
Skip an intermittent issue tests/tail/overlay-headers (fails in this run but passes in the 'main' branch)
CodSpeed Performance Report
Merging #9516 will not alter performance
Comparing ChrisDryden:hex_octal_parsing (5a3fb2e) with main (2000af8)
Summary
✅ 127 untouched
⏩ 6 skipped[^skipped]
[^skipped]: 6 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.
GNU testsuite comparison:
Congrats! The gnu test tests/stty/stty-row-col is no longer failing!
The benchmark change is unrelated, should be good for another round of reviews
GNU testsuite comparison:
Skipping an intermittent issue tests/tail/overlay-headers (passes in this run but fails in the 'main' branch)
Congrats! The gnu test tests/stty/stty-row-col is no longer failing!
GNU testsuite comparison:
Skipping an intermittent issue tests/tail/overlay-headers (passes in this run but fails in the 'main' branch)
Congrats! The gnu test tests/stty/stty-row-col is no longer failing!
GNU testsuite comparison:
Skipping an intermittent issue tests/tail/overlay-headers (passes in this run but fails in the 'main' branch)
Congrats! The gnu test tests/stty/stty-row-col is no longer failing!
I ended up reverting back to the approach of using the existing parsing helper function since it reduces the amount of new code, and IMO makes it cleaner. Now that its down to ~40 lines should be easier to review
GNU testsuite comparison:
Congrats! The gnu test tests/stty/stty-row-col is no longer failing!
Congrats! The gnu test tests/tail/inotify-dir-recreate is now passing!