Skip to content

Commit e1eab98

Browse files
authored
Merge pull request #2087 from dtolnay/rightarrow
Allow end of expr before `->`
2 parents 5631c74 + 5345ee5 commit e1eab98

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎src/op.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ pub(crate) mod parsing {
123123
input.parse().map(BinOp::Ge)
124124
} else if input.peek(Token![+]) {
125125
input.parse().map(BinOp::Add)
126-
} else if input.peek(Token![-]) {
126+
} else if input.peek(Token![-]) && !input.peek(Token![->]) {
127127
input.parse().map(BinOp::Sub)
128128
} else if input.peek(Token![*]) {
129129
input.parse().map(BinOp::Mul)

0 commit comments

Comments
 (0)