[gobject-introspection] giscanner.ast: map uintptr_t and intptr_t



commit 9076ff19faba9c5f1d5fa50acc3d892faafe9a14
Author: Marc-André Lureau <marcandre lureau redhat com>
Date:   Thu Oct 28 19:56:41 2021 +0400

    giscanner.ast: map uintptr_t and intptr_t
    
    Those types should map by definition to guintptr and gintptr.
    
    They are fairly common in Rust cbindgen projects, which maps
    usize->uintptr_t for ex.
    
    Signed-off-by: Marc-André Lureau <marcandre lureau redhat com>

 giscanner/ast.py | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/giscanner/ast.py b/giscanner/ast.py
index c94ee768..b760c71d 100644
--- a/giscanner/ast.py
+++ b/giscanner/ast.py
@@ -344,6 +344,8 @@ type_names['FILE*'] = TYPE_ANY
 # integers it's easy enough to expand them.
 type_names['size_t'] = type_names['gsize']
 type_names['ssize_t'] = type_names['gssize']
+type_names['uintptr_t'] = type_names['guintptr']
+type_names['intptr_t'] = type_names['gintptr']
 type_names['time_t'] = TYPE_LONG
 type_names['off_t'] = type_names['gsize']
 type_names['pid_t'] = TYPE_INT


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]