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

Issue 2465263002: Always store the type of a conditional expression on the node. (Closed)

Created:
4 years, 1 month ago by asgerf
Modified:
4 years, 1 month ago
CC:
dart-kernel+reviews_google.com
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Always store the type of a conditional expressions on the node. Previously, the type of a conditional expression could be omitted if one of the arms was just a null literal. This was meant to simplify translation into kernel, but wasn't really worth it in terms of complexity, and it does not work well for types that carry nullability information. BUG= R=ahe@google.com Committed: https://github.com/dart-lang/kernel/commit/c227e785a14e04f1688d75ad4d0f12b0be6b850f

Patch Set 1 #

Total comments: 2

Patch Set 2 : Add copyright #

Patch Set 3 : Merge in master #

Patch Set 4 : Update handling of conditional expression in type checker #

Patch Set 5 : Update test expectation #

Unified diffs Side-by-side diffs Delta from patch set Stats (+120 lines, -40 lines) Patch
M lib/analyzer/ast_from_analyzer.dart View 9 chunks +14 lines, -10 lines 0 comments Download
M lib/ast.dart View 1 2 1 chunk +3 lines, -14 lines 0 comments Download
M lib/frontend/accessors.dart View 3 chunks +6 lines, -5 lines 0 comments Download
M lib/type_checker.dart View 1 2 3 1 chunk +3 lines, -11 lines 0 comments Download
A testcases/input/null_aware.dart View 1 1 chunk +20 lines, -0 lines 0 comments Download
A testcases/spec-mode/null_aware.baseline.txt View 1 chunk +22 lines, -0 lines 0 comments Download
A testcases/strong-mode/null_aware.baseline.txt View 1 2 3 4 1 chunk +30 lines, -0 lines 0 comments Download
A testcases/type-propagation/null_aware.baseline.txt View 1 chunk +22 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (4 generated)
asgerf
4 years, 1 month ago (2016-11-01 13:43:20 UTC) #3
ahe
lgtm https://codereview.chromium.org/2465263002/diff/1/testcases/input/null_aware.dart File testcases/input/null_aware.dart (right): https://codereview.chromium.org/2465263002/diff/1/testcases/input/null_aware.dart#newcode1 testcases/input/null_aware.dart:1: class Foo { No copyright.
4 years, 1 month ago (2016-11-01 13:45:00 UTC) #5
asgerf
https://codereview.chromium.org/2465263002/diff/1/testcases/input/null_aware.dart File testcases/input/null_aware.dart (right): https://codereview.chromium.org/2465263002/diff/1/testcases/input/null_aware.dart#newcode1 testcases/input/null_aware.dart:1: class Foo { On 2016/11/01 13:45:00, ahe wrote: > ...
4 years, 1 month ago (2016-11-01 14:34:49 UTC) #6
asgerf
4 years, 1 month ago (2016-11-01 15:04:17 UTC) #8
Message was sent while issue was closed.
Committed patchset #5 (id:80001) manually as
c227e785a14e04f1688d75ad4d0f12b0be6b850f (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698