I have set of protocols:
protocol SpaceInterpolatorProtocol {
associatedtype Axis: SpaceAxisProtocol
associatedtype Spot: SpaceAxisSpotProtocol
associatedtype Vertex: SpaceVertexProtocol
....
}
protocol SpaceAxisProtocol: Equatable & Hashable {
associatedtype CoordUnit: FloatingPoint
...
}
protocol SpaceVertexProtocol:Hashable {
associatedtype Spot: SpaceAxisSpotProtocol
...
}
protocol SpaceAxisSpotProtocol : Hashable {
associatedtype Axis: SpaceAxisProtocol
...
}
Is it possible to restrict SpaceInterpolatorProtocol definition that
Axis == Spot.Axis
Axis.CoordUnit == Spot.Axis.CoordUnit
Vertex.Spot == Spot
and not to use where
in all protocol extensions?