-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: replace long unsigned int
with std::size_t
#3930
Conversation
WalkthroughModifications made to the Changes
Possibly related PRs
Suggested labels
Suggested reviewers
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sizeable if true.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Outside diff range and nitpick comments (1)
Examples/Io/Root/include/ActsExamples/Io/Root/RootAthenaDumpReader.hpp (1)
175-175
: Approve this change, I do! Wise choice, std::size_t is.Consistent with modern C++ practices and STL containers, this change is. A natural fit for size-related variables, std::size_t proves to be.
Hmmmm... Consider similar updates for array size constants like maxCL, maxSP, you should. Consistency in the Force, important it is.
- static constexpr unsigned int maxCL = 1500000; - static constexpr unsigned int maxSP = 1500000; - static constexpr unsigned int maxDTT = 1500000; - static constexpr unsigned int maxTRK = 1500000; - static constexpr unsigned int maxPart = 1500000; + static constexpr std::size_t maxCL = 1500000; + static constexpr std::size_t maxSP = 1500000; + static constexpr std::size_t maxDTT = 1500000; + static constexpr std::size_t maxTRK = 1500000; + static constexpr std::size_t maxPart = 1500000;
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (6)
Examples/Algorithms/TrackFinding/src/GbtsSeedingAlgorithm.cpp
(1 hunks)Examples/Io/Root/include/ActsExamples/Io/Root/RootAthenaDumpReader.hpp
(1 hunks)Tests/UnitTests/Plugins/GeoModel/GeoBoxToVolumeTest.cpp
(1 hunks)Tests/UnitTests/Plugins/GeoModel/GeoDetectorObjectTest.cpp
(2 hunks)Tests/UnitTests/Plugins/GeoModel/GeoPolyConverterTests.cpp
(1 hunks)Tests/UnitTests/Plugins/GeoModel/GeoTubeToVolumeTest.cpp
(1 hunks)
🔇 Additional comments (7)
Examples/Algorithms/TrackFinding/src/GbtsSeedingAlgorithm.cpp (1)
358-360
: Good choice, using std::size_t
for loop index, you have made.
Type safety and consistency, it enhances, when iterating over container sizes.
Tests/UnitTests/Plugins/GeoModel/GeoTubeToVolumeTest.cpp (1)
59-61
: Wise decision, changing loop index to std::size_t
is.
Prevents type mismatches, it does, and enhances safety.
Tests/UnitTests/Plugins/GeoModel/GeoBoxToVolumeTest.cpp (1)
61-63
: Commendable, your use of std::size_t
for loop index is.
Improves type safety, it does, ensuring proper iteration.
Tests/UnitTests/Plugins/GeoModel/GeoPolyConverterTests.cpp (2)
91-94
: Enhanced, your loop indices are, with std::size_t
.
Consistency and safety, this change brings.
99-102
: Again, std::size_t
for loop index, you have wisely used.
Robustness in code, it ensures.
Tests/UnitTests/Plugins/GeoModel/GeoDetectorObjectTest.cpp (2)
46-48
: Improved, the loop counter is, by using std::size_t
.
Type safety, it provides, when indexing containers.
78-81
: Consistent use of std::size_t
, commendable it is.
Enhances code reliability, this change does.
|
Summary by CodeRabbit
New Features
Bug Fixes
Refactor
long unsigned int
tostd::size_t
across multiple components for improved type safety.Tests