binding ObjC method with accept or return generalized types like NSArray<NEPacket *>
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
What did you expect to see?
What did you see instead?
Method not found, which is expected.
This issue is more like feature request/discussion. Are there any plans to provide at least minimal support of generics in Obj C? There are some very nice iOS apis which expect NSArrays of concrete objects and it's sad, that we cannot bind them?
I would like to try to create a POC myself, so maybe someone else has done some investigation, have some thoughts etc?
As there is no generics concept in golang, so I see a biggest problem here is how to distinquish lets say NSArray<NEPacket *> from NSArray<NSDate *>
Current import which looks like this "Objc/Foundation/NSArray" generates golang interface NSArray with methods which are not typed (like Count) which is fine. So perhaps we can do something like
"ObjC/Foundation/NEPacket_NSArray" to generate distinct go interfaces with methods which accept or return NEPacket type parameters? I know it looks ugly, but I didn't find out any other options how to encode type name of array into interface as only to as part of interface name.
Any help, ideas, suggestions would be much appreciated
The text was updated successfully, but these errors were encountered: