File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -104,11 +104,13 @@ const char token_terminators[] = {
104
104
' #'
105
105
};
106
106
107
+ const uint8_t token_terminators_length = sizeof (token_terminators) / sizeof (char );
108
+
107
109
// Note: this is a heuristic as we only use this to distinguish word
108
110
// operators and we don't want to include complex Unicode ranges
109
111
bool is_token_end (int32_t c) {
110
- for (const char & terminator : token_terminators ) {
111
- if (c == terminator ) {
112
+ for (uint8_t i = 0 ; i < token_terminators_length; i++ ) {
113
+ if (c == token_terminators[i] ) {
112
114
return true ;
113
115
}
114
116
}
@@ -598,7 +600,7 @@ bool scan(TSLexer* lexer, const bool* valid_symbols) {
598
600
599
601
extern " C" {
600
602
void * tree_sitter_elixir_external_scanner_create () {
601
- return nullptr ;
603
+ return NULL ;
602
604
}
603
605
604
606
bool tree_sitter_elixir_external_scanner_scan (void * payload, TSLexer* lexer, const bool * valid_symbols) {
You can’t perform that action at this time.
0 commit comments