Merge branch 'cs_insn_const' of https://github.com/obs1dium/capstone into next
diff --git a/cs.c b/cs.c
index 3f51d8f..40eb326 100644
--- a/cs.c
+++ b/cs.c
@@ -653,7 +653,7 @@
 }
 
 CAPSTONE_EXPORT
-bool cs_insn_group(csh ud, cs_insn *insn, unsigned int group_id)
+bool cs_insn_group(csh ud, const cs_insn *insn, unsigned int group_id)
 {
 	struct cs_struct *handle;
 	if (!ud)
@@ -680,7 +680,7 @@
 }
 
 CAPSTONE_EXPORT
-bool cs_reg_read(csh ud, cs_insn *insn, unsigned int reg_id)
+bool cs_reg_read(csh ud, const cs_insn *insn, unsigned int reg_id)
 {
 	struct cs_struct *handle;
 	if (!ud)
@@ -707,7 +707,7 @@
 }
 
 CAPSTONE_EXPORT
-bool cs_reg_write(csh ud, cs_insn *insn, unsigned int reg_id)
+bool cs_reg_write(csh ud, const cs_insn *insn, unsigned int reg_id)
 {
 	struct cs_struct *handle;
 	if (!ud)
@@ -734,7 +734,7 @@
 }
 
 CAPSTONE_EXPORT
-int cs_op_count(csh ud, cs_insn *insn, unsigned int op_type)
+int cs_op_count(csh ud, const cs_insn *insn, unsigned int op_type)
 {
 	struct cs_struct *handle;
 	unsigned int count = 0, i;
@@ -810,7 +810,7 @@
 }
 
 CAPSTONE_EXPORT
-int cs_op_index(csh ud, cs_insn *insn, unsigned int op_type,
+int cs_op_index(csh ud, const cs_insn *insn, unsigned int op_type,
 		unsigned int post)
 {
 	struct cs_struct *handle;
diff --git a/include/capstone.h b/include/capstone.h
index 7518eaa..8abb882 100644
--- a/include/capstone.h
+++ b/include/capstone.h
@@ -438,7 +438,7 @@
  @return: true if this instruction indeed belongs to aboved group, or false otherwise.
 */
 CAPSTONE_EXPORT
-bool cs_insn_group(csh handle, cs_insn *insn, unsigned int group_id);
+bool cs_insn_group(csh handle, const cs_insn *insn, unsigned int group_id);
 
 /*
  Check if a disassembled instruction IMPLICITLY used a particular register.
@@ -456,7 +456,7 @@
  @return: true if this instruction indeed implicitly used aboved register, or false otherwise.
 */
 CAPSTONE_EXPORT
-bool cs_reg_read(csh handle, cs_insn *insn, unsigned int reg_id);
+bool cs_reg_read(csh handle, const cs_insn *insn, unsigned int reg_id);
 
 /*
  Check if a disassembled instruction IMPLICITLY modified a particular register.
@@ -474,7 +474,7 @@
  @return: true if this instruction indeed implicitly modified aboved register, or false otherwise.
 */
 CAPSTONE_EXPORT
-bool cs_reg_write(csh handle, cs_insn *insn, unsigned int reg_id);
+bool cs_reg_write(csh handle, const cs_insn *insn, unsigned int reg_id);
 
 /*
  Count the number of operands of a given type.
@@ -490,7 +490,7 @@
  or -1 on failure.
 */
 CAPSTONE_EXPORT
-int cs_op_count(csh handle, cs_insn *insn, unsigned int op_type);
+int cs_op_count(csh handle, const cs_insn *insn, unsigned int op_type);
 
 /*
  Retrieve the position of operand of given type in <arch>.operands[] array.
@@ -509,7 +509,7 @@
  in instruction @insn, or -1 on failure.
 */
 CAPSTONE_EXPORT
-int cs_op_index(csh handle, cs_insn *insn, unsigned int op_type,
+int cs_op_index(csh handle, const cs_insn *insn, unsigned int op_type,
 		unsigned int position);
 
 #ifdef __cplusplus