Skip to content

Commit 55cf724

Browse files
committed
Simplify EmptyCollection(). Thanks, Wolf Behrenhoff!
1 parent 09e2409 commit 55cf724

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

core/cont/src/TCollection.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -815,8 +815,8 @@ TIter TIter::End()
815815

816816
const TCollection &ROOT::Internal::EmptyCollection()
817817
{
818-
static std::unique_ptr<TCollection> fgEmptyCollection((TCollection *)TClass::GetClass("TObjArray")->New());
819-
return *fgEmptyCollection.get();
818+
static TObjArray sEmpty;
819+
return sEmpty;
820820
}
821821

822822
////////////////////////////////////////////////////////////////////////////////

0 commit comments

Comments
 (0)