-
Notifications
You must be signed in to change notification settings - Fork 135
Fix/compilation warnings #962
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
Open
olantwin
wants to merge
10
commits into
master
Choose a base branch
from
fix/compilation-warnings
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+89
−117
Conversation
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
b6baaf1 to
d68ff4e
Compare
wcmartylee
requested changes
Dec 2, 2025
d68ff4e to
9961667
Compare
- Initialise uninitialised variables in GenieGenerator (pout, x, y, z) - Initialise uninitialised variables in MuonBackGenerator (mass, e, tof, phi) - Replace undefined pointer comparison with TString::IsNull() in FixedTargetGenerator - Correct member initialisation order in veto and Tracklet constructors to match declaration order
- Remove unused return value in TimeDetHit::GetNode() - Remove unused variables in MTCDetector (hit, N, mat_number, t1) - Remove unused material pointers in strawtubes (air, Se, Al) - Remove unused variables in splitcalHit (pointZ, boxPassive) - Remove unused variables in generator files (max_nr, buffer, t, top, phi, ns, hadDecay, fsrPtrIn, destParticle)
- Remove unused i_nlayECAL_gas variable and all its assignments in splitcal - Remove unused bparam assignment in GenieGenerator (keep function call) - Remove unused old decay vertex variables (td, xd, yd, zd) in HNLPythia8Generator - Fix signed/unsigned comparison in GenieGenerator loop (use size_t) - Fix signed/unsigned comparison in TEvtGenDecayer (add static_cast)
Add using declarations to bring base class Print methods into scope for all detector Hit and Point classes. This prevents the derived class Print() methods from hiding the base class Print(Option_t*) methods. Affected classes: - ShipHit-derived: TimeDetHit, MTCDetHit, SiliconTargetHit, vetoHit, splitcalHit, UpstreamTaggerHit, strawtubesHit - FairMCPoint-derived: TimeDetPoint, MTCDetPoint, SiliconTargetPoint, vetoPoint, splitcalPoint, UpstreamTaggerPoint, strawtubesPoint - TObject-derived: ShipMCTrack
The TGeoBBox and TGeoTubeSeg objects in ShipMagnet::MagnetSupport() are registered by name in ROOT's geometry manager and referenced in the boolean expression for TGeoCompositeShape. While they appear unused to the compiler, they are accessed by ROOT via their registered names.
Annotate all remaining TGeo objects that are registered by name and used in composite shape boolean expressions: - magyoke1, magyoke2 (used in three different design variants) - magnet1a, magnet1b, magnet1c, magnet1d - C1, C2, Box1, Box2 (coil shapes) - my1, my2, CTop, CBot (yoke and coil shapes for design 4)
- ShipTargetStation: enclosure_outer_tube and enclosure_cutout_box (used in composite shape) - ShipMagnet: myc composite shape (used by name in CTop1, CTop2, CBot1, CBot2 shapes)
Annotate proximity_shielding_envelope, proximity_shielding_inner, and proximity_shielding_hole which are used by name in the composite shape boolean expression at lines 238-240.
6495294 to
56845ec
Compare
- Add [[maybe_unused]] to 'abs' in ShipMuonShield.cxx which is used by name in the composite shape at line 487 - Initialise 'material' pointer to nullptr in ShipTargetStation.cxx and change second if to else if for clarity
- Add [[maybe_unused]] to detbox1/detbox2 in strawtubes.cxx (used in composite shape at line 318) - Add [[maybe_unused]] to histogram pointers in exitHadronAbsorber.cxx (registered in ROOT's gDirectory) - Initialise xmu, ymu, zmu to 0 in MuDISGenerator.cxx to prevent maybe-uninitialized warnings
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.
No description provided.