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

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

Issue 8440014: Two-phase constructors (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 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 | Annotate | Revision Log
« no previous file with comments | « runtime/vm/dart_entry.cc ('k') | runtime/vm/parser.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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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_OBJECT_H_ 5 #ifndef VM_OBJECT_H_
6 #define VM_OBJECT_H_ 6 #define VM_OBJECT_H_
7 7
8 #include "vm/assert.h" 8 #include "vm/assert.h"
9 #include "vm/dart.h" 9 #include "vm/dart.h"
10 #include "vm/globals.h" 10 #include "vm/globals.h"
(...skipping 1265 matching lines...) Expand 10 before | Expand all | Expand 10 after
1276 intptr_t token_index); 1276 intptr_t token_index);
1277 1277
1278 // Allocates a new Function object representing a closure function, as well as 1278 // Allocates a new Function object representing a closure function, as well as
1279 // a new associated Class object representing the signature class of the 1279 // a new associated Class object representing the signature class of the
1280 // function. 1280 // function.
1281 // The function and the class share the same given name. 1281 // The function and the class share the same given name.
1282 static RawFunction* NewClosureFunction(const String& name, 1282 static RawFunction* NewClosureFunction(const String& name,
1283 const Function& parent, 1283 const Function& parent,
1284 intptr_t token_index); 1284 intptr_t token_index);
1285 1285
1286 static const int kCtorPhaseInit = 1 << 0;
1287 static const int kCtorPhaseBody = 1 << 1;
1288 static const int kCtorPhaseAll = (kCtorPhaseInit | kCtorPhaseBody);
1289
1286 private: 1290 private:
1287 void set_name(const String& value) const; 1291 void set_name(const String& value) const;
1288 void set_kind(RawFunction::Kind value) const; 1292 void set_kind(RawFunction::Kind value) const;
1289 void set_is_static(bool is_static) const; 1293 void set_is_static(bool is_static) const;
1290 void set_is_const(bool is_const) const; 1294 void set_is_const(bool is_const) const;
1291 void set_parent_function(const Function& value) const; 1295 void set_parent_function(const Function& value) const;
1292 void set_token_index(intptr_t value) const; 1296 void set_token_index(intptr_t value) const;
1293 void set_implicit_closure_function(const Function& value) const; 1297 void set_implicit_closure_function(const Function& value) const;
1294 static RawFunction* New(); 1298 static RawFunction* New();
1295 1299
(...skipping 1687 matching lines...) Expand 10 before | Expand all | Expand 10 after
2983 } 2987 }
2984 2988
2985 2989
2986 void Context::SetAt(intptr_t index, const Instance& value) const { 2990 void Context::SetAt(intptr_t index, const Instance& value) const {
2987 StorePointer(InstanceAddr(index), value.raw()); 2991 StorePointer(InstanceAddr(index), value.raw());
2988 } 2992 }
2989 2993
2990 } // namespace dart 2994 } // namespace dart
2991 2995
2992 #endif // VM_OBJECT_H_ 2996 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/dart_entry.cc ('k') | runtime/vm/parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698