opcode: less redundant indentation
This commit is contained in:
parent
1fe8282eda
commit
554ba250b9
1 changed files with 135 additions and 132 deletions
|
@ -1,5 +1,4 @@
|
|||
var Opcode = {
|
||||
map: {
|
||||
var ops = {
|
||||
// push value
|
||||
OP_0 : 0,
|
||||
OP_FALSE : 0,
|
||||
|
@ -136,12 +135,16 @@ var Opcode = {
|
|||
OP_PUBKEYHASH : 253,
|
||||
OP_PUBKEY : 254,
|
||||
OP_INVALIDOPCODE : 255
|
||||
},
|
||||
reverseMap: []
|
||||
}
|
||||
|
||||
for(var i in Opcode.map) {
|
||||
Opcode.reverseMap[Opcode.map[i]] = i
|
||||
var reverse = []
|
||||
for (var op in ops) {
|
||||
var code = ops[code]
|
||||
|
||||
reverse[code] = op
|
||||
}
|
||||
|
||||
module.exports = Opcode
|
||||
module.exports = {
|
||||
map: ops,
|
||||
reverseMap: reverse
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue