Add missing opcodes

the basicTest.m file, compiled by the Winamp3 compiler (and perhaps others) output these opcodes which are unknown to the decompiler. I _think_ this is what they are supposed to be.
This commit is contained in:
Jordan Eldredge 2019-07-11 20:57:18 -07:00
parent f94fcf2579
commit deb8289d6a

View file

@ -6,7 +6,7 @@ const COMMANDS = {
short: "popTo",
arg: "var",
in: "0",
out: "0"
out: "0",
// note in fact popTo takes one
// argument but it is not visible to the parser because popTo
// is always at the start of a function
@ -29,7 +29,7 @@ const COMMANDS = {
name: "ret",
short: "return",
in: "1",
out: "0" // note: we claim that return
out: "0", // note: we claim that return
// pops one argument from the stack, which ist not the full truth.
},
@ -56,6 +56,10 @@ const COMMANDS = {
"80": { name: "logAnd", short: "&&", in: "2", out: "1" },
"81": { name: "logOr", short: "||", in: "2", out: "1" },
// The decompiler has these next two as 90 and 91.
"88": { name: "lshift", short: "<<", in: "2", out: "1" },
"89": { name: "rshift", short: ">>", in: "2", out: "1" },
"90": { name: "lshift", short: "<<", in: "2", out: "1" },
"91": { name: "rshift", short: ">>", in: "2", out: "1" },
@ -66,7 +70,7 @@ const COMMANDS = {
"300": { name: "blockStart", short: "{", in: "0", out: "0" },
"301": { name: "blockEnd", short: "}", in: "0", out: "0" }
"301": { name: "blockEnd", short: "}", in: "0", out: "0" },
};
module.exports = { COMMANDS };