Skip to content

Commit

Permalink
Adapt to Clang16's base class name printing policy
Browse files Browse the repository at this point in the history
  • Loading branch information
Gnimuc committed Aug 18, 2024
1 parent e598a1f commit 0227723
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions deps/generate_wrapper.jl
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,10 @@ function object_decl_handler(ctx::BindgenContext, classdecl::CLCursor)::Tuple{Un
end

# handle simple inheritance
if length(children(classdecl)) > 1 && kind(children(classdecl)[1]) == Clang.CXCursor_CXXBaseSpecifier

if startswith(get_full_name(children(classdecl)[1]), "class ")
base_class = split(get_full_name(children(classdecl)[1]), "class ")[2]
subnodes = children(classdecl)
if length(subnodes) > 1 && kind(subnodes[1]) == Clang.CXCursor_CXXBaseSpecifier
base_class = get_full_name(subnodes[1])
if !isempty(base_class)

ctx.outputSupertypes *= "template<> struct SuperType<$full_name> { typedef $base_class type; };\n"

Expand Down

0 comments on commit 0227723

Please sign in to comment.