Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Side by Side Diff: runtime/vm/raw_object.h

Issue 1420103006: Shared token objects (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: catch up Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/object_test.cc ('k') | runtime/vm/snapshot.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/atomic.h" 9 #include "vm/atomic.h"
10 #include "vm/globals.h" 10 #include "vm/globals.h"
(...skipping 900 matching lines...) Expand 10 before | Expand all | Expand 10 after
911 }; 911 };
912 912
913 913
914 class RawTokenStream : public RawObject { 914 class RawTokenStream : public RawObject {
915 RAW_HEAP_OBJECT_IMPLEMENTATION(TokenStream); 915 RAW_HEAP_OBJECT_IMPLEMENTATION(TokenStream);
916 916
917 RawObject** from() { 917 RawObject** from() {
918 return reinterpret_cast<RawObject**>(&ptr()->private_key_); 918 return reinterpret_cast<RawObject**>(&ptr()->private_key_);
919 } 919 }
920 RawString* private_key_; // Key used for private identifiers. 920 RawString* private_key_; // Key used for private identifiers.
921 RawArray* token_objects_; 921 RawGrowableObjectArray* token_objects_;
922 RawExternalTypedData* stream_; 922 RawExternalTypedData* stream_;
923 RawObject** to() { 923 RawObject** to() {
924 return reinterpret_cast<RawObject**>(&ptr()->stream_); 924 return reinterpret_cast<RawObject**>(&ptr()->stream_);
925 } 925 }
926 926
927 friend class SnapshotReader; 927 friend class SnapshotReader;
928 }; 928 };
929 929
930 930
931 class RawScript : public RawObject { 931 class RawScript : public RawObject {
(...skipping 1335 matching lines...) Expand 10 before | Expand all | Expand 10 after
2267 COMPILE_ASSERT(kExternalTypedDataInt8ArrayCid == 2267 COMPILE_ASSERT(kExternalTypedDataInt8ArrayCid ==
2268 kTypedDataInt8ArrayViewCid + 15); 2268 kTypedDataInt8ArrayViewCid + 15);
2269 COMPILE_ASSERT(kByteBufferCid == kExternalTypedDataInt8ArrayCid + 14); 2269 COMPILE_ASSERT(kByteBufferCid == kExternalTypedDataInt8ArrayCid + 14);
2270 COMPILE_ASSERT(kNullCid == kByteBufferCid + 1); 2270 COMPILE_ASSERT(kNullCid == kByteBufferCid + 1);
2271 return (kNullCid - kTypedDataInt8ArrayCid); 2271 return (kNullCid - kTypedDataInt8ArrayCid);
2272 } 2272 }
2273 2273
2274 } // namespace dart 2274 } // namespace dart
2275 2275
2276 #endif // VM_RAW_OBJECT_H_ 2276 #endif // VM_RAW_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/object_test.cc ('k') | runtime/vm/snapshot.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698