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

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

Issue 1493533002: Reset top-level class finalization (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years 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.h ('k') | runtime/vm/parser.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 #include "vm/object.h" 5 #include "vm/object.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 #include "vm/cpu.h" 10 #include "vm/cpu.h"
(...skipping 3519 matching lines...) Expand 10 before | Expand all | Expand 10 after
3530 } 3530 }
3531 3531
3532 3532
3533 void Class::set_is_finalized() const { 3533 void Class::set_is_finalized() const {
3534 ASSERT(!is_finalized()); 3534 ASSERT(!is_finalized());
3535 set_state_bits(ClassFinalizedBits::update(RawClass::kFinalized, 3535 set_state_bits(ClassFinalizedBits::update(RawClass::kFinalized,
3536 raw_ptr()->state_bits_)); 3536 raw_ptr()->state_bits_));
3537 } 3537 }
3538 3538
3539 3539
3540 void Class::ResetFinalization() const {
3541 ASSERT(IsTopLevel());
3542 set_state_bits(ClassFinalizedBits::update(RawClass::kAllocated,
3543 raw_ptr()->state_bits_));
3544 set_state_bits(TypeFinalizedBit::update(false, raw_ptr()->state_bits_));
3545 }
3546
3547
3540 void Class::set_is_prefinalized() const { 3548 void Class::set_is_prefinalized() const {
3541 ASSERT(!is_finalized()); 3549 ASSERT(!is_finalized());
3542 set_state_bits(ClassFinalizedBits::update(RawClass::kPreFinalized, 3550 set_state_bits(ClassFinalizedBits::update(RawClass::kPreFinalized,
3543 raw_ptr()->state_bits_)); 3551 raw_ptr()->state_bits_));
3544 } 3552 }
3545 3553
3546 3554
3547 void Class::set_is_marked_for_parsing() const { 3555 void Class::set_is_marked_for_parsing() const {
3548 set_state_bits(MarkedForParsingBit::update(true, raw_ptr()->state_bits_)); 3556 set_state_bits(MarkedForParsingBit::update(true, raw_ptr()->state_bits_));
3549 } 3557 }
(...skipping 18372 matching lines...) Expand 10 before | Expand all | Expand 10 after
21922 return tag_label.ToCString(); 21930 return tag_label.ToCString();
21923 } 21931 }
21924 21932
21925 21933
21926 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const { 21934 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const {
21927 Instance::PrintJSONImpl(stream, ref); 21935 Instance::PrintJSONImpl(stream, ref);
21928 } 21936 }
21929 21937
21930 21938
21931 } // namespace dart 21939 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698