OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 1480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1491 } else { | 1491 } else { |
1492 __ Drop(3); | 1492 __ Drop(3); |
1493 } | 1493 } |
1494 break; | 1494 break; |
1495 case ObjectLiteral::Property::GETTER: | 1495 case ObjectLiteral::Property::GETTER: |
1496 case ObjectLiteral::Property::SETTER: | 1496 case ObjectLiteral::Property::SETTER: |
1497 // Duplicate receiver on stack. | 1497 // Duplicate receiver on stack. |
1498 __ ldr(r0, MemOperand(sp)); | 1498 __ ldr(r0, MemOperand(sp)); |
1499 __ push(r0); | 1499 __ push(r0); |
1500 VisitForStackValue(key); | 1500 VisitForStackValue(key); |
1501 __ mov(r1, Operand(property->kind() == ObjectLiteral::Property::SETTER ? | 1501 if (property->kind() == ObjectLiteral::Property::GETTER) { |
1502 Smi::FromInt(1) : | 1502 VisitForStackValue(value); |
1503 Smi::FromInt(0))); | 1503 __ LoadRoot(r1, Heap::kNullValueRootIndex); |
1504 __ push(r1); | 1504 __ push(r1); |
1505 VisitForStackValue(value); | 1505 } else { |
| 1506 __ LoadRoot(r1, Heap::kNullValueRootIndex); |
| 1507 __ push(r1); |
| 1508 VisitForStackValue(value); |
| 1509 } |
1506 __ mov(r0, Operand(Smi::FromInt(NONE))); | 1510 __ mov(r0, Operand(Smi::FromInt(NONE))); |
1507 __ push(r0); | 1511 __ push(r0); |
1508 __ CallRuntime(Runtime::kDefineOrRedefineAccessorProperty, 5); | 1512 __ CallRuntime(Runtime::kDefineOrRedefineAccessorProperty, 5); |
1509 break; | 1513 break; |
1510 } | 1514 } |
1511 } | 1515 } |
1512 | 1516 |
1513 if (expr->has_function()) { | 1517 if (expr->has_function()) { |
1514 ASSERT(result_saved); | 1518 ASSERT(result_saved); |
1515 __ ldr(r0, MemOperand(sp)); | 1519 __ ldr(r0, MemOperand(sp)); |
(...skipping 2885 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4401 *context_length = 0; | 4405 *context_length = 0; |
4402 return previous_; | 4406 return previous_; |
4403 } | 4407 } |
4404 | 4408 |
4405 | 4409 |
4406 #undef __ | 4410 #undef __ |
4407 | 4411 |
4408 } } // namespace v8::internal | 4412 } } // namespace v8::internal |
4409 | 4413 |
4410 #endif // V8_TARGET_ARCH_ARM | 4414 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |