File tree 1 file changed +0
-30
lines changed
1 file changed +0
-30
lines changed Original file line number Diff line number Diff line change @@ -72,36 +72,6 @@ fn foo(x: Option<String>) {
72
72
```
73
73
"## ,
74
74
75
- E0003 : r##"
76
- #### Note: this error code is no longer emitted by the compiler.
77
-
78
- Not-a-Number (NaN) values cannot be compared for equality and hence can never
79
- match the input to a match expression. So, the following will not compile:
80
-
81
- ```compile_fail
82
- const NAN: f32 = 0.0 / 0.0;
83
-
84
- let number = 0.1f32;
85
-
86
- match number {
87
- NAN => { /* ... */ },
88
- _ => {}
89
- }
90
- ```
91
-
92
- To match against NaN values, you should instead use the `is_nan()` method in a
93
- guard, like so:
94
-
95
- ```
96
- let number = 0.1f32;
97
-
98
- match number {
99
- x if x.is_nan() => { /* ... */ }
100
- _ => {}
101
- }
102
- ```
103
- "## ,
104
-
105
75
E0004 : r##"
106
76
This error indicates that the compiler cannot guarantee a matching pattern for
107
77
one or more possible inputs to a match expression. Guaranteed matches are
You can’t perform that action at this time.
0 commit comments