| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_RAW_OBJECT_H_ | 5 #ifndef VM_RAW_OBJECT_H_ |
| 6 #define VM_RAW_OBJECT_H_ | 6 #define VM_RAW_OBJECT_H_ |
| 7 | 7 |
| 8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
| 9 #include "vm/globals.h" | 9 #include "vm/globals.h" |
| 10 #include "vm/token.h" | 10 #include "vm/token.h" |
| (...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 590 public: | 590 public: |
| 591 enum Kind { | 591 enum Kind { |
| 592 kRegularFunction, | 592 kRegularFunction, |
| 593 kClosureFunction, | 593 kClosureFunction, |
| 594 kSignatureFunction, // represents a signature only without actual code. | 594 kSignatureFunction, // represents a signature only without actual code. |
| 595 kGetterFunction, // represents getter functions e.g: get foo() { .. }. | 595 kGetterFunction, // represents getter functions e.g: get foo() { .. }. |
| 596 kSetterFunction, // represents setter functions e.g: set foo(..) { .. }. | 596 kSetterFunction, // represents setter functions e.g: set foo(..) { .. }. |
| 597 kConstructor, | 597 kConstructor, |
| 598 kImplicitGetter, // represents an implicit getter for fields. | 598 kImplicitGetter, // represents an implicit getter for fields. |
| 599 kImplicitSetter, // represents an implicit setter for fields. | 599 kImplicitSetter, // represents an implicit setter for fields. |
| 600 kConstImplicitGetter, // represents an implicit const getter for fields. | 600 kImplicitStaticFinalGetter, // represents an implicit getter for static |
| 601 // final fields (incl. static const fields). |
| 601 kMethodExtractor, // converts method into implicit closure on the receiver. | 602 kMethodExtractor, // converts method into implicit closure on the receiver. |
| 602 kNoSuchMethodDispatcher, // invokes noSuchMethod. | 603 kNoSuchMethodDispatcher, // invokes noSuchMethod. |
| 603 kInvokeFieldDispatcher, // invokes a field as a closure. | 604 kInvokeFieldDispatcher, // invokes a field as a closure. |
| 604 }; | 605 }; |
| 605 | 606 |
| 606 private: | 607 private: |
| 607 friend class Class; | 608 friend class Class; |
| 608 RAW_HEAP_OBJECT_IMPLEMENTATION(Function); | 609 RAW_HEAP_OBJECT_IMPLEMENTATION(Function); |
| 609 | 610 |
| 610 RawObject** from() { return reinterpret_cast<RawObject**>(&ptr()->name_); } | 611 RawObject** from() { return reinterpret_cast<RawObject**>(&ptr()->name_); } |
| (...skipping 1096 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1707 // Make sure this is updated when new TypedData types are added. | 1708 // Make sure this is updated when new TypedData types are added. |
| 1708 ASSERT(kTypedDataInt8ArrayViewCid == kTypedDataInt8ArrayCid + 12); | 1709 ASSERT(kTypedDataInt8ArrayViewCid == kTypedDataInt8ArrayCid + 12); |
| 1709 ASSERT(kExternalTypedDataInt8ArrayCid == kTypedDataInt8ArrayViewCid + 13); | 1710 ASSERT(kExternalTypedDataInt8ArrayCid == kTypedDataInt8ArrayViewCid + 13); |
| 1710 ASSERT(kNullCid == kExternalTypedDataInt8ArrayCid + 12); | 1711 ASSERT(kNullCid == kExternalTypedDataInt8ArrayCid + 12); |
| 1711 return (kNullCid - kTypedDataInt8ArrayCid); | 1712 return (kNullCid - kTypedDataInt8ArrayCid); |
| 1712 } | 1713 } |
| 1713 | 1714 |
| 1714 } // namespace dart | 1715 } // namespace dart |
| 1715 | 1716 |
| 1716 #endif // VM_RAW_OBJECT_H_ | 1717 #endif // VM_RAW_OBJECT_H_ |
| OLD | NEW |