Removed redundant nullpointer checks in token.cpp
This commit is contained in:
parent
1968b6ffe0
commit
a748678636
|
@ -296,7 +296,7 @@ const Token *Token::linkAt(int index) const
|
|||
if (!tok) {
|
||||
throw InternalError(this, "Internal error. Token::linkAt called with index outside the tokens range.");
|
||||
}
|
||||
return tok ? tok->link() : 0;
|
||||
return tok->link();
|
||||
}
|
||||
|
||||
Token *Token::linkAt(int index)
|
||||
|
@ -305,7 +305,7 @@ Token *Token::linkAt(int index)
|
|||
if (!tok) {
|
||||
throw InternalError(this, "Internal error. Token::linkAt called with index outside the tokens range.");
|
||||
}
|
||||
return tok ? tok->link() : 0;
|
||||
return tok->link();
|
||||
}
|
||||
|
||||
const std::string &Token::strAt(int index) const
|
||||
|
|
Loading…
Reference in New Issue