[LLVMbugs] [Bug 16359] New: Missing error (waning in c++98) for non trivial object as argument to variadic function

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Jun 18 06:34:34 PDT 2013


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

            Bug ID: 16359
           Summary: Missing error (waning in c++98) for non trivial object
                    as argument to variadic function
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++11
          Assignee: unassignedclangbugs at nondot.org
          Reporter: rafael.espindola at gmail.com
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu,
                    matthewbg at google.com, richard-llvm at metafoo.co.uk
    Classification: Unclassified

Matt Beaumont-Gay found this:


struct Foo {
  Foo() {}
  Foo(const Foo&) {}
};
void f(...);
void g() {
  Foo foo;
  void (*fun)(...) = f;
  fun(foo);
  f(foo);
}

In c++98 we warn only on the direct function call and in c++11 we error only on
it too. Gcc 4.7 produces errors/warnings for both.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20130618/bbfcbb9e/attachment.html>


More information about the llvm-bugs mailing list