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

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

Issue 2951803005: Set and keep parent function of signature functions. (Closed)
Patch Set: address review comments Created 3 years, 6 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
« no previous file with comments | « runtime/vm/kernel_binary_flowgraph.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 RUNTIME_VM_OBJECT_H_ 5 #ifndef RUNTIME_VM_OBJECT_H_
6 #define RUNTIME_VM_OBJECT_H_ 6 #define RUNTIME_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 2838 matching lines...) Expand 10 before | Expand all | Expand 10 after
2849 TokenPosition token_pos, 2849 TokenPosition token_pos,
2850 Heap::Space space = Heap::kOld); 2850 Heap::Space space = Heap::kOld);
2851 2851
2852 // Allocates a new Function object representing a closure function. 2852 // Allocates a new Function object representing a closure function.
2853 static RawFunction* NewClosureFunction(const String& name, 2853 static RawFunction* NewClosureFunction(const String& name,
2854 const Function& parent, 2854 const Function& parent,
2855 TokenPosition token_pos); 2855 TokenPosition token_pos);
2856 2856
2857 // Allocates a new Function object representing a signature function. 2857 // Allocates a new Function object representing a signature function.
2858 // The owner is the scope class of the function type. 2858 // The owner is the scope class of the function type.
2859 // The parent is the enclosing function or null if none.
2859 static RawFunction* NewSignatureFunction(const Object& owner, 2860 static RawFunction* NewSignatureFunction(const Object& owner,
2861 const Function& parent,
2860 TokenPosition token_pos, 2862 TokenPosition token_pos,
2861 Heap::Space space = Heap::kOld); 2863 Heap::Space space = Heap::kOld);
2862 2864
2863 static RawFunction* NewEvalFunction(const Class& owner, 2865 static RawFunction* NewEvalFunction(const Class& owner,
2864 const Script& script, 2866 const Script& script,
2865 bool is_static); 2867 bool is_static);
2866 2868
2867 RawFunction* CreateMethodExtractor(const String& getter_name) const; 2869 RawFunction* CreateMethodExtractor(const String& getter_name) const;
2868 RawFunction* GetMethodExtractor(const String& getter_name) const; 2870 RawFunction* GetMethodExtractor(const String& getter_name) const;
2869 2871
(...skipping 6185 matching lines...) Expand 10 before | Expand all | Expand 10 after
9055 9057
9056 inline void TypeArguments::SetHash(intptr_t value) const { 9058 inline void TypeArguments::SetHash(intptr_t value) const {
9057 // This is only safe because we create a new Smi, which does not cause 9059 // This is only safe because we create a new Smi, which does not cause
9058 // heap allocation. 9060 // heap allocation.
9059 StoreSmi(&raw_ptr()->hash_, Smi::New(value)); 9061 StoreSmi(&raw_ptr()->hash_, Smi::New(value));
9060 } 9062 }
9061 9063
9062 } // namespace dart 9064 } // namespace dart
9063 9065
9064 #endif // RUNTIME_VM_OBJECT_H_ 9066 #endif // RUNTIME_VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/kernel_binary_flowgraph.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698