diff options
| author | Kimplul <kimi.h.kuparinen@gmail.com> | 2023-03-26 02:01:04 +0200 |
|---|---|---|
| committer | Kimplul <kimi.h.kuparinen@gmail.com> | 2023-03-26 02:21:50 +0200 |
| commit | 373728f324b82d305748cfe3c853053fe2a9f761 (patch) | |
| tree | 92e50af6527e981bcbf6c0fe6c44622bd3861cc7 /src/debug.c | |
| parent | cc3cf3353f23dd2f87412d42f8c3d52f873711dd (diff) | |
| download | ek-373728f324b82d305748cfe3c853053fe2a9f761.tar.gz ek-373728f324b82d305748cfe3c853053fe2a9f761.zip | |
struct member naming
Diffstat (limited to 'src/debug.c')
| -rw-r--r-- | src/debug.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/debug.c b/src/debug.c index 2bb4af4..566da42 100644 --- a/src/debug.c +++ b/src/debug.c @@ -191,6 +191,21 @@ static void _type_str(FILE *fp, struct ast_node *type) } break; } + + case AST_TYPE_STRUCT: { + struct ast_node *struc_id = type->_type.struc.struc; + fprintf(fp, "%s", struc_id->_id.id); + + struct ast_node *impls = type->_type.struc.impls; + if (impls) { + fprintf(fp, " ("); + while (impls) { + _type_str(fp, impls); + impls = impls->next; + } + fprintf(fp, ")"); + } + } } _type_str(fp, type->_type.next); |
