質問編集履歴
2
訂正
test
CHANGED
File without changes
|
test
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
|
7
7
|
|
8
8
|
|
9
|
-
enum Status
|
9
|
+
enum Status {
|
10
10
|
|
11
11
|
case A
|
12
12
|
|
@@ -18,7 +18,7 @@
|
|
18
18
|
|
19
19
|
|
20
20
|
|
21
|
-
var statsu: Status = .A
|
21
|
+
var statsu: Status? = .A
|
22
22
|
|
23
23
|
|
24
24
|
|
1
訂正
test
CHANGED
File without changes
|
test
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
|
7
7
|
|
8
8
|
|
9
|
-
enum Status {
|
9
|
+
enum Status: Int {
|
10
10
|
|
11
11
|
case A
|
12
12
|
|
@@ -24,7 +24,7 @@
|
|
24
24
|
|
25
25
|
func segmentedControlDidTap(_ sender: UISegmentedControl) {
|
26
26
|
|
27
|
-
status = sender.selectedSegmentIndex
|
27
|
+
status = Status(rawValue: sender.selectedSegmentIndex)
|
28
28
|
|
29
29
|
}
|
30
30
|
|