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

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

Issue 10824201: Verify at method exit that stack size is the same as at entry, except for methods with finally clau… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 4 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
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/bigint_operations.h" 10 #include "vm/bigint_operations.h"
(...skipping 3774 matching lines...) Expand 10 before | Expand all | Expand 10 after
3785 ASSERT(n >= 0); 3785 ASSERT(n >= 0);
3786 raw_ptr()->num_optional_parameters_ = n; 3786 raw_ptr()->num_optional_parameters_ = n;
3787 } 3787 }
3788 3788
3789 3789
3790 void Function::set_is_optimizable(bool value) const { 3790 void Function::set_is_optimizable(bool value) const {
3791 raw()->SetIsOptimizable(value); 3791 raw()->SetIsOptimizable(value);
3792 } 3792 }
3793 3793
3794 3794
3795 void Function::set_has_finally(bool value) const {
3796 raw()->SetHasFinally(value);
3797 }
3798
3799
3795 void Function::set_is_native(bool value) const { 3800 void Function::set_is_native(bool value) const {
3796 raw()->SetIsNative(value); 3801 raw()->SetIsNative(value);
3797 } 3802 }
3798 3803
3799 3804
3800 void Function::set_is_abstract(bool value) const { 3805 void Function::set_is_abstract(bool value) const {
3801 raw()->SetIsAbstract(value); 3806 raw()->SetIsAbstract(value);
3802 } 3807 }
3803 3808
3804 3809
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after
4142 result.set_is_const(is_const); 4147 result.set_is_const(is_const);
4143 result.set_is_external(is_external); 4148 result.set_is_external(is_external);
4144 result.set_owner(owner); 4149 result.set_owner(owner);
4145 result.set_token_pos(token_pos); 4150 result.set_token_pos(token_pos);
4146 result.set_end_token_pos(token_pos); 4151 result.set_end_token_pos(token_pos);
4147 result.set_num_fixed_parameters(0); 4152 result.set_num_fixed_parameters(0);
4148 result.set_num_optional_parameters(0); 4153 result.set_num_optional_parameters(0);
4149 result.set_usage_counter(0); 4154 result.set_usage_counter(0);
4150 result.set_deoptimization_counter(0); 4155 result.set_deoptimization_counter(0);
4151 result.set_is_optimizable(true); 4156 result.set_is_optimizable(true);
4157 result.set_has_finally(false);
4152 result.set_is_native(false); 4158 result.set_is_native(false);
4153 result.set_is_abstract(is_abstract); 4159 result.set_is_abstract(is_abstract);
4154 return result.raw(); 4160 return result.raw();
4155 } 4161 }
4156 4162
4157 4163
4158 RawFunction* Function::NewClosureFunction(const String& name, 4164 RawFunction* Function::NewClosureFunction(const String& name,
4159 const Function& parent, 4165 const Function& parent,
4160 intptr_t token_pos) { 4166 intptr_t token_pos) {
4161 ASSERT(name.IsOneByteString()); 4167 ASSERT(name.IsOneByteString());
(...skipping 6887 matching lines...) Expand 10 before | Expand all | Expand 10 after
11049 const char* JSRegExp::ToCString() const { 11055 const char* JSRegExp::ToCString() const {
11050 const String& str = String::Handle(pattern()); 11056 const String& str = String::Handle(pattern());
11051 const char* format = "JSRegExp: pattern=%s flags=%s"; 11057 const char* format = "JSRegExp: pattern=%s flags=%s";
11052 intptr_t len = OS::SNPrint(NULL, 0, format, str.ToCString(), Flags()); 11058 intptr_t len = OS::SNPrint(NULL, 0, format, str.ToCString(), Flags());
11053 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len + 1); 11059 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len + 1);
11054 OS::SNPrint(chars, (len + 1), format, str.ToCString(), Flags()); 11060 OS::SNPrint(chars, (len + 1), format, str.ToCString(), Flags());
11055 return chars; 11061 return chars;
11056 } 11062 }
11057 11063
11058 } // namespace dart 11064 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/parser.cc » ('j') | runtime/vm/raw_object.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698