Skip to content

Commit

Permalink
Update test suite to nightly-2024-05-15
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed May 15, 2024
1 parent 4edbb8d commit cea7a1e
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions tests/common/eq.rs
Original file line number Diff line number Diff line change
Expand Up @@ -684,15 +684,14 @@ impl SpanlessEq for TokenKind {
_ => false,
},
(TokenKind::Interpolated(this), TokenKind::Interpolated(other)) => {
let (this, this_span) = this.as_ref();
let (other, other_span) = other.as_ref();
SpanlessEq::eq(this_span, other_span)
&& match (this, other) {
(Nonterminal::NtExpr(this), Nonterminal::NtExpr(other)) => {
SpanlessEq::eq(this, other)
}
_ => this == other,
let this = this.as_ref();
let other = other.as_ref();
match (this, other) {
(Nonterminal::NtExpr(this), Nonterminal::NtExpr(other)) => {
SpanlessEq::eq(this, other)
}
_ => this == other,
}
}
_ => self == other,
}
Expand Down Expand Up @@ -801,7 +800,7 @@ fn is_escaped_literal_token(token: &Token, unescaped: Symbol) -> bool {
Token {
kind: TokenKind::Interpolated(nonterminal),
span: _,
} => match &nonterminal.0 {
} => match nonterminal.as_ref() {
Nonterminal::NtExpr(expr) => match &expr.kind {
ExprKind::Lit(lit) => is_escaped_lit(lit, unescaped),
_ => false,
Expand Down

0 comments on commit cea7a1e

Please sign in to comment.