Uploaded image for project: 'SonarJava'
  1. SonarJava
  2. SONARJAVA-3338

FP on S1118: improve support of Lombok's annotation generating constructor

    XMLWordPrintable

    Details

      Description

      • lombok.AllArgsConstructor
      • lombok.NoArgsConstructor
      • lombok.RequiredArgsConstructor

      All three Lombok annotations above generate a constructor. When doing so, one can specify an access level (default is public):

      @NoArgsConstructor(access = AccessLevel.PROTECTED)
      

      This generates FP for S1118 expecting a non-public constructor.

      We already partially support the problem: we filter issues when the access level is PRIVATE, however, the rule reports an issue only when the constructor is Public.

      The Lombok's filter should correctly match the behavior of the rule.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              quentin.jaquier Quentin Jaquier
              Reporter:
              quentin.jaquier Quentin Jaquier
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Due:
                Created:
                Updated:
                Resolved: