Sign in
fuchsia
/
third_party
/
rust
/
346aec9b02f3c74f3fce97fd6bda24709d220e49
/
.
/
src
/
test
/
ui
/
try-block
/
try-block-in-edition2015.rs
blob: 00964297308093ac51df1a9bdf8ca28de3d76868 [
file
] [
log
] [
blame
]
// compile-flags: --edition 2015
pub
fn
main
()
{
let
try_result
:
Option
<
_
>
=
try
{
//~^ ERROR expected struct, variant or union type, found macro `try`
let
x
=
5
;
//~ ERROR expected identifier, found keyword
x
};
assert_eq
!(
try_result
,
Some
(
5
));
}