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

Unified Diff: sdk/lib/internal/symbol.dart

Issue 2038853003: Specialize Symbol.hashCode (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sdk/lib/_internal/js_runtime/lib/internal_patch.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/internal/symbol.dart
diff --git a/sdk/lib/internal/symbol.dart b/sdk/lib/internal/symbol.dart
index 21d976b119e423d42842c6a07d5dfc9169911427..64fcdb389118bfa0585010508800802e89da92c5 100644
--- a/sdk/lib/internal/symbol.dart
+++ b/sdk/lib/internal/symbol.dart
@@ -112,10 +112,7 @@ class Symbol implements core.Symbol {
bool operator ==(other) => other is Symbol && _name == other._name;
- int get hashCode {
- const arbitraryPrime = 664597;
- return 0x1fffffff & (arbitraryPrime * _name.hashCode);
- }
+ external int get hashCode;
toString() => 'Symbol("$_name")';
« no previous file with comments | « sdk/lib/_internal/js_runtime/lib/internal_patch.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698