mirror of
https://github.com/capstone-engine/capstone.git
synced 2024-11-24 22:19:43 +00:00
ocaml: rename cs_disasm() back to cs_disasm_quick(), which rightly reflects its nature
This commit is contained in:
parent
6dc1dd5ae0
commit
82354b60ba
@ -55,6 +55,7 @@ type opt_value =
|
|||||||
| CS_OPT_SYNTAX_ATT (* X86 ATT asm syntax (CS_OPT_SYNTAX). *)
|
| CS_OPT_SYNTAX_ATT (* X86 ATT asm syntax (CS_OPT_SYNTAX). *)
|
||||||
| CS_OPT_SYNTAX_NOREGNAME (* Prints register name with only number (CS_OPT_SYNTAX) *)
|
| CS_OPT_SYNTAX_NOREGNAME (* Prints register name with only number (CS_OPT_SYNTAX) *)
|
||||||
|
|
||||||
|
|
||||||
type cs_arch =
|
type cs_arch =
|
||||||
| CS_INFO_ARM of cs_arm
|
| CS_INFO_ARM of cs_arm
|
||||||
| CS_INFO_ARM64 of cs_arm64
|
| CS_INFO_ARM64 of cs_arm64
|
||||||
@ -80,7 +81,7 @@ type cs_insn0 = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
external cs_open: arch -> mode list -> Int64.t option = "ocaml_cs_open"
|
external cs_open: arch -> mode list -> Int64.t option = "ocaml_cs_open"
|
||||||
external cs_disasm: arch -> mode list -> string -> Int64.t -> Int64.t -> cs_insn0 list = "ocaml_cs_disasm"
|
external cs_disasm_quick: arch -> mode list -> string -> Int64.t -> Int64.t -> cs_insn0 list = "ocaml_cs_disasm"
|
||||||
external _cs_disasm_internal: arch -> Int64.t -> string -> Int64.t -> Int64.t -> cs_insn0 list = "ocaml_cs_disasm_internal"
|
external _cs_disasm_internal: arch -> Int64.t -> string -> Int64.t -> Int64.t -> cs_insn0 list = "ocaml_cs_disasm_internal"
|
||||||
external cs_reg_name: Int64.t -> int -> string = "ocaml_register_name"
|
external cs_reg_name: Int64.t -> int -> string = "ocaml_register_name"
|
||||||
external cs_insn_name: Int64.t -> int -> string = "ocaml_instruction_name"
|
external cs_insn_name: Int64.t -> int -> string = "ocaml_instruction_name"
|
||||||
|
@ -47,7 +47,7 @@ let print_insn insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment, syntax) = x in
|
let (arch, mode, code, comment, syntax) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter print_insn insns;;
|
List.iter print_insn insns;;
|
||||||
|
@ -93,7 +93,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment) = x in
|
let (arch, mode, code, comment) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
@ -90,7 +90,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment) = x in
|
let (arch, mode, code, comment) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
@ -73,7 +73,7 @@ let print_insn mode arch insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment, syntax) = x in
|
let (arch, mode, code, comment, syntax) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode arch) insns;;
|
List.iter (print_insn mode arch) insns;;
|
||||||
|
@ -67,7 +67,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment) = x in
|
let (arch, mode, code, comment) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
@ -64,7 +64,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment) = x in
|
let (arch, mode, code, comment) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
@ -70,7 +70,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment) = x in
|
let (arch, mode, code, comment) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
@ -72,7 +72,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment) = x in
|
let (arch, mode, code, comment) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
@ -103,7 +103,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment, syntax) = x in
|
let (arch, mode, code, comment, syntax) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
@ -70,7 +70,7 @@ let print_insn mode insn =
|
|||||||
|
|
||||||
let print_arch x =
|
let print_arch x =
|
||||||
let (arch, mode, code, comment) = x in
|
let (arch, mode, code, comment) = x in
|
||||||
let insns = cs_disasm arch mode code 0x1000L 0L in
|
let insns = cs_disasm_quick arch mode code 0x1000L 0L in
|
||||||
printf "*************\n";
|
printf "*************\n";
|
||||||
printf "Platform: %s\n" comment;
|
printf "Platform: %s\n" comment;
|
||||||
List.iter (print_insn mode) insns;;
|
List.iter (print_insn mode) insns;;
|
||||||
|
Loading…
Reference in New Issue
Block a user