diff --git a/docs/modules/ROOT/pages/cops_style.adoc b/docs/modules/ROOT/pages/cops_style.adoc index 3d538d9a046..2522c37cd9d 100644 --- a/docs/modules/ROOT/pages/cops_style.adoc +++ b/docs/modules/ROOT/pages/cops_style.adoc @@ -120,6 +120,9 @@ This cop checks for grouping of accessors in `class` and `module` bodies. By default it enforces accessors to be placed in grouped declarations, but it can be configured to enforce separating them in multiple declarations. +Note: `Sorbet` is not compatible with "grouped" style. Consider "separated" style +or disabling this cop. + === Examples ==== EnforcedStyle: grouped (default) diff --git a/lib/rubocop/cop/style/accessor_grouping.rb b/lib/rubocop/cop/style/accessor_grouping.rb index 61c83bc8ccf..4da6a6e4785 100644 --- a/lib/rubocop/cop/style/accessor_grouping.rb +++ b/lib/rubocop/cop/style/accessor_grouping.rb @@ -7,6 +7,9 @@ module Style # By default it enforces accessors to be placed in grouped declarations, # but it can be configured to enforce separating them in multiple declarations. # + # Note: `Sorbet` is not compatible with "grouped" style. Consider "separated" style + # or disabling this cop. + # # @example EnforcedStyle: grouped (default) # # bad # class Foo