Skip to content

Commit 9820bd0

Browse files
Rollup merge of rust-lang#37059 - jfirebaugh:unused-RangeExpression, r=alexcrichton
Remove TypeOrigin::RangeExpression This variant became unused in rust-lang#30884.
2 parents 79d3d26 + 16a979c commit 9820bd0

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

src/librustc/infer/mod.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -199,9 +199,6 @@ pub enum TypeOrigin {
199199
// Computing common supertype of an if expression with no else counter-part
200200
IfExpressionWithNoElse(Span),
201201

202-
// Computing common supertype in a range expression
203-
RangeExpression(Span),
204-
205202
// `where a == b`
206203
EquatePredicate(Span),
207204

@@ -231,7 +228,6 @@ impl TypeOrigin {
231228
},
232229
&TypeOrigin::IfExpression(_) => "if and else have incompatible types",
233230
&TypeOrigin::IfExpressionWithNoElse(_) => "if may be missing an else clause",
234-
&TypeOrigin::RangeExpression(_) => "start and end of range have incompatible types",
235231
&TypeOrigin::EquatePredicate(_) => "equality predicate not satisfied",
236232
&TypeOrigin::MainFunctionType(_) => "main function has wrong type",
237233
&TypeOrigin::StartFunctionType(_) => "start function has wrong type",
@@ -251,7 +247,6 @@ impl TypeOrigin {
251247
&TypeOrigin::MatchExpressionArm(..) => "match arms have compatible types",
252248
&TypeOrigin::IfExpression(_) => "if and else have compatible types",
253249
&TypeOrigin::IfExpressionWithNoElse(_) => "if missing an else returns ()",
254-
&TypeOrigin::RangeExpression(_) => "start and end of range have compatible types",
255250
&TypeOrigin::EquatePredicate(_) => "equality where clause is satisfied",
256251
&TypeOrigin::MainFunctionType(_) => "`main` function has the correct type",
257252
&TypeOrigin::StartFunctionType(_) => "`start` function has the correct type",
@@ -1755,7 +1750,6 @@ impl TypeOrigin {
17551750
TypeOrigin::MatchExpressionArm(match_span, ..) => match_span,
17561751
TypeOrigin::IfExpression(span) => span,
17571752
TypeOrigin::IfExpressionWithNoElse(span) => span,
1758-
TypeOrigin::RangeExpression(span) => span,
17591753
TypeOrigin::EquatePredicate(span) => span,
17601754
TypeOrigin::MainFunctionType(span) => span,
17611755
TypeOrigin::StartFunctionType(span) => span,

0 commit comments

Comments
 (0)