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 d631f29 commit bd1c615Copy full SHA for bd1c615
src/test/run-pass/expr-if-box.rs
@@ -9,6 +9,12 @@ fn test_box() {
9
check (*res == 100);
10
}
11
12
+fn test_str() {
13
+ auto res = if (true) { "happy" } else { "sad" };
14
+ check (res == "happy");
15
+}
16
+
17
fn main() {
18
test_box();
-}
19
+ test_str();
20
src/test/run-pass/expr-if.rs
@@ -80,11 +80,6 @@ fn test_if_as_block_result() {
80
check (res);
81
82
83
-fn test_str() {
84
- auto res = if (true) { "happy" } else { "sad" };
85
- check (res == "happy");
86
87
-
88
89
test_if();
90
test_else();
@@ -94,5 +89,4 @@ fn main() {
94
test_inferrence();
95
test_if_as_if_condition();
96
91
test_if_as_block_result();
97
- test_str();
98
92
0 commit comments