https://github.com/DeinAlptraum created https://github.com/llvm/llvm-project/pull/138135
None >From 257a5e923fee29df8c546b84875a64c43c994c04 Mon Sep 17 00:00:00 2001 From: Jannick Kremer <jannick.kre...@mailbox.org> Date: Thu, 1 May 2025 23:00:23 +0900 Subject: [PATCH] [libclang/python] Remove compatibility workaround for briefComment --- clang/bindings/python/clang/cindex.py | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/clang/bindings/python/clang/cindex.py b/clang/bindings/python/clang/cindex.py index e4a731b1d57fa..2b0a1db04821e 100644 --- a/clang/bindings/python/clang/cindex.py +++ b/clang/bindings/python/clang/cindex.py @@ -2980,11 +2980,7 @@ def availability(self): @property def briefComment(self): - if conf.function_exists("clang_getCompletionBriefComment"): - return _CXString.from_result( - conf.lib.clang_getCompletionBriefComment(self.obj) - ) - return "" + return _CXString.from_result(conf.lib.clang_getCompletionBriefComment(self.obj)) def __repr__(self): return ( @@ -4264,14 +4260,6 @@ def get_cindex_library(self) -> CDLL: return library - def function_exists(self, name: str) -> bool: - try: - getattr(self.lib, name) - except AttributeError: - return False - - return True - conf = Config() _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits