TrigOutputHandling: clang-tidy suggestions and small improvements
Apply a set of small changes and slight refactoring of the code driven mainly by clang-tidy warnings. The addressed warnings (not always all cases, only where reasonable): * use `= default` to define a trivial destructor [modernize-use-equals-default] * use `using` instead of `typedef` [modernize-use-using] * implicit conversions of pointers to `bool` [readability-implicit-bool-conversion] * implicit conversion from `bool` to `char` [readability-implicit-bool-conversion] * pass by value and use `std::move` [modernize-pass-by-value] * use nullptr [modernize-use-nullptr] * all parameters should be named in a function [readability-named-parameter] * implement the "[rule of five](https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#Rc-five)" for `BareDataBucket` [cppcoreguidelines-special-member-functions] * implement the "[rule of zero](https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#Rc-zero)" for `TriggerEDMSerialiserTool::Address` * local copy of a variable never modified -> avoid the copy [performance-unnecessary-copy-initialization] * some methods could be made static member functions or anonymous-namespace functions [readability-convert-member-functions-to-static] * constructor does not initialize some fields [cppcoreguidelines-pro-type-member-init] * use `empty()` instead of `size()==0` [readability-container-size-empty] * some improvements to memory allocation, avoid `new` if possible [cppcoreguidelines-owning-memory] * do not use 'else' after 'return' [readability-else-after-return] * function has a definition with different parameter names [readability-inconsistent-declaration-parameter-name] * use a const reference instead of copy as loop variable [performance-for-range-copy] * use `dynamic_cast` instead of `static_cast` to downcast from a base to a derived class [cppcoreguidelines-pro-type-static-cast-downcast] * use single-character overload of `string::find` when searching for a single character [performance-faster-string-find] * `const` values in declarations do not affect the signature of a function, so they should not be put there [readability-avoid-const-params-in-decls]
Showing
- Trigger/TrigSteer/TrigOutputHandling/TrigOutputHandling/HLTResultMTMaker.h 6 additions, 3 deletions.../TrigOutputHandling/TrigOutputHandling/HLTResultMTMaker.h
- Trigger/TrigSteer/TrigOutputHandling/TrigOutputHandling/HLTResultMTMakerTool.h 1 addition, 1 deletion...gOutputHandling/TrigOutputHandling/HLTResultMTMakerTool.h
- Trigger/TrigSteer/TrigOutputHandling/TrigOutputHandling/ITriggerBitsMakerTool.h 1 addition, 1 deletion...OutputHandling/TrigOutputHandling/ITriggerBitsMakerTool.h
- Trigger/TrigSteer/TrigOutputHandling/TrigOutputHandling/TriggerBitsMakerTool.h 3 additions, 3 deletions...gOutputHandling/TrigOutputHandling/TriggerBitsMakerTool.h
- Trigger/TrigSteer/TrigOutputHandling/src/BareDataBucket.h 12 additions, 7 deletionsTrigger/TrigSteer/TrigOutputHandling/src/BareDataBucket.h
- Trigger/TrigSteer/TrigOutputHandling/src/DecisionSummaryMakerAlg.cxx 2 additions, 5 deletions...gSteer/TrigOutputHandling/src/DecisionSummaryMakerAlg.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/DecisionSummaryMakerAlg.h 1 addition, 1 deletion...rigSteer/TrigOutputHandling/src/DecisionSummaryMakerAlg.h
- Trigger/TrigSteer/TrigOutputHandling/src/HLTEDMCreator.cxx 5 additions, 5 deletionsTrigger/TrigSteer/TrigOutputHandling/src/HLTEDMCreator.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/HLTEDMCreator.h 1 addition, 1 deletionTrigger/TrigSteer/TrigOutputHandling/src/HLTEDMCreator.h
- Trigger/TrigSteer/TrigOutputHandling/src/HLTEDMCreatorAlg.cxx 1 addition, 10 deletions...ger/TrigSteer/TrigOutputHandling/src/HLTEDMCreatorAlg.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/HLTEDMCreatorAlg.h 1 addition, 2 deletionsTrigger/TrigSteer/TrigOutputHandling/src/HLTEDMCreatorAlg.h
- Trigger/TrigSteer/TrigOutputHandling/src/HLTResultMTMaker.cxx 1 addition, 7 deletions...ger/TrigSteer/TrigOutputHandling/src/HLTResultMTMaker.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/HLTResultMTMakerAlg.cxx 0 additions, 2 deletions.../TrigSteer/TrigOutputHandling/src/HLTResultMTMakerAlg.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/HLTResultMTMakerAlg.h 1 addition, 1 deletion...er/TrigSteer/TrigOutputHandling/src/HLTResultMTMakerAlg.h
- Trigger/TrigSteer/TrigOutputHandling/src/StreamTagMakerTool.cxx 10 additions, 18 deletions...r/TrigSteer/TrigOutputHandling/src/StreamTagMakerTool.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/StreamTagMakerTool.h 2 additions, 4 deletions...ger/TrigSteer/TrigOutputHandling/src/StreamTagMakerTool.h
- Trigger/TrigSteer/TrigOutputHandling/src/TriggerBitsMakerTool.cxx 1 addition, 3 deletions...TrigSteer/TrigOutputHandling/src/TriggerBitsMakerTool.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/TriggerEDMDeserialiserAlg.cxx 84 additions, 38 deletions...teer/TrigOutputHandling/src/TriggerEDMDeserialiserAlg.cxx
- Trigger/TrigSteer/TrigOutputHandling/src/TriggerEDMDeserialiserAlg.h 9 additions, 47 deletions...gSteer/TrigOutputHandling/src/TriggerEDMDeserialiserAlg.h
- Trigger/TrigSteer/TrigOutputHandling/src/TriggerEDMSerialiserTool.cxx 31 additions, 31 deletions...Steer/TrigOutputHandling/src/TriggerEDMSerialiserTool.cxx
Loading
Please register or sign in to comment