hylo icon indicating copy to clipboard operation
hylo copied to clipboard

Implement exhaustivity checks

Open dabrahams opened this issue 8 months ago • 1 comments

On requirements-machine branch:

public fun force_unwrap<T>(x: sink Optional<T>) -> T {
  match x { // error: incompatible types '{}' and 'T'
    // let r: T { return r }
    _ { fatal_error("force unwrapping nil.") }
  }
}

dabrahams avatar Jun 21 '24 08:06 dabrahams