We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 413d97f commit 9375204Copy full SHA for 9375204
src/test/compile-fail/if-without-else-result.rs
@@ -0,0 +1,6 @@
1
+// error-pattern:`if` without `else` can not produce a result
2
+
3
+fn main() {
4
+ let a = if true { true };
5
+ log a;
6
+}
0 commit comments