mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-11 04:41:42 +00:00
Merge pull request #12399 from lioncash/erasing
General: Make use of std::erase_if/std::erase where applicable
This commit is contained in:
commit
8cbb2c2e44
11 changed files with 65 additions and 84 deletions
|
@ -963,11 +963,9 @@ static ParseResult ParseComplexExpression(const std::string& str)
|
|||
|
||||
void RemoveInertTokens(std::vector<Token>* tokens)
|
||||
{
|
||||
tokens->erase(std::remove_if(tokens->begin(), tokens->end(),
|
||||
[](const Token& tok) {
|
||||
return tok.type == TOK_COMMENT || tok.type == TOK_WHITESPACE;
|
||||
}),
|
||||
tokens->end());
|
||||
std::erase_if(*tokens, [](const Token& tok) {
|
||||
return tok.type == TOK_COMMENT || tok.type == TOK_WHITESPACE;
|
||||
});
|
||||
}
|
||||
|
||||
static std::unique_ptr<Expression> ParseBarewordExpression(const std::string& str)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue