fix: accept U/u integer-literal suffix before << in whitespace/operators#440
fix: accept U/u integer-literal suffix before << in whitespace/operators#440Noethix55555 wants to merge 3 commits into
Conversation
The check that allows no-space shifts of suffixed integer literals (10UL<<20, 10LL<<20) omitted the standalone U/u suffix, so 10U<<20 and 10u<<20 were wrongly flagged as missing spaces around <<. Add U and u to the suffix alternation.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThis PR fixes a false-positive operator-spacing lint error. The ChangesLeft-shift operator spacing check
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
GitHub account was created today. |
the better way to do this probably no need to worry about the `OPERATORULL<<` F+ why write and commit straight from github? yoloooo
for more information, see https://pre-commit.ci
|
next, could we review the other PRs before they become a year old? :) |
Summary
The
whitespace/operatorscheck allows no-space shifts of suffixed integer literals (10UL<<20,10LL<<20), but the suffix alternation omitted the standaloneU/usuffix, so10U<<20and10u<<20were wrongly reported as missing spaces around<<. This addsUanduto the alternation.Added assertions for
10U<<20and10u<<20next to the existing10LL<<20/10ULL<<20cases.Closes #439.
Summary by CodeRabbit
Bug Fixes
Tests
Usuffix casing.