Skip to main content

Crate endbasic_core

Crate endbasic_core 

Source
Expand description

The EndBASIC core language parser, compiler, and virtual machine.

Structs§

AnyValueSyntax
Syntax specification for a parameter that accepts any scalar type.
CallableMetadata
Representation of a callable’s metadata.
CallableMetadataBuilder
Builder pattern for constructing a callable’s metadata.
Compiler
Compiler context.
ExitCode
Program exit code carried by the END instruction.
GlobalDef
Descriptor for a single global variable to be pre-defined before compilation.
Image
Representation of a compiled EndBASIC program.
InvalidExitCodeError
Error to indicate an invalid END exit code.
Limits
Limits for VM execution resources.
LineCol
A position within a source stream, represented as line and column numbers.
OptionalValueSyntax
Syntax specification for an optional scalar parameter.
RegisterRef
An immutable reference to a variable (register) in the register file, carrying its type for runtime validation of dereference operations.
RegisterRefMut
A mutable reference to a variable (register) in the register file, carrying its type for runtime validation of dereference and set operations.
RepeatedSyntax
Syntax specification for a repeated parameter.
RequiredRefSyntax
Syntax specification for a required reference parameter.
RequiredValueSyntax
Syntax specification for a required scalar parameter.
Scope
Arguments provided to a callable during its execution.
SymbolKey
The key of a symbol in the symbols table.
U24
An unsigned integer constrained to 24 bits.
Vm
Virtual machine for EndBASIC program execution.

Enums§

ArgSep
Types of separators between arguments to a BuiltinCall.
ArgSepSyntax
Specifies the expected argument separator in a callable’s syntax.
CallError
Error types for callable execution.
CompilerError
Errors that can occur during compilation.
ConstantDatum
A typed scalar value, used both in the compile-time constant pool and as a return value when inspecting global variables after execution.
ExprType
Represents type of an expression.
GetGlobalError
Error returned when a global variable access encounters a type or shape mismatch.
GlobalDefKind
Kind of a pre-defined global variable.
RepeatedTypeSyntax
Specifies the type constraints for a repeated parameter.
SingularArgSyntax
Syntax specification for a non-repeated argument.
StopReason
Representation of termination states from program execution.
UpcallError
Error type for uncaught upcall failures.
VarArgTag
Tags used as integer register values to identify the type stored in another register at runtime.

Traits§

Callable
A trait to define a callable that is executed by a Machine.

Functions§

only_metadata
Extracts the metadata of all provided upcalls.

Type Aliases§

CallResult
Result type for callable execution.
GetGlobalResult
Result type for global variable access operations.