Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[flow] Fix parsing of arrows in conditional exprs in parens (#13655)
- Loading branch information
1 parent
9d0aa1e
commit e721f61
Showing
22 changed files
with
739 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
packages/babel-parser/test/fixtures/flow/arrows-in-ternaries/issue-13644/input.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
(a ? (b = c) : d => e); // a ? (b = c) : (d => e) | ||
(a ? (b += c) : d => e); // a ? (b += c) : (d => e) | ||
|
||
(a ? (b = c) : d => e : f); // a ? ((b = c): d => e) : f | ||
(a ? (b += c) : d => e : f); // ((a ? (b += c) : (d => e)) : f) | ||
|
||
(a ? b => (c = d) : e => f); // a ? (b => (c = d)) : (e => f) | ||
(a ? b => (c += d) : e => f); // a ? (b => (c += d)) : (e => f) | ||
|
||
(a ? b => (c = d) : e => f : g); // a ? (b => ((c = d): e => f)) : g | ||
(a ? b => (c += d) : e => f : g); // ((a ? (b => (c += d)) : (e => f)) : g) |
Oops, something went wrong.