[LLVMbugs] [Bug 15528] New: Incomprehensible errors for namespaces with missing braces

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sat Mar 16 05:32:12 PDT 2013


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

            Bug ID: 15528
           Summary: Incomprehensible errors for namespaces with missing
                    braces
           Product: clang
           Version: trunk
          Hardware: Macintosh
                OS: MacOS X
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Frontend
          Assignee: unassignedclangbugs at nondot.org
          Reporter: gonzalobg88 at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 10184
  --> http://llvm.org/bugs/attachment.cgi?id=10184&action=edit
Minimal example

Missing braces in namespace declaration errors are currently being displayed
after a long chain of "non-errors". For namespaces in header files the
situation is even worse: arriving at the -ferror-limit is very easy. See
minimal example below.

3 Files: a.h, b.h, main.cpp (dependency on boost/any)

FILE: a.h:
#ifndef A_H_
#define A_H_
#include <iostream>
namespace test {
// } // uncomment this line to fix the error
#endif

FILE: b.h:
#ifndef B_H_
#define B_H_
#include <boost/any.hpp>
// uncomment this line to see how the "real error" is displayed:
#include <unordered_map>
#endif

FILE: main.cpp:
#include "a.h"
#include "b.h"
int main() { return 0; }

-- 
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/20130316/adffde2e/attachment.html>


More information about the llvm-bugs mailing list