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

Issue 21292003: Handle int/double case expression types correctly. (Closed)

Created:
7 years, 4 months ago by Johnni Winther
Modified:
7 years, 4 months ago
Reviewers:
ahe
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Handle int/double case expression types correctly. BUG=http://dartbug.com/11536 R=ahe@google.com Committed: https://code.google.com/p/dart/source/detail?r=25864

Patch Set 1 #

Total comments: 4

Patch Set 2 : Rebased #

Patch Set 3 : Updated cf. comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+81 lines, -13 lines) Patch
M sdk/lib/_internal/compiler/implementation/ssa/builder.dart View 1 chunk +0 lines, -9 lines 0 comments Download
M sdk/lib/_internal/compiler/implementation/typechecker.dart View 1 2 1 chunk +33 lines, -1 line 0 comments Download
M sdk/lib/_internal/compiler/implementation/warnings.dart View 1 2 1 chunk +4 lines, -1 line 0 comments Download
M tests/compiler/dart2js/type_checker_test.dart View 3 chunks +15 lines, -2 lines 0 comments Download
M tests/language/language.status View 1 1 chunk +2 lines, -0 lines 0 comments Download
A tests/language/switch_int_double_test.dart View 1 chunk +27 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
Johnni Winther
7 years, 4 months ago (2013-07-31 09:14:15 UTC) #1
ahe
LGTM, although I think these semantics are ridiculous. https://codereview.chromium.org/21292003/diff/1/sdk/lib/_internal/compiler/implementation/typechecker.dart File sdk/lib/_internal/compiler/implementation/typechecker.dart (right): https://codereview.chromium.org/21292003/diff/1/sdk/lib/_internal/compiler/implementation/typechecker.dart#newcode1208 sdk/lib/_internal/compiler/implementation/typechecker.dart:1208: bool ...
7 years, 4 months ago (2013-08-06 14:31:36 UTC) #2
Johnni Winther
Committed patchset #3 manually as r25864 (presubmit successful).
7 years, 4 months ago (2013-08-07 09:15:01 UTC) #3
Johnni Winther
7 years, 4 months ago (2013-08-07 09:20:43 UTC) #4
Message was sent while issue was closed.
https://codereview.chromium.org/21292003/diff/1/sdk/lib/_internal/compiler/im...
File sdk/lib/_internal/compiler/implementation/typechecker.dart (right):

https://codereview.chromium.org/21292003/diff/1/sdk/lib/_internal/compiler/im...
sdk/lib/_internal/compiler/implementation/typechecker.dart:1208: bool notEqual =
false;
On 2013/08/06 14:31:36, ahe wrote:
> I feel a name like "hasReportedProblem" or something would be clearer.

Done.

https://codereview.chromium.org/21292003/diff/1/sdk/lib/_internal/compiler/im...
sdk/lib/_internal/compiler/implementation/typechecker.dart:1218:
MessageKind.SWITCH_CASE_TYPES_NOT_EQUAL);
On 2013/08/06 14:31:36, ahe wrote:
> You don't report what the type is.

Done.

Powered by Google App Engine
This is Rietveld 408576698