Skip to content

Conversation

@mt82
Copy link
Contributor

@mt82 mt82 commented Dec 23, 2025

Default initialization values have been introduced for all CRTHit data members. This change ensures that variables are properly initialized at object creation, reducing the risk of undefined behavior and improving code reliability.

@mt82 mt82 linked an issue Dec 23, 2025 that may be closed by this pull request
@mt82 mt82 changed the title added initialization added initialization to CRTHit data members Dec 23, 2025
Copy link
Contributor

@kjplows kjplows left a comment

Choose a reason for hiding this comment

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

Looks good to me thanks! I'll let @PetrilloAtWork decide if using flavours of 0 is better than calling on std::numeric_limits<T> here; my one comment is if any CRT variables are expected to be 0 physically (looking at ts0_ns, x_pos etc) probably std::numeric_limits::lowest() is easier to interpret as nonsense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Partially reviewed

Development

Successfully merging this pull request may close these issues.

CRTHit struct members not initialized

3 participants