Closed Mx-Iris closed 10 months ago
Hey, thanks for checking out the toolkit!
Unfortunately macros cannot know what a typealias expands to, so that case could not be handled without passing the macro extra information (as in making the macro take an optional argument where the dev can specify the underlying type of the completion handler).
However, optional completion handlers (without typealiases) could definitely be supported! (because all of the required type information is present in the syntax). The example macros aren’t very comprehensive because they’re only intended to demonstrate usage of the toolkit, but I’d happily accept a PR.
I think my previous comment should answer your question, but feel free to reopen the issue if you have any related concerns
I'm using AddAsyncMacro from the example, and it seems to only get the direct function type, if I use Optional or Typealias I get errors