compiler, runtime, common: (Initial) Support For extern Declarations

Especially FFI

Signed-off-by: Will Hawkins <hawkinsw@obs.cr>
This commit is contained in:
Will Hawkins
2026-04-23 06:07:07 -04:00
parent 74fead1eba
commit f2bd53ce5f
17 changed files with 693 additions and 247 deletions
+5 -1
View File
@@ -39,9 +39,13 @@ public protocol CompilableType {
}
public protocol CompilableDeclaration {
/// Info
///
/// Extensions should update the context with the newly declared item _unless_
/// they are in an extern context (``CompilerContext.extern_context``).
static func Compile(
node: Node, withContext context: CompilerContext
) -> Result<(P4DataType, CompilerContext)?>
) -> Result<(Declaration, CompilerContext)?>
}
public protocol Compilable<T> {