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
Copy file name to clipboardExpand all lines: CHANGELOG.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,16 +35,16 @@ Swift Next
35
35
funcboxes() -> [Box<Wrapped.Element>] where Wrapped:Sequence { ... }
36
36
}
37
37
```
38
-
Because contextual `where` clauses are effectively visibility constraints, overrides adopting this feature must be at least as visible as the overridden method:
38
+
Because contextual `where` clauses are effectively visibility constraints, overrides adopting this feature must be at least as visible as the overridden method. In practice this implies any instance of `Derived` that can access `Base.foo` must also be able to access `Derived.foo`.
39
39
40
40
```swift
41
41
classBase<T> {
42
42
funcfoo() where T ==Int { ... }
43
43
}
44
44
45
-
classDerived<T>: Base<T> {
46
-
// OK, <T where T: Equatable> has broader visibility than <T where T == Int>
47
-
overridefuncfoo() whereT:Equatable { ... }
45
+
classDerived<U>: Base<U> {
46
+
// OK, <U where U: Equatable> has broader visibility than <T where T == Int>
0 commit comments