diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/AttributesConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/AttributesConfiguration.swift index b2916aefc1..e9a6fe06b9 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/AttributesConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/AttributesConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct AttributesConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct AttributesConfiguration: SeverityBasedRuleConfiguration { typealias Parent = AttributesRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/BlanketDisableCommandConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/BlanketDisableCommandConfiguration.swift index f422a7fc59..b7bc5e1d31 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/BlanketDisableCommandConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/BlanketDisableCommandConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct BlanketDisableCommandConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct BlanketDisableCommandConfiguration: SeverityBasedRuleConfiguration { typealias Parent = BlanketDisableCommandRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CollectionAlignmentConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CollectionAlignmentConfiguration.swift index 51bd4c433c..0838689139 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CollectionAlignmentConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CollectionAlignmentConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct CollectionAlignmentConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct CollectionAlignmentConfiguration: SeverityBasedRuleConfiguration { typealias Parent = CollectionAlignmentRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ColonConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ColonConfiguration.swift index f563e9cf22..ee0379a0a7 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ColonConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ColonConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ColonConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ColonConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ColonRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ComputedAccessorsOrderConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ComputedAccessorsOrderConfiguration.swift index 506917b368..01a3a2e3eb 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ComputedAccessorsOrderConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ComputedAccessorsOrderConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ComputedAccessorsOrderConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ComputedAccessorsOrderConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ComputedAccessorsOrderRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ConditionalReturnsOnNewlineConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ConditionalReturnsOnNewlineConfiguration.swift index 1151f1137b..2a44156d46 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ConditionalReturnsOnNewlineConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ConditionalReturnsOnNewlineConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ConditionalReturnsOnNewlineConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ConditionalReturnsOnNewlineConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ConditionalReturnsOnNewlineRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CyclomaticComplexityConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CyclomaticComplexityConfiguration.swift index d66add4901..46cc15cc75 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CyclomaticComplexityConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/CyclomaticComplexityConfiguration.swift @@ -2,7 +2,7 @@ import SourceKittenFramework import SwiftLintCore @AutoApply -struct CyclomaticComplexityConfiguration: RuleConfiguration, Equatable { +struct CyclomaticComplexityConfiguration: RuleConfiguration { typealias Parent = CyclomaticComplexityRule private static let defaultComplexityStatements: Set = [ diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DeploymentTargetConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DeploymentTargetConfiguration.swift index ce1236abef..ca8b32a157 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DeploymentTargetConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DeploymentTargetConfiguration.swift @@ -1,4 +1,4 @@ -struct DeploymentTargetConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct DeploymentTargetConfiguration: SeverityBasedRuleConfiguration { typealias Parent = DeploymentTargetRule enum Platform: String { diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DiscouragedDirectInitConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DiscouragedDirectInitConfiguration.swift index 856b8df5bf..160006e4a5 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DiscouragedDirectInitConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/DiscouragedDirectInitConfiguration.swift @@ -4,7 +4,7 @@ import SwiftLintCore // swiftlint:disable let_var_whitespace @AutoApply -struct DiscouragedDirectInitConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct DiscouragedDirectInitConfiguration: SeverityBasedRuleConfiguration { typealias Parent = DiscouragedDirectInitRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/EmptyCountConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/EmptyCountConfiguration.swift index 7437b82ae4..c0302c9cee 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/EmptyCountConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/EmptyCountConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct EmptyCountConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct EmptyCountConfiguration: SeverityBasedRuleConfiguration { typealias Parent = EmptyCountRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExpiringTodoConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExpiringTodoConfiguration.swift index 87c8072bb8..4667ff09ee 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExpiringTodoConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExpiringTodoConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ExpiringTodoConfiguration: RuleConfiguration, Equatable { +struct ExpiringTodoConfiguration: RuleConfiguration { typealias Parent = ExpiringTodoRule typealias Severity = SeverityConfiguration diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitInitConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitInitConfiguration.swift index a95cc40a93..12797b725e 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitInitConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitInitConfiguration.swift @@ -1,5 +1,5 @@ @AutoApply -struct ExplicitInitConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ExplicitInitConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ExplicitInitRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitTypeInterfaceConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitTypeInterfaceConfiguration.swift index 467dafccbf..b57dd54f74 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitTypeInterfaceConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ExplicitTypeInterfaceConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ExplicitTypeInterfaceConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ExplicitTypeInterfaceConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ExplicitTypeInterfaceRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileHeaderConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileHeaderConfiguration.swift index eb4df0af74..48706f9722 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileHeaderConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileHeaderConfiguration.swift @@ -2,7 +2,7 @@ import Foundation import SourceKittenFramework import SwiftLintCore -struct FileHeaderConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct FileHeaderConfiguration: SeverityBasedRuleConfiguration { typealias Parent = FileHeaderRule private static let fileNamePlaceholder = "SWIFTLINT_CURRENT_FILENAME" diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileLengthConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileLengthConfiguration.swift index 6eb72a97b3..f32ea9cd78 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileLengthConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileLengthConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct FileLengthConfiguration: RuleConfiguration, Equatable { +struct FileLengthConfiguration: RuleConfiguration { typealias Parent = FileLengthRule @ConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameConfiguration.swift index 1fb9d7d03c..9caeff15f9 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct FileNameConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct FileNameConfiguration: SeverityBasedRuleConfiguration { typealias Parent = FileNameRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameNoSpaceConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameNoSpaceConfiguration.swift index 57527663d7..8482977ece 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameNoSpaceConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileNameNoSpaceConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct FileNameNoSpaceConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct FileNameNoSpaceConfiguration: SeverityBasedRuleConfiguration { typealias Parent = FileNameNoSpaceRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileTypesOrderConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileTypesOrderConfiguration.swift index e0a2d4774e..f9d6c34323 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileTypesOrderConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FileTypesOrderConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct FileTypesOrderConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct FileTypesOrderConfiguration: SeverityBasedRuleConfiguration { typealias Parent = FileTypesOrderRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ForWhereConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ForWhereConfiguration.swift index aa6e1acf04..56f13072e4 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ForWhereConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ForWhereConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ForWhereConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ForWhereConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ForWhereRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FunctionParameterCountConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FunctionParameterCountConfiguration.swift index 5cde760a27..aedea8a3ad 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FunctionParameterCountConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/FunctionParameterCountConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct FunctionParameterCountConfiguration: RuleConfiguration, Equatable { +struct FunctionParameterCountConfiguration: RuleConfiguration { typealias Parent = FunctionParameterCountRule @ConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitReturnConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitReturnConfiguration.swift index 0df1c4e2a8..8c1c2af319 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitReturnConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitReturnConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ImplicitReturnConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ImplicitReturnConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ImplicitReturnRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitlyUnwrappedOptionalConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitlyUnwrappedOptionalConfiguration.swift index c1a8a4c86a..1f4ec57f41 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitlyUnwrappedOptionalConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ImplicitlyUnwrappedOptionalConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ImplicitlyUnwrappedOptionalConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ImplicitlyUnwrappedOptionalConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ImplicitlyUnwrappedOptionalRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/InclusiveLanguageConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/InclusiveLanguageConfiguration.swift index fed7ddf7f8..03d2e472bb 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/InclusiveLanguageConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/InclusiveLanguageConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct InclusiveLanguageConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct InclusiveLanguageConfiguration: SeverityBasedRuleConfiguration { typealias Parent = InclusiveLanguageRule private static let defaultTerms: Set = [ diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/IndentationWidthConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/IndentationWidthConfiguration.swift index 3dccf5fd15..b111307b81 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/IndentationWidthConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/IndentationWidthConfiguration.swift @@ -4,7 +4,7 @@ import SwiftLintCore // swiftlint:disable let_var_whitespace @AutoApply -struct IndentationWidthConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct IndentationWidthConfiguration: SeverityBasedRuleConfiguration { typealias Parent = IndentationWidthRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/LineLengthConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/LineLengthConfiguration.swift index dbaa6dd43b..82241b7b2a 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/LineLengthConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/LineLengthConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct LineLengthConfiguration: RuleConfiguration, Equatable { +struct LineLengthConfiguration: RuleConfiguration { typealias Parent = LineLengthRule @ConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MissingDocsConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MissingDocsConfiguration.swift index bcdab75ccd..a497952ce5 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MissingDocsConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MissingDocsConfiguration.swift @@ -1,6 +1,6 @@ import SwiftLintCore -struct MissingDocsConfiguration: RuleConfiguration, Equatable { +struct MissingDocsConfiguration: RuleConfiguration { typealias Parent = MissingDocsRule private(set) var parameters = [ diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ModifierOrderConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ModifierOrderConfiguration.swift index ec46eca32f..05ef0cba4e 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ModifierOrderConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ModifierOrderConfiguration.swift @@ -2,7 +2,7 @@ import SourceKittenFramework import SwiftLintCore @AutoApply -struct ModifierOrderConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ModifierOrderConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ModifierOrderRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineArgumentsConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineArgumentsConfiguration.swift index 0f3b1b09ba..674e5fb039 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineArgumentsConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineArgumentsConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct MultilineArgumentsConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct MultilineArgumentsConfiguration: SeverityBasedRuleConfiguration { typealias Parent = MultilineArgumentsRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineParametersConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineParametersConfiguration.swift index 98c2b151db..963afd7b6e 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineParametersConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/MultilineParametersConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct MultilineParametersConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct MultilineParametersConfiguration: SeverityBasedRuleConfiguration { typealias Parent = MultilineParametersRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NameConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NameConfiguration.swift index 90accea653..7bb842c2a3 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NameConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NameConfiguration.swift @@ -1,7 +1,7 @@ import Foundation import SwiftLintCore -struct NameConfiguration: RuleConfiguration, Equatable { +struct NameConfiguration: RuleConfiguration { typealias Severity = SeverityConfiguration typealias SeverityLevels = SeverityLevelsConfiguration typealias StartWithLowercaseConfiguration = ChildOptionSeverityConfiguration diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NestingConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NestingConfiguration.swift index 6fe0955c94..a9c6351003 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NestingConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NestingConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct NestingConfiguration: RuleConfiguration, Equatable { +struct NestingConfiguration: RuleConfiguration { typealias Parent = NestingRule typealias Severity = SeverityLevelsConfiguration diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NonOverridableClassDeclarationConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NonOverridableClassDeclarationConfiguration.swift index 204113fa18..5022944724 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NonOverridableClassDeclarationConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NonOverridableClassDeclarationConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply // swiftlint:disable:next type_name -struct NonOverridableClassDeclarationConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct NonOverridableClassDeclarationConfiguration: SeverityBasedRuleConfiguration { typealias Parent = NonOverridableClassDeclarationRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NumberSeparatorConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NumberSeparatorConfiguration.swift index e06f07dbda..6268222e0a 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NumberSeparatorConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/NumberSeparatorConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct NumberSeparatorConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct NumberSeparatorConfiguration: SeverityBasedRuleConfiguration { typealias Parent = NumberSeparatorRule struct ExcludeRange: AcceptableByConfigurationElement, Equatable { diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ObjectLiteralConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ObjectLiteralConfiguration.swift index 1c71f60c62..fd691da869 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ObjectLiteralConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ObjectLiteralConfiguration.swift @@ -3,7 +3,7 @@ import SwiftLintCore typealias DiscouragedObjectLiteralConfiguration = ObjectLiteralConfiguration @AutoApply -struct ObjectLiteralConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ObjectLiteralConfiguration: SeverityBasedRuleConfiguration { @ConfigurationElement(key: "severity") private(set) var severityConfiguration = SeverityConfiguration(.warning) @ConfigurationElement(key: "image_literal") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OpeningBraceConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OpeningBraceConfiguration.swift index 3fb8225728..85f40e1da0 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OpeningBraceConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OpeningBraceConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct OpeningBraceConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct OpeningBraceConfiguration: SeverityBasedRuleConfiguration { typealias Parent = OpeningBraceRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OperatorUsageWhitespaceConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OperatorUsageWhitespaceConfiguration.swift index 1313c23924..09c8bcd489 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OperatorUsageWhitespaceConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OperatorUsageWhitespaceConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct OperatorUsageWhitespaceConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct OperatorUsageWhitespaceConfiguration: SeverityBasedRuleConfiguration { typealias Parent = OperatorUsageWhitespaceRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OverriddenSuperCallConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OverriddenSuperCallConfiguration.swift index 1c100efc46..ca2a9aeb32 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OverriddenSuperCallConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/OverriddenSuperCallConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct OverriddenSuperCallConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct OverriddenSuperCallConfiguration: SeverityBasedRuleConfiguration { typealias Parent = OverriddenSuperCallRule private static let defaultIncluded = [ diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrefixedTopLevelConstantConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrefixedTopLevelConstantConfiguration.swift index c30f5c69ab..f6057ceb93 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrefixedTopLevelConstantConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrefixedTopLevelConstantConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct PrefixedTopLevelConstantConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct PrefixedTopLevelConstantConfiguration: SeverityBasedRuleConfiguration { typealias Parent = PrefixedTopLevelConstantRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOutletConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOutletConfiguration.swift index 4034e9921a..e31075e071 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOutletConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOutletConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct PrivateOutletConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct PrivateOutletConfiguration: SeverityBasedRuleConfiguration { typealias Parent = PrivateOutletRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOverFilePrivateConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOverFilePrivateConfiguration.swift index 8c3ccbd032..ed9766230f 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOverFilePrivateConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateOverFilePrivateConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct PrivateOverFilePrivateConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct PrivateOverFilePrivateConfiguration: SeverityBasedRuleConfiguration { typealias Parent = PrivateOverFilePrivateRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateUnitTestConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateUnitTestConfiguration.swift index 365e3f2c05..9a67e2bd6c 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateUnitTestConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/PrivateUnitTestConfiguration.swift @@ -1,7 +1,7 @@ import Foundation import SwiftLintCore -struct PrivateUnitTestConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct PrivateUnitTestConfiguration: SeverityBasedRuleConfiguration { typealias Parent = PrivateUnitTestRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ProhibitedSuperConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ProhibitedSuperConfiguration.swift index eb4a8536f8..914e3a5dfc 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ProhibitedSuperConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/ProhibitedSuperConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct ProhibitedSuperConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct ProhibitedSuperConfiguration: SeverityBasedRuleConfiguration { typealias Parent = ProhibitedSuperRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/RequiredEnumCaseConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/RequiredEnumCaseConfiguration.swift index 565efd1a47..7a3184a68a 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/RequiredEnumCaseConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/RequiredEnumCaseConfiguration.swift @@ -1,4 +1,4 @@ -struct RequiredEnumCaseConfiguration: RuleConfiguration, Equatable { +struct RequiredEnumCaseConfiguration: RuleConfiguration { typealias Parent = RequiredEnumCaseRule struct RequiredCase: Hashable { diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SelfBindingConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SelfBindingConfiguration.swift index 253e08f8c7..005a838f3c 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SelfBindingConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SelfBindingConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct SelfBindingConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct SelfBindingConfiguration: SeverityBasedRuleConfiguration { typealias Parent = SelfBindingRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SortedImportsConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SortedImportsConfiguration.swift index fd55611479..8aaab0abc8 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SortedImportsConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SortedImportsConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct SortedImportsConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct SortedImportsConfiguration: SeverityBasedRuleConfiguration { typealias Parent = SortedImportsRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/StatementPositionConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/StatementPositionConfiguration.swift index 877d1e6c4c..a0361e64d7 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/StatementPositionConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/StatementPositionConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct StatementPositionConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct StatementPositionConfiguration: SeverityBasedRuleConfiguration { typealias Parent = StatementPositionRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SwitchCaseAlignmentConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SwitchCaseAlignmentConfiguration.swift index 69cf2cfe68..fc48093af5 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SwitchCaseAlignmentConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/SwitchCaseAlignmentConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct SwitchCaseAlignmentConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct SwitchCaseAlignmentConfiguration: SeverityBasedRuleConfiguration { typealias Parent = SwitchCaseAlignmentRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TestCaseAccessibilityConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TestCaseAccessibilityConfiguration.swift index 0f234ccf02..4141ce49b9 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TestCaseAccessibilityConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TestCaseAccessibilityConfiguration.swift @@ -4,7 +4,7 @@ import SwiftLintCore // swiftlint:disable let_var_whitespace @AutoApply -struct TestCaseAccessibilityConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct TestCaseAccessibilityConfiguration: SeverityBasedRuleConfiguration { typealias Parent = TestCaseAccessibilityRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TodoConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TodoConfiguration.swift index 8ad7beb1e9..437c57a2cb 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TodoConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TodoConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct TodoConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct TodoConfiguration: SeverityBasedRuleConfiguration { typealias Parent = TodoRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingClosureConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingClosureConfiguration.swift index 473d946a32..e4b4862921 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingClosureConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingClosureConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct TrailingClosureConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct TrailingClosureConfiguration: SeverityBasedRuleConfiguration { typealias Parent = TrailingClosureRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingCommaConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingCommaConfiguration.swift index 07270aeece..f386f1967d 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingCommaConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingCommaConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct TrailingCommaConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct TrailingCommaConfiguration: SeverityBasedRuleConfiguration { typealias Parent = TrailingCommaRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingWhitespaceConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingWhitespaceConfiguration.swift index 1261049871..d8577e64ae 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingWhitespaceConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TrailingWhitespaceConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct TrailingWhitespaceConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct TrailingWhitespaceConfiguration: SeverityBasedRuleConfiguration { typealias Parent = TrailingWhitespaceRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeContentsOrderConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeContentsOrderConfiguration.swift index b526120841..811622d0f7 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeContentsOrderConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeContentsOrderConfiguration.swift @@ -20,7 +20,7 @@ enum TypeContent: String { } @AutoApply -struct TypeContentsOrderConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct TypeContentsOrderConfiguration: SeverityBasedRuleConfiguration { typealias Parent = TypeContentsOrderRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeNameConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeNameConfiguration.swift index 7b241d6231..8d56cbf5e5 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeNameConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/TypeNameConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct TypeNameConfiguration: RuleConfiguration, Equatable { +struct TypeNameConfiguration: RuleConfiguration { typealias Parent = TypeNameRule @ConfigurationElement diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnitTestConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnitTestConfiguration.swift index 4a7b88714e..2f3473abda 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnitTestConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnitTestConfiguration.swift @@ -9,7 +9,7 @@ typealias NoMagicNumbersConfiguration = UnitTestConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct UnitTestConfiguration: SeverityBasedRuleConfiguration { @ConfigurationElement(key: "severity") private(set) var severityConfiguration = SeverityConfiguration(.warning) @ConfigurationElement( diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedDeclarationConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedDeclarationConfiguration.swift index 932bb9b378..d3a1a194bf 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedDeclarationConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedDeclarationConfiguration.swift @@ -4,7 +4,7 @@ import SwiftLintCore // swiftlint:disable let_var_whitespace @AutoApply -struct UnusedDeclarationConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct UnusedDeclarationConfiguration: SeverityBasedRuleConfiguration { typealias Parent = UnusedDeclarationRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedImportConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedImportConfiguration.swift index e13a599747..57aa628523 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedImportConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedImportConfiguration.swift @@ -28,7 +28,7 @@ struct TransitiveModuleConfiguration: Equatable, AcceptableByConfi } @AutoApply -struct UnusedImportConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct UnusedImportConfiguration: SeverityBasedRuleConfiguration { typealias Parent = UnusedImportRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedOptionalBindingConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedOptionalBindingConfiguration.swift index ae4a1a8413..fa094ad346 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedOptionalBindingConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/UnusedOptionalBindingConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct UnusedOptionalBindingConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct UnusedOptionalBindingConfiguration: SeverityBasedRuleConfiguration { typealias Parent = UnusedOptionalBindingRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceClosingBracesConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceClosingBracesConfiguration.swift index 70c97d0f53..700b06e04b 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceClosingBracesConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceClosingBracesConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply // swiftlint:disable:next type_name -struct VerticalWhitespaceClosingBracesConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct VerticalWhitespaceClosingBracesConfiguration: SeverityBasedRuleConfiguration { typealias Parent = VerticalWhitespaceClosingBracesRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceConfiguration.swift index 936c2d7a56..2249594ee8 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/VerticalWhitespaceConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct VerticalWhitespaceConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct VerticalWhitespaceConfiguration: SeverityBasedRuleConfiguration { typealias Parent = VerticalWhitespaceRule @ConfigurationElement(key: "severity") diff --git a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/XCTSpecificMatcherConfiguration.swift b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/XCTSpecificMatcherConfiguration.swift index f79f22f1e0..249c35ef4e 100644 --- a/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/XCTSpecificMatcherConfiguration.swift +++ b/Source/SwiftLintBuiltInRules/Rules/RuleConfigurations/XCTSpecificMatcherConfiguration.swift @@ -1,7 +1,7 @@ import SwiftLintCore @AutoApply -struct XCTSpecificMatcherConfiguration: SeverityBasedRuleConfiguration, Equatable { +struct XCTSpecificMatcherConfiguration: SeverityBasedRuleConfiguration { typealias Parent = XCTSpecificMatcherRule @MakeAcceptableByConfigurationElement diff --git a/Source/SwiftLintCore/Models/ChildOptionSeverityConfiguration.swift b/Source/SwiftLintCore/Models/ChildOptionSeverityConfiguration.swift index f459eae26e..3c867c6bb7 100644 --- a/Source/SwiftLintCore/Models/ChildOptionSeverityConfiguration.swift +++ b/Source/SwiftLintCore/Models/ChildOptionSeverityConfiguration.swift @@ -1,6 +1,6 @@ /// A rule configuration that allows to disable (`off`) an option of a rule or specify its severity level in which /// case it's active. -public struct ChildOptionSeverityConfiguration: RuleConfiguration, Equatable, InlinableOptionType { +public struct ChildOptionSeverityConfiguration: RuleConfiguration { /// Configuration with a warning severity. public static var error: Self { Self(optionSeverity: .error) } /// Configuration with an error severity. diff --git a/Source/SwiftLintCore/Models/RuleConfigurationDescription.swift b/Source/SwiftLintCore/Models/RuleConfigurationDescription.swift index e743b1d8fe..bfce03145b 100644 --- a/Source/SwiftLintCore/Models/RuleConfigurationDescription.swift +++ b/Source/SwiftLintCore/Models/RuleConfigurationDescription.swift @@ -267,7 +267,7 @@ public struct RuleConfigurationDescriptionBuilder { } /// :nodoc: - public static func buildExpression(_ expression: any RuleConfiguration) -> Description { + public static func buildExpression(_ expression: some RuleConfiguration) -> Description { Description.from(configuration: expression) } diff --git a/Source/SwiftLintCore/Models/SeverityConfiguration.swift b/Source/SwiftLintCore/Models/SeverityConfiguration.swift index 7358d5017b..7e44821f68 100644 --- a/Source/SwiftLintCore/Models/SeverityConfiguration.swift +++ b/Source/SwiftLintCore/Models/SeverityConfiguration.swift @@ -1,5 +1,5 @@ /// A rule configuration that allows specifying the desired severity level for violations. -public struct SeverityConfiguration: SeverityBasedRuleConfiguration, Equatable { +public struct SeverityConfiguration: SeverityBasedRuleConfiguration { /// Configuration with a warning severity. public static var error: Self { Self(.error) } /// Configuration with an error severity. diff --git a/Source/SwiftLintCore/Protocols/Rule.swift b/Source/SwiftLintCore/Protocols/Rule.swift index 160b3fefcd..8c5a152dbd 100644 --- a/Source/SwiftLintCore/Protocols/Rule.swift +++ b/Source/SwiftLintCore/Protocols/Rule.swift @@ -114,7 +114,7 @@ public extension ConfigurationProviderRule { func isEqualTo(_ rule: Rule) -> Bool { if let rule = rule as? Self { - return configuration.isEqualTo(rule.configuration) + return configuration == rule.configuration } return false } diff --git a/Source/SwiftLintCore/Protocols/RuleConfiguration.swift b/Source/SwiftLintCore/Protocols/RuleConfiguration.swift index fa08f524a9..8f5a32f516 100644 --- a/Source/SwiftLintCore/Protocols/RuleConfiguration.swift +++ b/Source/SwiftLintCore/Protocols/RuleConfiguration.swift @@ -1,5 +1,5 @@ /// A configuration value for a rule to allow users to modify its behavior. -public protocol RuleConfiguration: InlinableOptionType { +public protocol RuleConfiguration: InlinableOptionType, Equatable { /// The type of the rule that's using this configuration. associatedtype Parent: Rule @@ -13,13 +13,6 @@ public protocol RuleConfiguration: InlinableOptionType { /// /// - throws: Throws if the configuration is not in the expected format. mutating func apply(configuration: Any) throws - - /// Whether the specified configuration is equivalent to the current value. - /// - /// - parameter ruleConfiguration: The rule configuration to compare against. - /// - /// - returns: Whether the specified configuration is equivalent to the current value. - func isEqualTo(_ ruleConfiguration: some RuleConfiguration) -> Bool } /// A configuration for a rule that allows to configure at least the severity. @@ -35,12 +28,6 @@ public extension SeverityBasedRuleConfiguration { } } -public extension RuleConfiguration where Self: Equatable { - func isEqualTo(_ ruleConfiguration: some RuleConfiguration) -> Bool { - return self == ruleConfiguration as? Self - } -} - public extension RuleConfiguration { var parameterDescription: RuleConfigurationDescription? { nil } } diff --git a/Source/SwiftLintCore/RuleConfigurations/SeverityLevelsConfiguration.swift b/Source/SwiftLintCore/RuleConfigurations/SeverityLevelsConfiguration.swift index 08a5fd842f..8bfcdc8639 100644 --- a/Source/SwiftLintCore/RuleConfigurations/SeverityLevelsConfiguration.swift +++ b/Source/SwiftLintCore/RuleConfigurations/SeverityLevelsConfiguration.swift @@ -1,5 +1,5 @@ /// A rule configuration that allows specifying thresholds for `warning` and `error` severities. -public struct SeverityLevelsConfiguration: RuleConfiguration, Equatable { +public struct SeverityLevelsConfiguration: RuleConfiguration { /// The threshold for a violation to be a warning. @ConfigurationElement(key: "warning") public var warning: Int = 12 diff --git a/Source/SwiftLintCore/Rules/CustomRules.swift b/Source/SwiftLintCore/Rules/CustomRules.swift index 3e6a1ad702..4d9dbc3f6a 100644 --- a/Source/SwiftLintCore/Rules/CustomRules.swift +++ b/Source/SwiftLintCore/Rules/CustomRules.swift @@ -2,7 +2,7 @@ import Foundation // MARK: - CustomRulesConfiguration -struct CustomRulesConfiguration: RuleConfiguration, Equatable, CacheDescriptionProvider { +struct CustomRulesConfiguration: RuleConfiguration, CacheDescriptionProvider { typealias Parent = CustomRules var parameterDescription: RuleConfigurationDescription? { RuleConfigurationOption.noOptions }