You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A-parserArea: Syntactic analysis / parsing of Rust source code (to an AST) as done by `rustc_parse`B-unstableBlocker: Implemented in the nightly compiler and unstable.C-bugCategory: This is a bug.F-try_blocks`#![feature(try_blocks)]`
Simple demo that won't compile but should be a type error:
#![feature(try_blocks)]fndemo(){return try {4};}
But it gives a parse error instead:
error: expected one of `.`, `;`, `?`, `}`, or an operator, found reserved keyword `try`
--> src/lib.rs:3:12
|
3 | return try { 4 };
| ^^^ expected one of `.`, `;`, `?`, `}`, or an operator
error: aborting due to previous error
(It works if you put parens, like return (try { 4 });)
A-parserArea: Syntactic analysis / parsing of Rust source code (to an AST) as done by `rustc_parse`B-unstableBlocker: Implemented in the nightly compiler and unstable.C-bugCategory: This is a bug.F-try_blocks`#![feature(try_blocks)]`
Activity
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov
Rollup merge of rust-lang#76274 - scottmcm:fix-76271, r=petrochenkov