perf(kernel/justification): avoid redundant justification objects
This commit is contained in:
parent
e019ab5500
commit
d69f829337
1 changed files with 1 additions and 1 deletions
|
@ -296,7 +296,7 @@ justification mk_composite(justification const & j1, justification const & j2, o
|
||||||
return justification(new (get_ext_composite_allocator().allocate()) ext_composite_cell(j1, j2, fn, s));
|
return justification(new (get_ext_composite_allocator().allocate()) ext_composite_cell(j1, j2, fn, s));
|
||||||
}
|
}
|
||||||
justification mk_composite1(justification const & j1, justification const & j2) {
|
justification mk_composite1(justification const & j1, justification const & j2) {
|
||||||
if (j1.is_none())
|
if (j1.is_none() || j1.raw() == j2.raw())
|
||||||
return j2;
|
return j2;
|
||||||
if (j2.is_none())
|
if (j2.is_none())
|
||||||
return j1;
|
return j1;
|
||||||
|
|
Loading…
Reference in a new issue