From b5f727e000f187063e2d3c8ba31146761df49ed8 Mon Sep 17 00:00:00 2001 From: billow Date: Tue, 11 Jun 2024 00:20:39 +0800 Subject: [PATCH] fix python --- bindings/const_generator.py | 2 +- bindings/python/capstone/xtensa_const.py | 11 +---------- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/bindings/const_generator.py b/bindings/const_generator.py index 7278c30739..206a6d5bae 100644 --- a/bindings/const_generator.py +++ b/bindings/const_generator.py @@ -224,7 +224,7 @@ def write_enum_extra_options(outfile, templ, enum, enum_values): outfile.write((templ["line_format"] % (name, value)).encode("utf-8")) -def is_with_prefix(x: str, prefix: str | List[str], target: str): +def is_with_prefix(x, prefix, target): if target in excluded_prefixes and any( x.startswith(excl_pre) for excl_pre in excluded_prefixes[target] ): diff --git a/bindings/python/capstone/xtensa_const.py b/bindings/python/capstone/xtensa_const.py index 7b38c308ff..a7328f1142 100644 --- a/bindings/python/capstone/xtensa_const.py +++ b/bindings/python/capstone/xtensa_const.py @@ -1,13 +1,4 @@ -from . import ( - CS_OP_INVALID, - CS_OP_REG, - CS_OP_IMM, - CS_OP_FP, - CS_OP_PRED, - CS_OP_SPECIAL, - CS_OP_MEM, -) - +from . import CS_OP_INVALID, CS_OP_REG, CS_OP_IMM, CS_OP_FP, CS_OP_PRED, CS_OP_SPECIAL, CS_OP_MEM # For Capstone Engine. AUTO-GENERATED FILE, DO NOT EDIT [xtensa_const.py] Xtensa_REG_INVALID = 0