main
Download
14 lines 410 BCModified 2025-09-21 raw
1234567891011121314
// This file defines how to compile optionals and null

#pragma once

#include "../ast.h"
#include "../environment.h"
#include "../stdlib/datatypes.h"
#include "../types.h"

Text_t optional_into_nonnone(type_t *t, Text_t value);
Text_t promote_to_optional(type_t *t, Text_t code);
Text_t compile_none(type_t *t);
Text_t check_none(type_t *t, Text_t value);
Text_t compile_non_optional(env_t *env, ast_t *ast);