Unnecessary error when declaring extension to type with @available
annotation
#61135
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
type checker
Area → compiler: Semantic analysis
Describe the bug
Declaring extensions to types probably should inherit the same availability as the type itself.
Steps To Reproduce
I expect the following code to compile with no issues:
Expected behavior
The functions declared in the extension are only available on iOS 13.0 and forward without needing to duplicate the
@available
annotation.Actual behavior
Environment (please fill out the following information)
The text was updated successfully, but these errors were encountered: