Extension of constructed generic type in Swift

前端 未结 7 732
闹比i
闹比i 2020-12-02 13:56

Is it possible to extend an generic class for a specialised/constructed generic type? I would like to extend Int Arrays with a method to calculate the sum of its elements.

7条回答
提交回复
热议问题