================
@@ -2454,7 +2480,7 @@ def element_type(self):
         If accessed on a type that is not an array, complex, or vector type, an
         exception will be raised.
         """
-        result = conf.lib.clang_getElementType(self)
+        result = Type.from_result(conf.lib.clang_getElementType(self), (self,))
----------------
DeinAlptraum wrote:

I wonder if we should simplify this further. E.g. instead of passing the result 
of the library function call on `self`, and then `self` separately, should we 
pass just the callable and `self`, and then have the `from_result` function 
call the library function itself?
Would change e.g. the call marked here to 
`Type.from_result(conf.lib.clang_getElementType, self)`

https://github.com/llvm/llvm-project/pull/105490
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to