Versions in this module Expand all Collapse all v1 v1.0.0 Mar 10, 2026 Changes in this version + const Magic + const VersionMajor + const VersionMinor + const VersionPatch + var FullVersion = uint32(VersionMajor<<16 | VersionMinor<<8 | VersionPatch) + type BoolConstant struct + Value bool + func (c *BoolConstant) Type() ConstantType + type Bytecode struct + Constants []Constant + LineNumberTable []LineInfo + MainFunc int + SourceFile string + type CharConstant struct + Value rune + func (c *CharConstant) Type() ConstantType + type ClassConstant struct + Interfaces []string + Methods map[string]int + Name string + StaticMethods map[string]int + SuperClass string + func (c *ClassConstant) Type() ConstantType + type Constant interface + Type func() ConstantType + type ConstantType byte + const ConstBool + const ConstChar + const ConstClass + const ConstFloat + const ConstFunction + const ConstInt + const ConstInterface + const ConstNil + const ConstString + type ErrInvalidConstantType struct + Type ConstantType + func (e *ErrInvalidConstantType) Error() string + type FloatConstant struct + Value float64 + func (c *FloatConstant) Type() ConstantType + type FunctionConstant struct + AccessModifier uint8 + DefaultValues []int + Flags uint8 + Instructions []byte + IsStatic bool + IsVariadic bool + Name string + NumLocals int + NumParameters int + func (c *FunctionConstant) Type() ConstantType + type Header struct + CodeSize uint32 + ConstCount uint32 + Flags uint32 + LineCount uint32 + Magic uint32 + Reserved [16]byte + Version uint32 + type IntConstant struct + Value int64 + func (c *IntConstant) Type() ConstantType + type InterfaceConstant struct + Methods map[string][]string + Name string + func (c *InterfaceConstant) Type() ConstantType + type LineInfo struct + Column int + Line int + Offset int + type NilConstant struct + func (c *NilConstant) Type() ConstantType + type Reader struct + func NewReader(r io.Reader) *Reader + func NewReaderFromBytes(data []byte) *Reader + func (r *Reader) Read() (*Bytecode, error) + type StringConstant struct + Value string + func (c *StringConstant) Type() ConstantType + type Writer struct + func NewWriter() *Writer + func (w *Writer) Bytes() []byte + func (w *Writer) Write(bc *Bytecode) error + func (w *Writer) WriteTo(writer io.Writer) (int64, error)