================
@@ -3050,17 +3050,15 @@ def __ne__(self, other: object) -> bool:
return not self.__eq__(other)
-## CIndex Objects ##
+## Opaque Clang Objects ##
-# CIndex objects (derived from ClangObject) are essentially lightweight
-# wrappers attached to some underlying object, which is exposed via CIndex as
-# a void*.
-
-
-class ClangObject:
+class OpaqueClangObject:
"""
- A helper for Clang objects. This class helps act as an intermediary for
- the ctypes library and the Clang CIndex library.
+ A helper for Python objects that mirror opaque types of the C API.
+ It stores opaque pointer returned by the C API, and implements
+ `from_param` function, allowing Python object to be implicitly converted
+ to the stored opaque pointer when it is passed as an argument to the
+ C API.
----------------
DeinAlptraum wrote:
Slight wording/grammer fix suggestion:
```suggestion
A helper for Python objects that mirror opaque types of the C API.
It stores an opaque pointer returned by the C API, and implements a
`from_param` method, allowing Python objects to be implicitly converted
to the stored opaque pointer when it is passed as an argument to the
C API.
```
https://github.com/llvm/llvm-project/pull/229374
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits