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

Fix false-positives in S1854

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.10
    • Fix Version/s: 3.12
    • Component/s: C++, Rules
    • Labels:
      None

      Description

      #include <iostream>
      
      int c;
      
      void fun() {
        extern int c;
        c = 42; // false-positive
      }
      
      int main() {
        fun();
        std::cout << c << std::endl;
        return 0;
      }
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              massimo.paladin Massimo PALADIN
              Reporter:
              evgeny.mandrikov Evgeny Mandrikov
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Due:
                Created:
                Updated:
                Resolved: