diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2025-03-25 15:40:59 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2025-03-25 15:40:59 -0400 |
| commit | 1f9147187d66e95a0ffedd4d5595ec98646b5fe1 (patch) | |
| tree | 14281e5cbde8e15fae63953b72844fb1a11d6f73 /src/types.c | |
| parent | d88d8648dc7802fbeac2f28dc5f2ef8fdfe1a9e4 (diff) | |
Make docstring tests use an actual expression AST instead of text
matching
Diffstat (limited to 'src/types.c')
| -rw-r--r-- | src/types.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/types.c b/src/types.c index 506850e8..7e5f262d 100644 --- a/src/types.c +++ b/src/types.c @@ -285,6 +285,7 @@ PUREFUNC bool has_heap_memory(type_t *t) PUREFUNC bool has_stack_memory(type_t *t) { + if (!t) return false; switch (t->tag) { case PointerType: return Match(t, PointerType)->is_stack; case OptionalType: return has_stack_memory(Match(t, OptionalType)->type); |
