blob: 6d713d6f1a6f9b339dbf3864f40060ac43b74e82 [file] [log] [blame] [view] [edit]
Generic structs can be declared to hold generic types, and generic functions
can be declared to take generic types as arguments.
Generics must be specialized when used; but, because of type inference,
annotation is usually not required. When that's not the case, structs can be
specialized via type annotation, and functions can be specialized passing the
generic arguments using this syntax `::<T, U, ..>`.
{generics.play}