[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: PR title should mention somewhere that only used functions are registered. https://github.com/llvm/llvm-project/pull/140015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Jannick Kremer via cfe-commits
https://github.com/DeinAlptraum updated https://github.com/llvm/llvm-project/pull/140015 >From c3c0adfe4a7dce3568a81594588be53d761b5980 Mon Sep 17 00:00:00 2001 From: Jannick Kremer Date: Thu, 15 May 2025 15:58:00 +0900 Subject: [PATCH 1/4] [libclang/python] Ensure all library functions are re

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/140015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Jannick Kremer via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Jannick Kremer via cfe-commits
https://github.com/DeinAlptraum edited https://github.com/llvm/llvm-project/pull/140015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Jannick Kremer via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/140015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/140015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll commented: I https://github.com/llvm/llvm-project/pull/140015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,17 @@ +import os + +from clang.cindex import Config, conf, FUNCTION_LIST + +if "CLANG_LIBRARY_PATH" in os.environ: +Config.set_library_path(os.environ["CLANG_LIBRARY_PATH"]) + +import unittest + + +class TestIndex(unittest.TestCase): +def test_functions_register

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Jannick Kremer via cfe-commits
DeinAlptraum wrote: @Endilll This PR adds the missing functions to `FUNCTION_LIST`, as well as a test that checks for completeness, as discussed here: https://github.com/llvm/llvm-project/pull/138103#discussion_r2085977138 The test is unfortunately not 100% foolproof, since as noted `clang_get

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Jannick Kremer via cfe-commits
https://github.com/DeinAlptraum updated https://github.com/llvm/llvm-project/pull/140015 Rate limit ยท GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,s

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Jannick Kremer (DeinAlptraum) Changes Add a few library functions that were not previously registered to the `CDLL` object. The current behavior relies on the default `restype` to work. Add a test to check that all library functions are p

[clang] [libclang/python] Ensure all library functions are registered (PR #140015)

2025-05-15 Thread Jannick Kremer via cfe-commits
https://github.com/DeinAlptraum created https://github.com/llvm/llvm-project/pull/140015 Add a few library functions that were not previously registered to the `CDLL` object. The current behavior relies on the default `restype` to work. Add a test to check that all library functions are proper