Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SWIFT

Type Constraints in Swift Generics

func addition<T: Numeric>(num1: T, num2: T) {
  ...
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #Type #Constraints #Swift #Generics
ADD COMMENT
Topic
Name
4+8 =