Skip to content

Commit

Permalink
fix bindings (python/java) and tests after the last change on the typ…
Browse files Browse the repository at this point in the history
…e of imm of cs_arm64_op
  • Loading branch information
aquynh committed Nov 17, 2014
1 parent 56128da commit faa925a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion bindings/java/capstone/Arm64.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public List getFieldOrder() {

public static class OpValue extends Union {
public int reg;
public int imm;
public long imm;
public double fp;
public MemType mem;
public int pstate;
Expand Down
2 changes: 1 addition & 1 deletion bindings/python/capstone/arm64.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Arm64OpShift(ctypes.Structure):
class Arm64OpValue(ctypes.Union):
_fields_ = (
('reg', ctypes.c_uint),
('imm', ctypes.c_int32),
('imm', ctypes.c_int64),
('fp', ctypes.c_double),
('mem', Arm64OpMem),
('pstate', ctypes.c_int),
Expand Down
4 changes: 2 additions & 2 deletions tests/test_arm64.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ static void print_insn_detail(cs_insn *ins)
printf("\t\toperands[%u].type: REG = %s\n", i, cs_reg_name(handle, op->reg));
break;
case ARM64_OP_IMM:
printf("\t\toperands[%u].type: IMM = 0x%x\n", i, op->imm);
printf("\t\toperands[%u].type: IMM = 0x%"PRIx64 "\n", i, op->imm);
break;
case ARM64_OP_FP:
printf("\t\toperands[%u].type: FP = %f\n", i, op->fp);
Expand All @@ -67,7 +67,7 @@ static void print_insn_detail(cs_insn *ins)

break;
case ARM64_OP_CIMM:
printf("\t\toperands[%u].type: C-IMM = %u\n", i, op->imm);
printf("\t\toperands[%u].type: C-IMM = %u\n", i, (int)op->imm);
break;
case ARM64_OP_REG_MRS:
printf("\t\toperands[%u].type: REG_MRS = 0x%x\n", i, op->reg);
Expand Down

0 comments on commit faa925a

Please sign in to comment.