Files
c2/v0/ast.h
T
2026-04-25 15:28:33 +02:00

34 lines
584 B
C

/**
* Holds the AST model
*/
#ifndef AST_H
#define AST_H
#include <stdbool.h>
#include <stddef.h>
typedef struct {
/// @brief The name of the module being imported.
char* module_name;
/// @brief Whether the import is public or not.
bool is_public;
} ImportDeclaration;
/**
* The top-level model.
* Every file matches an entire Module.
*/
typedef struct {
/// @brief The name of the module.
char* name;
/// @brief The list of imports in the module.
ImportDeclaration* imports;
/// @brief The number of imports in the module.
size_t import_count;
} Module;
#endif