https://github.com/TApplencourt updated https://github.com/llvm/llvm-project/pull/162882
>From 674bdfb5d0160bf637cce069fdf03c465c81b287 Mon Sep 17 00:00:00 2001 From: tapplencourt <[email protected]> Date: Fri, 10 Oct 2025 16:39:51 +0000 Subject: [PATCH 1/2] Add isFunctionInlined support in Python Binding --- clang/bindings/python/clang/cindex.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/clang/bindings/python/clang/cindex.py b/clang/bindings/python/clang/cindex.py index 80140d2787608..015667b4decd9 100644 --- a/clang/bindings/python/clang/cindex.py +++ b/clang/bindings/python/clang/cindex.py @@ -2362,6 +2362,13 @@ def get_bitfield_width(self) -> int: """ return conf.lib.clang_getFieldDeclBitWidth(self) # type: ignore [no-any-return] + def is_function_inlined(self) -> bool: + """ + Check if the function is inlined + """ + assert self.kind == TypeKind.FUNCTIONPROTO + return bool(conf.lib.clang_Cursor_isFunctionInlined(self)) # type: ignore [no-any-return] + @cursor_null_guard def has_attrs(self) -> bool: """ @@ -4308,6 +4315,7 @@ def set_property(self, property, value): ("clang_Cursor_isAnonymous", [Cursor], bool), ("clang_Cursor_isAnonymousRecordDecl", [Cursor], bool), ("clang_Cursor_isBitField", [Cursor], bool), + ("clang_Cursor_isFunctionInlined", [Cursor], c_uint), ("clang_Location_isInSystemHeader", [SourceLocation], bool), ("clang_PrintingPolicy_dispose", [PrintingPolicy]), ("clang_PrintingPolicy_getProperty", [PrintingPolicy, c_int], c_uint), >From 1300ae39e26309f9e64971a616d3690436b13631 Mon Sep 17 00:00:00 2001 From: tapplencourt <[email protected]> Date: Fri, 10 Oct 2025 16:39:51 +0000 Subject: [PATCH 2/2] Add isFunctionInlined support in Python Binding --- clang/bindings/python/clang/cindex.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/clang/bindings/python/clang/cindex.py b/clang/bindings/python/clang/cindex.py index 015667b4decd9..99ca72fccc26f 100644 --- a/clang/bindings/python/clang/cindex.py +++ b/clang/bindings/python/clang/cindex.py @@ -2369,6 +2369,14 @@ def is_function_inlined(self) -> bool: assert self.kind == TypeKind.FUNCTIONPROTO return bool(conf.lib.clang_Cursor_isFunctionInlined(self)) # type: ignore [no-any-return] + @cursor_null_guard + def is_function_inlined(self) -> bool: + """ + Check if the function is inlined + """ + assert self.kind == TypeKind.FUNCTIONPROTO + return bool(conf.lib.clang_Cursor_isFunctionInlined(self)) # type: ignore [no-any-return] + @cursor_null_guard def has_attrs(self) -> bool: """ _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
