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

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

Issue 23909002: Implement closurization of regular methods in ObjectMirror.getField in the VM. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 3 months 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/flow_graph_builder.cc ('k') | runtime/vm/object.cc » ('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_OBJECT_H_ 5 #ifndef VM_OBJECT_H_
6 #define VM_OBJECT_H_ 6 #define VM_OBJECT_H_
7 7
8 #include "include/dart_api.h" 8 #include "include/dart_api.h"
9 #include "platform/assert.h" 9 #include "platform/assert.h"
10 #include "platform/utils.h" 10 #include "platform/utils.h"
(...skipping 1446 matching lines...) Expand 10 before | Expand all | Expand 10 after
1457 RawContextScope* context_scope() const; 1457 RawContextScope* context_scope() const;
1458 void set_context_scope(const ContextScope& value) const; 1458 void set_context_scope(const ContextScope& value) const;
1459 1459
1460 // Enclosing function of this local function. 1460 // Enclosing function of this local function.
1461 RawFunction* parent_function() const; 1461 RawFunction* parent_function() const;
1462 1462
1463 // Signature class of this closure function or signature function. 1463 // Signature class of this closure function or signature function.
1464 RawClass* signature_class() const; 1464 RawClass* signature_class() const;
1465 void set_signature_class(const Class& value) const; 1465 void set_signature_class(const Class& value) const;
1466 1466
1467 RawInstance* implicit_static_closure() const; 1467 /// RawInstance* implicit_static_closure() const;
1468 void set_implicit_static_closure(const Instance& closure) const; 1468 /// void set_implicit_static_closure(const Instance& closure) const;
1469 1469
1470 RawCode* closure_allocation_stub() const; 1470 RawCode* closure_allocation_stub() const;
1471 void set_closure_allocation_stub(const Code& value) const; 1471 void set_closure_allocation_stub(const Code& value) const;
1472 1472
1473 void set_extracted_method_closure(const Function& function) const; 1473 void set_extracted_method_closure(const Function& function) const;
1474 RawFunction* extracted_method_closure() const; 1474 RawFunction* extracted_method_closure() const;
1475 1475
1476 void set_saved_args_desc(const Array& array) const; 1476 void set_saved_args_desc(const Array& array) const;
1477 RawArray* saved_args_desc() const; 1477 RawArray* saved_args_desc() const;
1478 1478
(...skipping 12 matching lines...) Expand all
1491 // Returns true iff an implicit closure function has been created 1491 // Returns true iff an implicit closure function has been created
1492 // for this function. 1492 // for this function.
1493 bool HasImplicitClosureFunction() const { 1493 bool HasImplicitClosureFunction() const {
1494 return implicit_closure_function() != null(); 1494 return implicit_closure_function() != null();
1495 } 1495 }
1496 1496
1497 // Return the closure function implicitly created for this function. 1497 // Return the closure function implicitly created for this function.
1498 // If none exists yet, create one and remember it. 1498 // If none exists yet, create one and remember it.
1499 RawFunction* ImplicitClosureFunction() const; 1499 RawFunction* ImplicitClosureFunction() const;
1500 1500
1501 // Return the closure implicitly created for this function.
1502 // If none exists yet, create one and remember it.
1503 RawInstance* ImplicitStaticClosure() const;
1504
1501 // Redirection information for a redirecting factory. 1505 // Redirection information for a redirecting factory.
1502 bool IsRedirectingFactory() const; 1506 bool IsRedirectingFactory() const;
1503 RawType* RedirectionType() const; 1507 RawType* RedirectionType() const;
1504 void SetRedirectionType(const Type& type) const; 1508 void SetRedirectionType(const Type& type) const;
1505 RawString* RedirectionIdentifier() const; 1509 RawString* RedirectionIdentifier() const;
1506 void SetRedirectionIdentifier(const String& identifier) const; 1510 void SetRedirectionIdentifier(const String& identifier) const;
1507 RawFunction* RedirectionTarget() const; 1511 RawFunction* RedirectionTarget() const;
1508 void SetRedirectionTarget(const Function& target) const; 1512 void SetRedirectionTarget(const Function& target) const;
1509 1513
1510 RawFunction::Kind kind() const { 1514 RawFunction::Kind kind() const {
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
1851 1855
1852 void set_name(const String& value) const; 1856 void set_name(const String& value) const;
1853 void set_kind(RawFunction::Kind value) const; 1857 void set_kind(RawFunction::Kind value) const;
1854 void set_is_static(bool value) const; 1858 void set_is_static(bool value) const;
1855 void set_is_const(bool value) const; 1859 void set_is_const(bool value) const;
1856 void set_is_external(bool value) const; 1860 void set_is_external(bool value) const;
1857 void set_parent_function(const Function& value) const; 1861 void set_parent_function(const Function& value) const;
1858 void set_owner(const Object& value) const; 1862 void set_owner(const Object& value) const;
1859 RawFunction* implicit_closure_function() const; 1863 RawFunction* implicit_closure_function() const;
1860 void set_implicit_closure_function(const Function& value) const; 1864 void set_implicit_closure_function(const Function& value) const;
1865 RawInstance* implicit_static_closure() const;
1866 void set_implicit_static_closure(const Instance& closure) const;
1861 void set_num_optional_parameters(intptr_t value) const; // Encoded value. 1867 void set_num_optional_parameters(intptr_t value) const; // Encoded value.
1862 void set_kind_tag(intptr_t value) const; 1868 void set_kind_tag(intptr_t value) const;
1863 void set_data(const Object& value) const; 1869 void set_data(const Object& value) const;
1864 static RawFunction* New(); 1870 static RawFunction* New();
1865 1871
1866 RawString* BuildSignature(bool instantiate, 1872 RawString* BuildSignature(bool instantiate,
1867 NameVisibility name_visibility, 1873 NameVisibility name_visibility,
1868 const AbstractTypeArguments& instantiator) const; 1874 const AbstractTypeArguments& instantiator) const;
1869 1875
1870 // Check the subtype or 'more specific' relationship. 1876 // Check the subtype or 'more specific' relationship.
(...skipping 4291 matching lines...) Expand 10 before | Expand all | Expand 10 after
6162 6168
6163 6169
6164 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, 6170 RawObject* MegamorphicCache::GetTargetFunction(const Array& array,
6165 intptr_t index) { 6171 intptr_t index) {
6166 return array.At((index * kEntryLength) + kTargetFunctionIndex); 6172 return array.At((index * kEntryLength) + kTargetFunctionIndex);
6167 } 6173 }
6168 6174
6169 } // namespace dart 6175 } // namespace dart
6170 6176
6171 #endif // VM_OBJECT_H_ 6177 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_builder.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698