<
lib.rs:11:21: 11:23 error: expected type, found token LIT_INT_UNSUFFIXED(16i64) lib.rs:11 if foo as int < 16 {}
The solution is of course to parenthesize the cast so it doesn't get parsed as generics, but the error message does not help at all.
This error got a little better:
hello.rs:3:21: 3:22 error: expected type, found `5` hello.rs:3 if i as usize < 5 { ^
Triage: no change.
Closing in favor of #22644.
The solution is of course to parenthesize the cast so it doesn't get parsed as generics, but the error message does not help at all.