mirror of
https://github.com/dlang-community/D-Scanner.git
synced 2025-04-27 22:00:17 +03:00
Fix: Token#opEquals(TokenType) never returns false
opEquals(TokenType) never returns false because its argument shadows the corresponding field.
This commit is contained in:
parent
aa406c76f2
commit
ec57809ec9
1 changed files with 1 additions and 1 deletions
|
@ -174,7 +174,7 @@ struct Token
|
|||
/**
|
||||
* Checks to see if the token is of the given type.
|
||||
*/
|
||||
bool opEquals(TokenType type) const { return type == type; }
|
||||
bool opEquals(TokenType type) const { return this.type == type; }
|
||||
|
||||
/**
|
||||
* Comparison operator orders tokens by start index.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue