Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Frame ¶
type Frame struct {
IP int
Vars map[string]value.Value // Local scope
Fn *value.ScriptFunction // Hàm đang được thực thi
Defers []*value.ScriptFunction // Deferred functions
}
Frame đại diện cho một khung thực thi (Activation Record)
type Runtime ¶
type Runtime struct {
Bytecode []byte
Constants []value.Value
Stack []value.Value
Vars map[string]value.Value // Module/Global scope
Globals map[string]value.Value // Engine Builtins
Frames []Frame // Call Stack
FrameIdx int // Hiện tại đang ở Frame nào
Energy uint64 // Năng lượng tiêu thụ
Spawner func(s *value.ScriptFunction)
}
func (*Runtime) Defer ¶
func (vm *Runtime) Defer(fn *value.ScriptFunction)
func (*Runtime) ExecuteLambda ¶
Click to show internal directories.
Click to hide internal directories.