Skip to content

Instantly share code, notes, and snippets.

@haranicle
Created February 16, 2016 10:07
Show Gist options
  • Save haranicle/0a464da3cac029aa0b76 to your computer and use it in GitHub Desktop.
Save haranicle/0a464da3cac029aa0b76 to your computer and use it in GitHub Desktop.
これもダメと #CodePiece
protocol P1 {
}
protocol P2 {
typealias A = P1 // Selfでも同様
}
let arr1: Array<P1> = []
let arr2: Array<P2> = [] // Protocol 'P2' can only be used as a generic constraint because it has Self or associated type requirements
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment