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

Issue 2755433004: align fasta.PrecedenceInfo.precedence with analyzer.TokenType.precedence (Closed)

Created:
3 years, 9 months ago by danrubel
Modified:
3 years, 9 months ago
CC:
reviews_dartlang.org, dart-fe-team+reviews_google.com
Target Ref:
refs/heads/master
Visibility:
Public.

Description

align fasta.PrecedenceInfo.precedence with analyzer.TokenType.precedence This updates fasta precedence to match analyzer: * '!' 0 --> 15 * '~' 0 --> 15 * '--' 15 --> 16 * '++' 15 --> 16 * '.' 15 --> 16 * '?.' 15 --> 16 * '(' 15 --> 16 * '[' 15 --> 16 And updates analyzer precedence to match fasta: * '--' 15 --> 16 * '++' 15 --> 16 * '[]' 16 --> 0 * '[]=' 16 --> 0 R=ahe@google.com, brianwilkerson@google.com Committed: https://github.com/dart-lang/sdk/commit/d7c4cad542a8314491d13b685312f7926ecfeeee

Patch Set 1 #

Patch Set 2 : increase precedence of --/++ to 16 in fasta and analyzer #

Total comments: 1

Patch Set 3 : change "[]" and "[]=" precedence 16 --> 0 #

Patch Set 4 : fix TokenType.isOperator for "[]" and "[]=" #

Patch Set 5 : fix tilde precedence test #

Total comments: 4

Patch Set 6 : merge #

Patch Set 7 : merge #

Unified diffs Side-by-side diffs Delta from patch set Stats (+204 lines, -13 lines) Patch
M pkg/front_end/lib/src/fasta/scanner/precedence.dart View 1 2 2 chunks +5 lines, -5 lines 0 comments Download
M pkg/front_end/lib/src/scanner/token.dart View 1 2 3 4 chunks +10 lines, -8 lines 0 comments Download
M pkg/front_end/test/scanner_roundtrip_test.dart View 1 2 1 chunk +10 lines, -0 lines 0 comments Download
A tests/language/precedence_test.dart View 1 2 3 4 1 chunk +179 lines, -0 lines 0 comments Download

Messages

Total messages: 13 (4 generated)
danrubel
3 years, 9 months ago (2017-03-15 11:21:22 UTC) #3
ahe
I'm always in trouble when it comes to precedence order. How do we test that ...
3 years, 9 months ago (2017-03-15 12:25:36 UTC) #4
danrubel
On 2017/03/15 12:25:36, ahe wrote: > I'm always in trouble when it comes to precedence ...
3 years, 9 months ago (2017-03-15 13:32:42 UTC) #5
Brian Wilkerson
https://codereview.chromium.org/2755433004/diff/20001/pkg/front_end/lib/src/scanner/token.dart File pkg/front_end/lib/src/scanner/token.dart (right): https://codereview.chromium.org/2755433004/diff/20001/pkg/front_end/lib/src/scanner/token.dart#newcode1012 pkg/front_end/lib/src/scanner/token.dart:1012: const TokenType._('MINUS_MINUS', TokenClass.UNARY_POSTFIX_OPERATOR, '--'); I'm not sure what the ...
3 years, 9 months ago (2017-03-15 13:50:33 UTC) #6
danrubel
Added test and updated precedence per discussions. PTAL.
3 years, 9 months ago (2017-03-18 14:38:36 UTC) #8
Brian Wilkerson
lgtm https://codereview.chromium.org/2755433004/diff/80001/tests/language/precedence_test.dart File tests/language/precedence_test.dart (right): https://codereview.chromium.org/2755433004/diff/80001/tests/language/precedence_test.dart#newcode6 tests/language/precedence_test.dart:6: library precedence_test; Unless the library directive is useful ...
3 years, 9 months ago (2017-03-18 16:11:28 UTC) #9
ahe
lgtm https://codereview.chromium.org/2755433004/diff/80001/tests/language/precedence_test.dart File tests/language/precedence_test.dart (right): https://codereview.chromium.org/2755433004/diff/80001/tests/language/precedence_test.dart#newcode20 tests/language/precedence_test.dart:20: void testBang() { I don't feel this is ...
3 years, 9 months ago (2017-03-20 12:19:46 UTC) #10
danrubel
https://codereview.chromium.org/2755433004/diff/80001/tests/language/precedence_test.dart File tests/language/precedence_test.dart (right): https://codereview.chromium.org/2755433004/diff/80001/tests/language/precedence_test.dart#newcode6 tests/language/precedence_test.dart:6: library precedence_test; On 2017/03/18 16:11:28, Brian Wilkerson wrote: > ...
3 years, 9 months ago (2017-03-20 13:06:49 UTC) #11
danrubel
3 years, 9 months ago (2017-03-20 16:47:40 UTC) #13
Message was sent while issue was closed.
Committed patchset #6 (id:100001) manually as
d7c4cad542a8314491d13b685312f7926ecfeeee (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698