unavailable
SW-W1014Unimplemented functions in Swift code can cause confusion for users who may think the function is available to use. This can lead to runtime errors and unexpected behavior.
To prevent this issue, it's recommended to mark any unimplemented functions as unavailable using the @available
attribute.
This communicates to users that the function is not yet implemented and should not be used.
func unimplementedFunction() -> String {
fatalError("This function is not yet implemented")
}
@available(*, unavailable, message: "This function is not yet implemented")
func unimplementedFunction() -> String {
fatalError("This function is not yet implemented")
}