fixing my mistake NOT <--> BYTE switch

This commit is contained in:
romanman 2014-12-04 09:29:49 +01:00
parent a2b00ff8dd
commit afc8dafab1
2 changed files with 11 additions and 11 deletions

View File

@ -60,10 +60,10 @@ public enum OpCode {
OR(0x17, 2),
/** (0x18) Bitwise XOR operation */
XOR(0x18, 2),
/** (0x19) Retrieve single byte from word */
BYTE(0x19, 2),
/** (0x1a) Bitwise NOT operationr */
NOT(0x1a, 1),
/** (0x19) Bitwise NOT operationr */
NOT(0x19, 1),
/** (0x1a) Retrieve single byte from word */
BYTE(0x1a, 2),
/* Cryptographic Operations */

View File

@ -614,7 +614,7 @@ public class VMTest {
public void testBYTE_1() {
VM vm = new VM();
program = new Program(Hex.decode("65AABBCCDDEEFF601E19"), invoke);
program = new Program(Hex.decode("65AABBCCDDEEFF601E1A"), invoke);
String expected = "00000000000000000000000000000000000000000000000000000000000000EE";
vm.step(program);
@ -628,7 +628,7 @@ public class VMTest {
public void testBYTE_2() {
VM vm = new VM();
program = new Program(Hex.decode("65AABBCCDDEEFF602019"), invoke);
program = new Program(Hex.decode("65AABBCCDDEEFF60201A"), invoke);
String expected = "0000000000000000000000000000000000000000000000000000000000000000";
vm.step(program);
@ -642,7 +642,7 @@ public class VMTest {
public void testBYTE_3() {
VM vm = new VM();
program = new Program(Hex.decode("65AABBCCDDEE3A601F19"), invoke);
program = new Program(Hex.decode("65AABBCCDDEE3A601F1A"), invoke);
String expected = "000000000000000000000000000000000000000000000000000000000000003A";
vm.step(program);
@ -657,7 +657,7 @@ public class VMTest {
public void testBYTE_4() {
VM vm = new VM();
program = new Program(Hex.decode("65AABBCCDDEE3A19"), invoke);
program = new Program(Hex.decode("65AABBCCDDEE3A1A"), invoke);
try {
vm.step(program);
vm.step(program);
@ -1005,7 +1005,7 @@ public class VMTest {
public void testNOT_1() {
VM vm = new VM();
program = new Program(Hex.decode("60011a"), invoke);
program = new Program(Hex.decode("600119"), invoke);
String expected = "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE";
vm.step(program);
@ -1018,7 +1018,7 @@ public class VMTest {
public void testNOT_2() {
VM vm = new VM();
program = new Program(Hex.decode("61A0031a"), invoke);
program = new Program(Hex.decode("61A00319"), invoke);
String expected = "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5FFC";
vm.step(program);
@ -1031,7 +1031,7 @@ public class VMTest {
public void testNOT_3() {
VM vm = new VM();
program = new Program(Hex.decode("6100001a"), invoke);
program = new Program(Hex.decode("61000019"), invoke);
String expected = "0000000000000000000000000000000000000000000000000000000000000000";
vm.step(program);