mirror of
https://github.com/captbaritone/webamp.git
synced 2026-08-03 15:34:25 +00:00
Unwrap program
This commit is contained in:
parent
d30e0a6f5f
commit
7b3026e5fb
2 changed files with 4 additions and 3 deletions
|
|
@ -134,8 +134,7 @@ function Debugger({ maki }) {
|
|||
|
||||
const nextValue = React.useCallback(
|
||||
value => {
|
||||
const { i, stack, program } = value;
|
||||
const { variables, commands } = program;
|
||||
const { i, stack, variables, commands } = value;
|
||||
dispatch({
|
||||
type: "STEPPED",
|
||||
variables,
|
||||
|
|
|
|||
|
|
@ -35,7 +35,9 @@ function* interpret(start, program, stack = []) {
|
|||
let i = start;
|
||||
while (i < commands.length) {
|
||||
const command = commands[i];
|
||||
yield { i, command, stack, variables, program };
|
||||
{
|
||||
yield { i, command, stack, variables, commands };
|
||||
}
|
||||
|
||||
switch (command.opcode) {
|
||||
// push
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue