[llvm-bugs] [Bug 36581] New: Nesting of case-labels in AST

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Mar 2 12:42:01 PST 2018


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

            Bug ID: 36581
           Summary: Nesting of case-labels in AST
           Product: clang
           Version: trunk
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: jonas.toth at gmail.com
                CC: dgregor at apple.com, llvm-bugs at lists.llvm.org

Hello everybody,

i noticed weird behaviour of clangs AST which is best shown with the following
example: (note the printed AST: nesting vs flat list)
https://godbolt.org/g/cKthLe

A list of empty cases in a switch statement do nest the AST, but a simple
semicolon prevents that and results in a flat list of case labels.

This issue is a direct blocker for https://reviews.llvm.org/D40737, because it
leads to a stack overflow within the checks test cases.

The SO happened in one of Apples builders:
http://green.lab.llvm.org/green/job/clang-stage2-cmake-RgSan/5470/consoleFull#17462642768254eaf0-7326-4999-85b0-388101f2d404

-- 
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/20180302/f55e14b0/attachment.html>


More information about the llvm-bugs mailing list