Ingen beskrivning

any.go 348B

1234567891011121314151617
  1. package main
  2. // ANY OMIT
  3. // any is a type alias of empty interface
  4. type any = interface{}
  5. // ANY OMIT
  6. // PRINT OMIT
  7. // Print prints the elements of any slice.
  8. // Print has a type parameter T and has a single (non-type)
  9. // parameter s which is a slice of that type parameter.
  10. func Print[T interface{}](s []T) {
  11. // same as above
  12. }
  13. // PRINT OMIT