http://llvm.org/bugs/show_bug.cgi?id=21116

            Bug ID: 21116
           Summary: [RFE] Diagnostic for when .cpp file does not implement
                    all methods
           Product: clang
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected]
    Classification: Unclassified

It is a common convention for all out of line methods of a C++ class to be
implemented in a single C++ file.

It would be nice if clang had a warning to enforce this, instead of only having
this mistake be detected at link time (or never, if no one calls the method).
Essentially I want the diagnostic on any unimplemented out-of-line methods when
clang sees that I implemented at least one out-of-line method of a class in the
main file.

--
$ cat t.cpp
class A {
  void a();
  void b();  // expected-warning{{unimplemented method}}
};

void A::a() {}
$ clang -cc1 -verify t.cpp
error: 'warning' diagnostics expected but not seen: 
  File t.cpp Line 3: unimplemented method
1 error generated.
--

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to