File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -54,13 +54,13 @@ class ConstFanClassCorrect: ConstFan {
54
54
}
55
55
56
56
class ConstFanClassWrong1: ConstFan {
57
- static _const let v: String // expected-error {{_const let should be initialized with a compile-time literal}}
57
+ static _const let v: String // expected-error {{_const let should be initialized with a literal value }}
58
58
// expected-error@-1 {{'static let' declaration requires an initializer expression or an explicitly stated getter}}
59
59
// expected-note@-2 {{add an initializer to silence this error}}
60
60
}
61
61
62
62
class ConstFanClassWrong2: ConstFan {
63
- static _const let v: String = " \( v) " // expected-error {{_const let should be initialized with a compile-time literal}}
63
+ static _const let v: String = " \( v) " // expected-error {{_const let should be initialized with a literal value }}
64
64
}
65
65
66
66
class ConstFanClassWrong3: ConstFan {
@@ -69,7 +69,7 @@ class ConstFanClassWrong3: ConstFan {
69
69
70
70
class ConstFanClassWrong4: ConstFan {
71
71
static func giveMeString() -> String { return " " }
72
- static _const let v: String = giveMeString() // expected-error {{_const let should be initialized with a compile-time literal}}
72
+ static _const let v: String = giveMeString() // expected-error {{_const let should be initialized with a literal value }}
73
73
}
74
74
75
75
_const let globalConst = 3
You can’t perform that action at this time.
0 commit comments