-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix crash when optional semicolon is used in a long single-line lambda
Summary: Whenever a lambda: 1. Has a single statement 2. Can't be collapsed due to length 3. Uses an optional semicolon It fails with: ``` com.google.googlejavaformat.FormattingError: 16:5: error: expected token: ';'; generated } instead ``` This fixes that by slightly reworking how statements are visited. Reviewed By: hick209 Differential Revision: D32708821 fbshipit-source-id: d3f84dbfdea9e17c1e3919b4918e8f6c09cb6ade
- Loading branch information
1 parent
187551e
commit 582f0f1
Showing
2 changed files
with
13 additions
and
3 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
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