| OLD | NEW |
| 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 4067 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4078 ASSERT(num_optional_parameters >= 0); | 4078 ASSERT(num_optional_parameters >= 0); |
| 4079 set_num_optional_parameters(are_optional_positional ? | 4079 set_num_optional_parameters(are_optional_positional ? |
| 4080 num_optional_parameters : | 4080 num_optional_parameters : |
| 4081 -num_optional_parameters); | 4081 -num_optional_parameters); |
| 4082 } | 4082 } |
| 4083 | 4083 |
| 4084 | 4084 |
| 4085 bool Function::is_optimizable() const { | 4085 bool Function::is_optimizable() const { |
| 4086 if (OptimizableBit::decode(raw_ptr()->kind_tag_) && | 4086 if (OptimizableBit::decode(raw_ptr()->kind_tag_) && |
| 4087 (script() != Script::null()) && | 4087 (script() != Script::null()) && |
| 4088 !is_native() && | |
| 4089 ((end_token_pos() - token_pos()) < FLAG_huge_method_cutoff_in_tokens)) { | 4088 ((end_token_pos() - token_pos()) < FLAG_huge_method_cutoff_in_tokens)) { |
| 4090 // Additional check needed for implicit getters. | 4089 // Additional check needed for implicit getters. |
| 4091 if (HasCode() && | 4090 if (HasCode() && |
| 4092 (Code::Handle(unoptimized_code()).Size() >= | 4091 (Code::Handle(unoptimized_code()).Size() >= |
| 4093 FLAG_huge_method_cutoff_in_code_size)) { | 4092 FLAG_huge_method_cutoff_in_code_size)) { |
| 4094 return false; | 4093 return false; |
| 4095 } else { | 4094 } else { |
| 4096 return true; | 4095 return true; |
| 4097 } | 4096 } |
| 4098 } | 4097 } |
| (...skipping 10511 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 14610 } | 14609 } |
| 14611 | 14610 |
| 14612 | 14611 |
| 14613 void MirrorReference::PrintToJSONStream(JSONStream* stream, bool ref) const { | 14612 void MirrorReference::PrintToJSONStream(JSONStream* stream, bool ref) const { |
| 14614 stream->OpenObject(); | 14613 stream->OpenObject(); |
| 14615 stream->CloseObject(); | 14614 stream->CloseObject(); |
| 14616 } | 14615 } |
| 14617 | 14616 |
| 14618 | 14617 |
| 14619 } // namespace dart | 14618 } // namespace dart |
| OLD | NEW |