aboutsummaryrefslogtreecommitdiff
path: root/types.c
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2025-03-15 14:22:11 -0400
committerBruce Hill <bruce@bruce-hill.com>2025-03-15 14:22:11 -0400
commitf51acef40e8297d7bd41b774413aa8331ca946ed (patch)
tree56aa02541d60beb3ece496fed2c11afd3ae942f3 /types.c
parent7a2653501310825e02d99d51fb4b9f1aacc75214 (diff)
Overhaul of Path so it uses root and array of components instead of
stringly typed
Diffstat (limited to 'types.c')
-rw-r--r--types.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/types.c b/types.c
index 358a729e..eaecad2f 100644
--- a/types.c
+++ b/types.c
@@ -494,6 +494,7 @@ PUREFUNC size_t unpadded_struct_size(type_t *t)
PUREFUNC size_t type_size(type_t *t)
{
if (t == THREAD_TYPE) return sizeof(pthread_t*);
+ if (t == PATH_TYPE) return sizeof(Path_t);
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wswitch-default"
switch (t->tag) {
@@ -579,6 +580,7 @@ PUREFUNC size_t type_size(type_t *t)
PUREFUNC size_t type_align(type_t *t)
{
if (t == THREAD_TYPE) return __alignof__(pthread_t*);
+ if (t == PATH_TYPE) return __alignof__(Path_t);
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wswitch-default"
switch (t->tag) {