Method ambiguities from destructor wrappers
When running Aqua.jl on my package with Aqua.test_all(ImGuiTestEngine) I get a bazillion method ambiguity warnings like this:
Ambiguity #11169
__delete(arg1::Union{Ptr{Nothing}, CxxWrap.CxxWrapCore.CxxPtr{<:ImGuiTestEngine.lib.ImGuiTestItemInfo}}) @ ImGuiTestEngine.lib ~/.julia/packages/CxxWrap/eWADG/src/CxxWrap.jl:668
__delete(arg1::Union{Ptr{Nothing}, CxxWrap.CxxWrapCore.CxxPtr{<:CxxWrap.StdLib.StdUnorderedMultiset{UInt8}}}) @ CxxWrap.StdLib ~/.julia/packages/CxxWrap/eWADG/src/CxxWrap.jl:668
Possible fix, define
__delete(::Union{Ptr{Nothing}, CxxWrap.CxxWrapCore.CxxPtr{Union{}}})
Unfortunately the package (https://github.com/JuliaImGui/ImGuiTestEngine.jl) is not easily installable right now because it requires an unmerged JLL, so I don't have an easy reproducer :smiling_face_with_tear: Anyway, it's not particularly urgent for me.
I'm including @barche, as it looks like an issue with CxxWrap.
I don't get where the ambiguity is. Looking at imgui_te_engine.h L295, I understand (I missed the union with ImGuiTestEngine.lib.ImGuiTestItemInfo is a struct and has therefore no relation with StdUnorderedMultiset. @JamesWrigley do you have more insights on what can make the choice between the two methods ambiguous? Maybe, if you can explicitly call CxxWrap.CxxWrapCore.__delete with ImGuiTestItemInfo you will get a Julia error message giving more information.Ptr{Nothing})
BTW, here are the generated wrappers: https://github.com/Gnimuc/CImGui.jl/tree/1.90.8/cimgui-pack/test_engine/src
Closing the issue, since it is related to CxxWrap. @JamesWrigley , @barche, I let you open an issue in CxxWrap, it it is still relevant.
Sorry, I completely missed this. @JamesWrigley if you are still having this problem, please create an issue with a small test that reproduces the problem in CxxWrap.jl.