mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 914132 part 4 - Fold |typeof object| if possible. r=bhackett
This commit is contained in:
parent
0c229fcfa2
commit
704175de0f
@ -1888,6 +1888,14 @@ MTypeOf::foldsTo(bool useValueNumbers)
|
||||
case MIRType_Boolean:
|
||||
type = JSTYPE_BOOLEAN;
|
||||
break;
|
||||
case MIRType_Object:
|
||||
if (!inputMaybeCallableOrEmulatesUndefined()) {
|
||||
// Object is not callable and does not emulate undefined, so it's
|
||||
// safe to fold to "object".
|
||||
type = JSTYPE_OBJECT;
|
||||
break;
|
||||
}
|
||||
// FALL THROUGH
|
||||
default:
|
||||
return this;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user