This website requires JavaScript.
Explore
Help
Sign in
bjoernager
/
rust
Watch
1
Fork
You've already forked rust
0
Code
Activity
72f8043d44
rust
/
src
/
test
/
ui
/
placement-syntax.rs
7 lines
109 B
Rust
Raw
Normal View
History
Unescape
Escape
Suggest correct comparison against negative literal When parsing as emplacement syntax (`x<-1`), suggest the correct syntax for comparison against a negative value (`x< -1`).
2018-06-28 14:58:54 -07:00
fn
main
(
)
{
let
x
=
-
5
;
Update tests
2019-05-13 22:19:19 +01:00
if
x
<
-
1
{
//~ ERROR expected `{`, found `<-`
Suggest correct comparison against negative literal When parsing as emplacement syntax (`x<-1`), suggest the correct syntax for comparison against a negative value (`x< -1`).
2018-06-28 14:58:54 -07:00
println!
(
"
ok
"
)
;
}
}
Copy permalink