[LLVMbugs] [Bug 19036] New: LabelStmt cursor equality

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Mar 4 04:59:18 PST 2014


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

            Bug ID: 19036
           Summary: LabelStmt cursor equality
           Product: clang
           Version: 3.4
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: libclang
          Assignee: unassignedclangbugs at nondot.org
          Reporter: vpozdyayev at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

When doing a complete tree traversal for

    int main( int, char ** ) {
        goto lbl1;
        lbl1:;
    } 

reaching LABEL_STMT via GOTO_STMT->LABEL_REF, or directly from COMPOUND_STMT,
results in cursors that are not `clang_equalCursors()`:

cursor    {kind=CXCursor_LabelStmt (201) xdata=0 data=0x0045dfac {0x00000000,
0x00900410, 0x008f2a00} }    CXCursor
    kind    CXCursor_LabelStmt (201)    CXCursorKind
    xdata    0    int
    data    0x0045dfac {0x00000000, 0x00900410, 0x008f2a00}    const void *[3]

and

cursor    {kind=CXCursor_LabelStmt (201) xdata=0 data=0x0045da74 {0x008ffed0,
0x00900410, 0x008f2a00} }    CXCursor
    kind    CXCursor_LabelStmt (201)    CXCursorKind
    xdata    0    int
    data    0x0045da74 {0x008ffed0, 0x00900410, 0x008f2a00}    const void *[3]

AFAICT this is related to "// FIXME: We end up faking the "parent"
declaration..." in CIndex.cpp

-- 
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/20140304/6c824607/attachment.html>


More information about the llvm-bugs mailing list