[llvm-bugs] [Bug 36528] New: clang-format FixNamespaceComments does not understand namespace aliases

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Feb 26 14:33:32 PST 2018


https://bugs.llvm.org/show_bug.cgi?id=36528

            Bug ID: 36528
           Summary: clang-format FixNamespaceComments does not understand
                    namespace aliases
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Formatter
          Assignee: unassignedclangbugs at nondot.org
          Reporter: mikhail.strelnikov at gmail.com
                CC: djasper at google.com, klimek at google.com,
                    llvm-bugs at lists.llvm.org

# cat test.cpp

namespace nn {}
void f()
{
    namespace n = nn;
    {
        int i;
        int j;
    }
}

# clang-format -style="{FixNamespaceComments: true}" test.cpp

namespace nn {}
void f() {
  namespace n = nn;
  {
    int i;
    int j;
  } // namespace n=nn;
}

In this case comment "// namespace n=nn;" should not be added.

-- 
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/20180226/8e8c5a2c/attachment.html>


More information about the llvm-bugs mailing list