| Index: src/hydrogen.cc
|
| ===================================================================
|
| --- src/hydrogen.cc (revision 6703)
|
| +++ src/hydrogen.cc (working copy)
|
| @@ -870,13 +870,11 @@
|
| }
|
| uses_to_replace.Rewind(0);
|
| block->RemovePhi(phi);
|
| - } else if (phi->HasNoUses() &&
|
| - !phi->HasReceiverOperand() &&
|
| - FLAG_eliminate_dead_phis) {
|
| - // We can't eliminate phis that have the receiver as an operand
|
| - // because in case of throwing an error we need the correct
|
| - // receiver value in the environment to construct a corrent
|
| - // stack trace.
|
| + } else if (FLAG_eliminate_dead_phis && phi->HasNoUses() &&
|
| + !phi->IsReceiver()) {
|
| + // We can't eliminate phis in the receiver position in the environment
|
| + // because in case of throwing an error we need this value to
|
| + // construct a stack trace.
|
| block->RemovePhi(phi);
|
| block->RecordDeletedPhi(phi->merged_index());
|
| }
|
| @@ -2952,6 +2950,9 @@
|
| if (is_store && lookup->IsReadOnly()) {
|
| BAILOUT("read-only global variable");
|
| }
|
| + if (lookup->holder() != *global) {
|
| + BAILOUT("global property on prototype of global object");
|
| + }
|
| }
|
|
|
|
|
|
|