Commit c9f787b
committed
[core] Make TDirectory::Append tolerant to identical objects.
When calling TDirectory::Append(obj, replace=true), and obj is already
in the directory, don't issue a warning. Proceed to clear the list of any
duplicates, issuing a warning for each.
This will enable workflows such as:
auto h = new TH1D(...);
directory->Append(h, true);
After this change, the above lines work both with implicit object
ownership off and on.1 parent c6512a3 commit c9f787b
1 file changed
+4
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
207 | 207 | | |
208 | 208 | | |
209 | 209 | | |
210 | | - | |
211 | | - | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
212 | 214 | | |
213 | 215 | | |
214 | 216 | | |
| |||
0 commit comments