Closed halleysfifthinc closed 7 months ago
Hello @halleysfifthinc . This PR is still marked as WIP. Are you still working on it? What remains to be done to consider it for merging?
Hey sorry for the delayed response. I had marked as draft because there were some cases that produced incorrect wrappers, and I never got around to producing MWEs to test against. IIRC, there were some edge cases where signature transformation wasn't correct, and where typename
weren't being added.
Thanks Allen for the update and for the contribution. Don't hesitate to open a new PR if you improve the code to handle the corner cases.
While working on wrapping a template heavy C++ library, I noticed several issues relating to the output of input and return argument types.
typedef
s weren't being accessed via theWrappedType
variable and/or prefaced withtypename
. (All the class localtypedef
s in the library I am wrapping were dependent on template parameters, I don't know if the existing behavior would have been alright for independenttypedef
s.)fix_template_types
wasn't being called on input argument types, leading to more of the abovesignature()
used the template varname (i.e.WrappedType
) leading to incorrectly printed signatures in theDEBUG_MSG
s as well as not matching veto's correctly (e.g. the actual signature in the veto file would not match whatsignature()
generated and therefore be wrapped).WrappedType
instead of the actual class/namespace, leading to e.g."WrappedType!updAs"
instead of"Static!Vec!updAs"
.Examples of all the fixes: