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

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

Issue 2949383003: Avoid an assert fault in snapshot writer by making sure that the parent of a (Closed)
Patch Set: Created 3 years, 5 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 | « no previous file | 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 2200 matching lines...) Expand 10 before | Expand all | Expand 10 after
2211 2211
2212 // Return the type of this function's signature. It may not be canonical yet. 2212 // Return the type of this function's signature. It may not be canonical yet.
2213 // For example, if this function has a signature of the form 2213 // For example, if this function has a signature of the form
2214 // '(T, [B, C]) => R', where 'T' and 'R' are type parameters of the 2214 // '(T, [B, C]) => R', where 'T' and 'R' are type parameters of the
2215 // owner class of this function, then its signature type is a parameterized 2215 // owner class of this function, then its signature type is a parameterized
2216 // function type with uninstantiated type arguments 'T' and 'R' as elements of 2216 // function type with uninstantiated type arguments 'T' and 'R' as elements of
2217 // its type argument vector. 2217 // its type argument vector.
2218 RawType* SignatureType() const; 2218 RawType* SignatureType() const;
2219 RawType* ExistingSignatureType() const; 2219 RawType* ExistingSignatureType() const;
2220 2220
2221 // Allocate and return a signature function equivalent to this function.
2222 RawFunction* CanonicalSignatureFunction(TrailPtr trail) const;
2223
2221 // Update the signature type (with a canonical version). 2224 // Update the signature type (with a canonical version).
2222 void SetSignatureType(const Type& value) const; 2225 void SetSignatureType(const Type& value) const;
2223 2226
2224 // Return a new function with instantiated result and parameter types. 2227 // Return a new function with instantiated result and parameter types.
2225 RawFunction* InstantiateSignatureFrom( 2228 RawFunction* InstantiateSignatureFrom(
2226 const TypeArguments& instantiator_type_arguments, 2229 const TypeArguments& instantiator_type_arguments,
2227 const TypeArguments& function_type_arguments, 2230 const TypeArguments& function_type_arguments,
2228 Heap::Space space) const; 2231 Heap::Space space) const;
2229 2232
2230 // Build a string of the form '(T, {B b, C c}) => R' representing the 2233 // Build a string of the form '(T, {B b, C c}) => R' representing the
(...skipping 6820 matching lines...) Expand 10 before | Expand all | Expand 10 after
9051 9054
9052 inline void TypeArguments::SetHash(intptr_t value) const { 9055 inline void TypeArguments::SetHash(intptr_t value) const {
9053 // This is only safe because we create a new Smi, which does not cause 9056 // This is only safe because we create a new Smi, which does not cause
9054 // heap allocation. 9057 // heap allocation.
9055 StoreSmi(&raw_ptr()->hash_, Smi::New(value)); 9058 StoreSmi(&raw_ptr()->hash_, Smi::New(value));
9056 } 9059 }
9057 9060
9058 } // namespace dart 9061 } // namespace dart
9059 9062
9060 #endif // RUNTIME_VM_OBJECT_H_ 9063 #endif // RUNTIME_VM_OBJECT_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698