Commit Graph

1 Commits

Author SHA1 Message Date
dc672f8485 fix(scanner): address memory safety and correctness issues in C code
- Add len==0 check in set_contains() to prevent buffer overflow
- Add missing stdlib.h include in scanner.c
- Clear heredoc stack properly in deserialize when length==0
- Ensure NUL termination in delimiter deserialization
- Create alloc.c to define ts_current_* symbols for TREE_SITTER_REUSE_ALLOCATOR

All changes tested with full test suite: 61/61 tests passing.

Addresses PR #1 review comments from CodeRabbit.
2026-01-04 15:32:40 +02:00