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

Issue 93433007: Implement hashCode for classes with equals(). (Closed)

Created:
7 years ago by scheglov
Modified:
7 years ago
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Implement hashCode for classes with equals(). These problems were reported by dart2js. R=brianwilkerson@google.com, devoncarew@google.com BUG= Committed: https://code.google.com/p/dart/source/detail?r=31068

Patch Set 1 #

Total comments: 4

Messages

Total messages: 4 (0 generated)
scheglov
7 years ago (2013-12-11 01:54:11 UTC) #1
Brian Wilkerson
LGTM https://codereview.chromium.org/93433007/diff/1/editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/DynamicTypeImpl.java File editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/DynamicTypeImpl.java (right): https://codereview.chromium.org/93433007/diff/1/editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/DynamicTypeImpl.java#newcode57 editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/DynamicTypeImpl.java:57: return 0; Might be good to give it ...
7 years ago (2013-12-11 03:21:42 UTC) #2
scheglov
Committed patchset #1 manually as r31068 (presubmit successful).
7 years ago (2013-12-11 16:33:05 UTC) #3
scheglov
7 years ago (2013-12-11 16:34:04 UTC) #4
Message was sent while issue was closed.
https://codereview.chromium.org/93433007/diff/1/editor/tools/plugins/com.goog...
File
editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/DynamicTypeImpl.java
(right):

https://codereview.chromium.org/93433007/diff/1/editor/tools/plugins/com.goog...
editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/DynamicTypeImpl.java:57:
return 0;
On 2013/12/11 03:21:43, Brian Wilkerson wrote:
> Might be good to give it a different hashCode than bottom (such as 1).

Done.

https://codereview.chromium.org/93433007/diff/1/editor/tools/plugins/com.goog...
File
editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/VoidTypeImpl.java
(right):

https://codereview.chromium.org/93433007/diff/1/editor/tools/plugins/com.goog...
editor/tools/plugins/com.google.dart.engine/src/com/google/dart/engine/internal/type/VoidTypeImpl.java:56:
return 0;
On 2013/12/11 03:21:43, Brian Wilkerson wrote:
> Might be good to give it a unique hash code, such as 2.

Done.

Powered by Google App Engine
This is Rietveld 408576698