Skip to content

Commit b882da1

Browse files
authored
Merge pull request #1512 from nmay231/main
fix(options3): panic when not matching to avoid false positives
2 parents 9ffcab0 + 3ecb47f commit b882da1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

exercises/options/options3.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ fn main() {
1313

1414
match y {
1515
Some(p) => println!("Co-ordinates are {},{} ", p.x, p.y),
16-
_ => println!("no match"),
16+
_ => panic!("no match!"),
1717
}
1818
y; // Fix without deleting this line.
1919
}

0 commit comments

Comments
 (0)