The following enum works fine without any error.
enum EnumOptions: CaseIterable {
case none
case mild
case moderate
case severe
case unmeasurable
}
When I try to add an associated value to one of the cases, it throws the following error "Type 'EnumOptions' does not conform to protocol 'CaseIterable'. Do you want to add protocol stubs?"
enum OedemaOptions: CaseIterable {
case none
case mild
case moderate
case severe
case unmeasurable(Int)
}
After adding stubs,
enum OedemaOptions: CaseIterable {
typealias AllCases = <#type#>
case none
case mild
case moderate
case severe
case unmeasurable(Int)
What should be filled up in the placeholder to make the Enum conform to CaseIterable, since there is only 1 case with associated value and not all the cases?