-
Notifications
You must be signed in to change notification settings - Fork 10.6k
Open
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.
Description
| Previous ID | SR-12395 |
| Radar | rdar://problem/60832868 |
| Original Reporter | cukier (JIRA User) |
| Type | Bug |
Environment
Xcode Version 11.4 beta 3 (11N132i)
Additional Detail from JIRA
| Votes | 0 |
| Component/s | |
| Labels | Bug |
| Assignee | None |
| Priority | Medium |
md5: b589a50929b998bd5fc09f8ee2142706
Issue Description:
if you have
typealias Zzz = FloatingPoint
protocol Proto {
func hello<T: Zzz>() -> T
}
struct Foo: Proto {
}and use a fixit to add protocol stubs, you get
func hello<T>() -> T where T : FloatingPoint {
<#code#>
}which doesn't use the shorthand type constraint syntax, and doesn't use the typealias.
I would've expected fixit to insert the following text:
func hello<T: Zzz>() -> T {
<#code#>
}Metadata
Metadata
Assignees
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.