Uploaded image for project: 'SonarCFamily'
  1. SonarCFamily
  2. CPP-2452

S1242: fix false-positives when class function is defined outside of the class

    Details

    • Type: False-Positive
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.7
    • Component/s: C++
    • Labels:
      None

      Description

      false-positive happens when the base class method definition is out of line

      class class1 {
        public:
        virtual void m1();
      };
      
      
      void class1::m1(){
      
      };
      
      class class2 : public class1 {
        public:
         void m1() override{}; // FP
      };
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                abbas.sabra Abbas Sabra
                Reporter:
                abbas.sabra Abbas Sabra
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Due:
                  Created:
                  Updated:
                  Resolved: