You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
funcprintGenericInfo<T>(_value: T) {
lettype = type(of: value)
print("'\(value)' of type '\(type)'")
}
protocolP {}
extensionString: P {}
letstringAsP: P = "Hello!"printGenericInfo(stringAsP)
// 'Hello!' of type 'P'
Fails in this way when attempted to copy verbatim to try out:
Additional Detail from JIRA
md5: 4034e73111f733319a978b85785e968b
Issue Description:
Just a small typo / mistake in documentation snippet. Explained below, I'll provide a PR fixing this shortly.
Where:
Documentation of`type(of)`: https://developer.apple.com/documentation/swift/2885064-type
Which snippet:
Fails in this way when attempted to copy verbatim to try out:
Will provide a small PR fixing this shortly.
The text was updated successfully, but these errors were encountered: