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

Unified Diff: lib/compiler/implementation/lib/isolate_patch.dart

Issue 11191078: Make hashCode a getter and not a method. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Update status file with co19 issue number. Created 8 years, 2 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
Index: lib/compiler/implementation/lib/isolate_patch.dart
diff --git a/lib/compiler/implementation/lib/isolate_patch.dart b/lib/compiler/implementation/lib/isolate_patch.dart
index 5bec001499bd3b0c9bb410717acbbb945d8f947e..66e81d92cfd9f0f0d1db7e4b291ddd2f8e3a61fe 100644
--- a/lib/compiler/implementation/lib/isolate_patch.dart
+++ b/lib/compiler/implementation/lib/isolate_patch.dart
@@ -650,7 +650,7 @@ class _BaseSendPort implements SendPort {
abstract void send(var message, [SendPort replyTo]);
abstract bool operator ==(var other);
- abstract int hashCode();
+ abstract int get hashCode;
}
/** A send port that delivers messages in-memory via native JavaScript calls. */
@@ -697,7 +697,7 @@ class _NativeJsSendPort extends _BaseSendPort implements SendPort {
bool operator ==(var other) => (other is _NativeJsSendPort) &&
(_receivePort == other._receivePort);
- int hashCode() => _receivePort._id;
+ int get hashCode => _receivePort._id;
}
/** A send port that delivers messages via worker.postMessage. */
@@ -734,7 +734,7 @@ class _WorkerSendPort extends _BaseSendPort implements SendPort {
(_receivePortId == other._receivePortId);
}
- int hashCode() {
+ int get hashCode {
// TODO(sigmund): use a standard hash when we get one available in corelib.
return (_workerId << 16) ^ (_isolateId << 8) ^ _receivePortId;
}
@@ -787,7 +787,7 @@ class _BufferingSendPort extends _BaseSendPort implements SendPort {
bool operator ==(var other) =>
other is _BufferingSendPort && _id == other._id;
- int hashCode() => _id;
+ int get hashCode => _id;
}
/** Default factory for receive ports. */

Powered by Google App Engine
This is Rietveld 408576698