Skip to content

Commit

Permalink
Remove use of std::string in test
Browse files Browse the repository at this point in the history
Avoiding using the standard library here
  • Loading branch information
AThousandShips committed Aug 9, 2023
1 parent f7bc653 commit 6ca1432
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tests/servers/rendering/test_shader_preprocessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ bool is_variable_char(unsigned char c) {
}

bool is_operator_char(unsigned char c) {
static const std::string operators = "<>=+-*/";
return operators.find(c) != std::string::npos;
return (c == '*') || (c == '+') || (c == '-') || (c == '/') || ((c >= '<') && (c <= '>'));
}

// Remove unnecessary spaces from a line.
Expand Down

0 comments on commit 6ca1432

Please sign in to comment.