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/intermediate_language.cc

Issue 11365196: Move JSSyntaxRegExp to core as a private member. This removes the last refrences to dart:coreimpl. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix two pending TODO's. Created 8 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 | 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/intermediate_language.h" 5 #include "vm/intermediate_language.h"
6 6
7 #include "vm/bit_vector.h" 7 #include "vm/bit_vector.h"
8 #include "vm/dart_entry.h" 8 #include "vm/dart_entry.h"
9 #include "vm/flow_graph_allocator.h" 9 #include "vm/flow_graph_allocator.h"
10 #include "vm/flow_graph_builder.h" 10 #include "vm/flow_graph_builder.h"
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 return String::Handle(lib.PrivateName(test_name_symbol)).Equals(name); 224 return String::Handle(lib.PrivateName(test_name_symbol)).Equals(name);
225 } 225 }
226 return name.Equals(test_name); 226 return name.Equals(test_name);
227 } 227 }
228 228
229 229
230 MethodRecognizer::Kind MethodRecognizer::RecognizeKind( 230 MethodRecognizer::Kind MethodRecognizer::RecognizeKind(
231 const Function& function) { 231 const Function& function) {
232 // Only core and math library methods can be recognized. 232 // Only core and math library methods can be recognized.
233 const Library& core_lib = Library::Handle(Library::CoreLibrary()); 233 const Library& core_lib = Library::Handle(Library::CoreLibrary());
234 const Library& core_impl_lib = Library::Handle(Library::CoreImplLibrary());
235 const Library& math_lib = Library::Handle(Library::MathLibrary()); 234 const Library& math_lib = Library::Handle(Library::MathLibrary());
236 const Class& function_class = Class::Handle(function.Owner()); 235 const Class& function_class = Class::Handle(function.Owner());
237 if ((function_class.library() != core_lib.raw()) && 236 if ((function_class.library() != core_lib.raw()) &&
238 (function_class.library() != core_impl_lib.raw()) &&
239 (function_class.library() != math_lib.raw())) { 237 (function_class.library() != math_lib.raw())) {
240 return kUnknown; 238 return kUnknown;
241 } 239 }
242 const Library& lib = Library::Handle(function_class.library()); 240 const Library& lib = Library::Handle(function_class.library());
243 const String& function_name = String::Handle(function.name()); 241 const String& function_name = String::Handle(function.name());
244 const String& class_name = String::Handle(function_class.Name()); 242 const String& class_name = String::Handle(function_class.Name());
245 243
246 #define RECOGNIZE_FUNCTION(test_class_name, test_function_name, enum_name) \ 244 #define RECOGNIZE_FUNCTION(test_class_name, test_function_name, enum_name) \
247 if (CompareNames(lib, #test_function_name, function_name) && \ 245 if (CompareNames(lib, #test_function_name, function_name) && \
248 CompareNames(lib, #test_class_name, class_name)) { \ 246 CompareNames(lib, #test_class_name, class_name)) { \
(...skipping 2396 matching lines...) Expand 10 before | Expand all | Expand 10 after
2645 return Array::length_offset(); 2643 return Array::length_offset();
2646 default: 2644 default:
2647 UNREACHABLE(); 2645 UNREACHABLE();
2648 return -1; 2646 return -1;
2649 } 2647 }
2650 } 2648 }
2651 2649
2652 #undef __ 2650 #undef __
2653 2651
2654 } // namespace dart 2652 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698