forked from mirrors/gecko-dev
Bug 1903041: Use a linear search in more situations. a=dmeehan
Original Revision: https://phabricator.services.mozilla.com/D214989 Differential Revision: https://phabricator.services.mozilla.com/D216607
This commit is contained in:
parent
eeca4f8483
commit
61c4e4fdf9
1 changed files with 2 additions and 2 deletions
|
|
@ -842,11 +842,12 @@ class TypeDef {
|
|||
return true;
|
||||
}
|
||||
const SuperTypeVector* subSTV = subTypeDef->superTypeVector();
|
||||
const SuperTypeVector* superSTV = superTypeDef->superTypeVector();
|
||||
|
||||
// During construction of a recursion group, the super type vector may not
|
||||
// have been computed yet, in which case we need to fall back to a linear
|
||||
// search.
|
||||
if (!subSTV) {
|
||||
if (!subSTV || !superSTV) {
|
||||
while (subTypeDef) {
|
||||
if (subTypeDef == superTypeDef) {
|
||||
return true;
|
||||
|
|
@ -868,7 +869,6 @@ class TypeDef {
|
|||
return false;
|
||||
}
|
||||
|
||||
const SuperTypeVector* superSTV = superTypeDef->superTypeVector();
|
||||
MOZ_ASSERT(superSTV);
|
||||
MOZ_ASSERT(superSTV->typeDef() == superTypeDef);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue