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

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

Issue 1408183004: Minor cleanup as saved_isolate_ should always be NULL in this case per the ASSERT in the constructo… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 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
« no previous file with comments | « no previous file | no next file » | 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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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_ISOLATE_H_ 5 #ifndef VM_ISOLATE_H_
6 #define VM_ISOLATE_H_ 6 #define VM_ISOLATE_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 "vm/atomic.h" 10 #include "vm/atomic.h"
(...skipping 894 matching lines...) Expand 10 before | Expand all | Expand 10 after
905 } 905 }
906 906
907 ~StartIsolateScope() { 907 ~StartIsolateScope() {
908 if (new_isolate_ == NULL) { 908 if (new_isolate_ == NULL) {
909 // Do nothing. 909 // Do nothing.
910 return; 910 return;
911 } 911 }
912 if (saved_isolate_ != new_isolate_) { 912 if (saved_isolate_ != new_isolate_) {
913 new_isolate_->ClearStackLimit(); 913 new_isolate_->ClearStackLimit();
914 Thread::ExitIsolate(); 914 Thread::ExitIsolate();
915 if (saved_isolate_ != NULL) { 915 ASSERT(saved_isolate_ == NULL);
916 Thread::EnterIsolate(saved_isolate_);
917 }
918 } 916 }
919 } 917 }
920 918
921 private: 919 private:
922 Isolate* new_isolate_; 920 Isolate* new_isolate_;
923 Isolate* saved_isolate_; 921 Isolate* saved_isolate_;
924 922
925 DISALLOW_COPY_AND_ASSIGN(StartIsolateScope); 923 DISALLOW_COPY_AND_ASSIGN(StartIsolateScope);
926 }; 924 };
927 925
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
1027 uint8_t* serialized_message_; 1025 uint8_t* serialized_message_;
1028 intptr_t serialized_message_len_; 1026 intptr_t serialized_message_len_;
1029 Isolate::Flags isolate_flags_; 1027 Isolate::Flags isolate_flags_;
1030 bool paused_; 1028 bool paused_;
1031 bool errors_are_fatal_; 1029 bool errors_are_fatal_;
1032 }; 1030 };
1033 1031
1034 } // namespace dart 1032 } // namespace dart
1035 1033
1036 #endif // VM_ISOLATE_H_ 1034 #endif // VM_ISOLATE_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698