base.swift 203 B

1234567891011
  1. func id<T>(_ some: T) -> T {
  2. return some
  3. }
  4. func const<T, U>(_ value: U) -> (T) -> U {
  5. return { (_: T) -> U in value }
  6. }
  7. func const<U>(_ value: U) -> () -> U {
  8. return { () -> U in value }
  9. }