mirror of
https://github.com/realm/SwiftLint.git
synced 2026-06-06 20:18:40 +00:00
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com> Co-authored-by: Danny Mösch <danny.moesch@icloud.com>
21 lines
642 B
Swift
21 lines
642 B
Swift
import SwiftLintCore
|
|
|
|
@AutoConfigParser
|
|
struct ForceUnwrappingConfiguration: SeverityBasedRuleConfiguration {
|
|
@ConfigurationElement(key: "severity")
|
|
private(set) var severityConfiguration = SeverityConfiguration<Parent>(.warning)
|
|
@ConfigurationElement(
|
|
key: "ignored_literal_argument_functions",
|
|
postprocessor: {
|
|
$0.formUnion([
|
|
"URL(string:)",
|
|
"NSURL(string:)",
|
|
"UIImage(named:)",
|
|
"NSImage(named:)",
|
|
"Data(hexString:)",
|
|
])
|
|
}
|
|
)
|
|
private(set) var ignoredLiteralArgumentFunctions = Set<String>()
|
|
}
|