https://bugs.kde.org/show_bug.cgi?id=423780
            Bug ID: 423780
           Summary: clazy-fully-qualified-moc-types not detecting missing
                    namespace
           Product: clazy
           Version: unspecified
          Platform: Other
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: unassigned-b...@kde.org
          Reporter: chg...@gmail.com
                CC: smart...@kde.org
  Target Milestone: ---

SUMMARY

Given an enum E in a class C in a namespace N, clazy reports an error when the
enum is used fully-unqualified (E value), but doesn't report an error if used
partially-qualified (C:E value).
The only valid usage should be "N:C:E value"

Or the documentation is not accurate, here is the given example:
namespace MyNameSpace {

    struct MyType { (...) };

    class MyObject : public QObject
    {
        Q_OBJECT
        Q_PROPERTY(MyGadget myprop READ myprop); // Wrong, needs namespace
    Q_SIGNALS:
        void mySignal(MyType); // Wrong
        void mySignal(MyNameSpace::MyType); // OK
    };
}


STEPS TO REPRODUCE
run clazy on:
namespace N { 
 class C: QObject 
 { 
  Enum E {}; 
 signals: 
  void function(C:E value) {} 
 }
}

OBSERVED RESULT
No error reported

EXPECTED RESULT
"signal arguments need to be fully-qualified" is emitted


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION

Stock clazy on Ubuntu 18.04, based on LLVM-6.0.0

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to