Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Collect unclosed delimiters in parent parser
- Loading branch information
Showing
4 changed files
with
45 additions
and
35 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,39 @@ | ||
error: incorrect close delimiter: `}` | ||
--> $DIR/token-error-correct-3.rs:19:9 | ||
| | ||
LL | if !is_directory(path.as_ref()) { | ||
| - close delimiter possibly meant for this | ||
LL | //~^ ERROR cannot find function `is_directory` | ||
LL | callback(path.as_ref(); | ||
| - un-closed delimiter | ||
... | ||
LL | } else { | ||
| ^ incorrect close delimiter | ||
|
||
error: expected one of `)`, `,`, `.`, `?`, or an operator, found `;` | ||
--> $DIR/token-error-correct-3.rs:15:35 | ||
| | ||
LL | callback(path.as_ref(); | ||
| ^ expected one of `)`, `,`, `.`, `?`, or an operator here | ||
| - ^ | ||
| | | | ||
| | help: `)` may belong here | ||
| unclosed delimiter | ||
|
||
error: expected one of `.`, `;`, `?`, `}`, or an operator, found `)` | ||
--> $DIR/token-error-correct-3.rs:19:9 | ||
| | ||
LL | fs::create_dir_all(path.as_ref()).map(|()| true) | ||
| - expected one of `.`, `;`, `?`, `}`, or an operator here | ||
LL | //~^ ERROR mismatched types | ||
LL | } else { | ||
| ^ unexpected token | ||
|
||
error[E0425]: cannot find function `is_directory` in this scope | ||
--> $DIR/token-error-correct-3.rs:13:13 | ||
| | ||
LL | if !is_directory(path.as_ref()) { | ||
| ^^^^^^^^^^^^ not found in this scope | ||
|
||
error[E0057]: this function takes 1 parameter but 2 parameters were supplied | ||
--> $DIR/token-error-correct-3.rs:15:13 | ||
error[E0308]: mismatched types | ||
--> $DIR/token-error-correct-3.rs:17:13 | ||
| | ||
LL | fs::create_dir_all(path.as_ref()).map(|()| true) | ||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^- help: try adding a semicolon: `;` | ||
| | | ||
| expected (), found enum `std::result::Result` | ||
| | ||
LL | / callback(path.as_ref(); | ||
LL | | //~^ ERROR expected one of | ||
LL | | //~| ERROR this function takes 1 parameter but 2 parameters were supplied | ||
LL | | fs::create_dir_all(path.as_ref()).map(|()| true) | ||
LL | | } else { | ||
| |_________^ expected 1 parameter | ||
= note: expected type `()` | ||
found type `std::result::Result<bool, std::io::Error>` | ||
|
||
error: aborting due to 4 previous errors | ||
|
||
Some errors occurred: E0057, E0425. | ||
For more information about an error, try `rustc --explain E0057`. | ||
Some errors occurred: E0308, E0425. | ||
For more information about an error, try `rustc --explain E0308`. |