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 2013 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2024 BinaryOpStub stub(op, mode); | 2024 BinaryOpStub stub(op, mode); |
2025 JumpPatchSite patch_site(masm_); // unbound, signals no inlined smi code. | 2025 JumpPatchSite patch_site(masm_); // unbound, signals no inlined smi code. |
2026 CallIC(stub.GetCode(), RelocInfo::CODE_TARGET, | 2026 CallIC(stub.GetCode(), RelocInfo::CODE_TARGET, |
2027 expr->BinaryOperationFeedbackId()); | 2027 expr->BinaryOperationFeedbackId()); |
2028 patch_site.EmitPatchInfo(); | 2028 patch_site.EmitPatchInfo(); |
2029 context()->Plug(r0); | 2029 context()->Plug(r0); |
2030 } | 2030 } |
2031 | 2031 |
2032 | 2032 |
2033 void FullCodeGenerator::EmitAssignment(Expression* expr) { | 2033 void FullCodeGenerator::EmitAssignment(Expression* expr) { |
2034 // Invalid left-hand sides are rewritten to have a 'throw | 2034 // Invalid left-hand sides are rewritten by the parser to have a 'throw |
2035 // ReferenceError' on the left-hand side. | 2035 // ReferenceError' on the left-hand side. |
2036 if (!expr->IsValidLeftHandSide()) { | 2036 if (!expr->IsValidLeftHandSide()) { |
2037 VisitForEffect(expr); | 2037 VisitForEffect(expr); |
2038 return; | 2038 return; |
2039 } | 2039 } |
2040 | 2040 |
2041 // Left-hand side can only be a property, a global or a (parameter or local) | 2041 // Left-hand side can only be a property, a global or a (parameter or local) |
2042 // slot. | 2042 // slot. |
2043 enum LhsKind { VARIABLE, NAMED_PROPERTY, KEYED_PROPERTY }; | 2043 enum LhsKind { VARIABLE, NAMED_PROPERTY, KEYED_PROPERTY }; |
2044 LhsKind assign_type = VARIABLE; | 2044 LhsKind assign_type = VARIABLE; |
(...skipping 2508 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4553 *context_length = 0; | 4553 *context_length = 0; |
4554 return previous_; | 4554 return previous_; |
4555 } | 4555 } |
4556 | 4556 |
4557 | 4557 |
4558 #undef __ | 4558 #undef __ |
4559 | 4559 |
4560 } } // namespace v8::internal | 4560 } } // namespace v8::internal |
4561 | 4561 |
4562 #endif // V8_TARGET_ARCH_ARM | 4562 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |