Skip to content

egammaSuperClusterBuilderBase remove redundant nullptr check

When we create newEgRec we call std::make_unique<egammaRec>(*egRec). We then check that newEgRec does not own a nullptr. But since we already initialised it by value this is impossible (I think?!?).

This MR changes the guard to instead check that egRec is not nullptr which might also be impossible but in that case it would be due to some feature of EgammaRecContainer/DataVector that I am not aware of.

Since we already deRef egRec there is no need to check it is not nullptr at the end of the loopy body. Perhaps a check earlier but this was never needed before.

Edited by Lucy Lewitt

Merge request reports