We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e9fd4cc commit 78efd96Copy full SHA for 78efd96
lib/src/parser.c
@@ -397,10 +397,12 @@ static unsigned ts_parser__external_scanner_serialize(
397
self->lexer.debug_buffer
398
);
399
} else {
400
- return self->language->external_scanner.serialize(
+ uint32_t length = self->language->external_scanner.serialize(
401
self->external_scanner_payload,
402
403
404
+ assert(length <= TREE_SITTER_SERIALIZATION_BUFFER_SIZE);
405
+ return length;
406
}
407
408
0 commit comments