Index: src/full-codegen/ia32/full-codegen-ia32.cc |
diff --git a/src/full-codegen/ia32/full-codegen-ia32.cc b/src/full-codegen/ia32/full-codegen-ia32.cc |
index e1045a80a686e7a5c62b41b112a0cb42664118ff..8bdd8d456db402fa668d09b7ed138e931d50bd71 100644 |
--- a/src/full-codegen/ia32/full-codegen-ia32.cc |
+++ b/src/full-codegen/ia32/full-codegen-ia32.cc |
@@ -109,8 +109,7 @@ void FullCodeGenerator::Generate() { |
// Sloppy mode functions and builtins need to replace the receiver with the |
// global proxy when called as functions (without an explicit receiver |
// object). |
- if (is_sloppy(info->language_mode()) && !info->is_native() && |
- info->MayUseThis()) { |
+ if (info->MustReplaceUndefinedReceiverWithGlobalProxy()) { |
Label ok; |
// +1 for return address. |
int receiver_offset = (info->scope()->num_parameters() + 1) * kPointerSize; |