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/parser.h" | 5 #include "vm/parser.h" |
6 #include "vm/flags.h" | 6 #include "vm/flags.h" |
7 | 7 |
8 #ifndef DART_PRECOMPILED_RUNTIME | 8 #ifndef DART_PRECOMPILED_RUNTIME |
9 | 9 |
10 #include "lib/invocation_mirror.h" | 10 #include "lib/invocation_mirror.h" |
(...skipping 11962 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11973 struct ConstantPosKey : ValueObject { | 11973 struct ConstantPosKey : ValueObject { |
11974 ConstantPosKey(const String& url, TokenPosition pos) | 11974 ConstantPosKey(const String& url, TokenPosition pos) |
11975 : script_url(url), token_pos(pos) { } | 11975 : script_url(url), token_pos(pos) { } |
11976 const String& script_url; | 11976 const String& script_url; |
11977 TokenPosition token_pos; | 11977 TokenPosition token_pos; |
11978 }; | 11978 }; |
11979 | 11979 |
11980 | 11980 |
11981 class ConstMapKeyEqualsTraits { | 11981 class ConstMapKeyEqualsTraits { |
11982 public: | 11982 public: |
| 11983 static const char* Name() { return "ConstMapKeyEqualsTraits"; } |
| 11984 |
11983 static bool IsMatch(const Object& a, const Object& b) { | 11985 static bool IsMatch(const Object& a, const Object& b) { |
11984 const Array& key1 = Array::Cast(a); | 11986 const Array& key1 = Array::Cast(a); |
11985 const Array& key2 = Array::Cast(b); | 11987 const Array& key2 = Array::Cast(b); |
11986 // Compare raw strings of script url symbol and raw smi of token positon. | 11988 // Compare raw strings of script url symbol and raw smi of token positon. |
11987 return (key1.At(0) == key2.At(0)) && (key1.At(1) == key2.At(1)); | 11989 return (key1.At(0) == key2.At(0)) && (key1.At(1) == key2.At(1)); |
11988 } | 11990 } |
11989 static bool IsMatch(const ConstantPosKey& key1, const Object& b) { | 11991 static bool IsMatch(const ConstantPosKey& key1, const Object& b) { |
11990 const Array& key2 = Array::Cast(b); | 11992 const Array& key2 = Array::Cast(b); |
11991 // Compare raw strings of script url symbol and token positon. | 11993 // Compare raw strings of script url symbol and token positon. |
11992 return (key1.script_url.raw() == key2.At(0)) | 11994 return (key1.script_url.raw() == key2.At(0)) |
(...skipping 2480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
14473 const ArgumentListNode& function_args, | 14475 const ArgumentListNode& function_args, |
14474 const LocalVariable* temp_for_last_arg, | 14476 const LocalVariable* temp_for_last_arg, |
14475 bool is_super_invocation) { | 14477 bool is_super_invocation) { |
14476 UNREACHABLE(); | 14478 UNREACHABLE(); |
14477 return NULL; | 14479 return NULL; |
14478 } | 14480 } |
14479 | 14481 |
14480 } // namespace dart | 14482 } // namespace dart |
14481 | 14483 |
14482 #endif // DART_PRECOMPILED_RUNTIME | 14484 #endif // DART_PRECOMPILED_RUNTIME |
OLD | NEW |