https://bugs.llvm.org/show_bug.cgi?id=44884
Bug ID: 44884
Summary: Debug information shows incorrect lexical scope for
typedef.
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: DebugInfo
Assignee: unassignedb...@nondot.org
Reporter: international.phan...@gmail.com
CC: jdevliegh...@apple.com, keith.wal...@arm.com,
llvm-bugs@lists.llvm.org,
paul_robin...@playstation.sony.com
Given the following test case:
//------------------------------------------------------------
// typedef.cpp
//------------------------------------------------------------
int bar(float Input) { return (int)Input; }
unsigned foo(char Param) {
typedef int INT;
INT Value = Param;
{
typedef float FLOAT;
{
FLOAT Added = Value + Param;
Value = bar(Added);
}
}
return Value + Param;
}
//------------------------------------------------------------
Using the following command line options to generate debug info
(DWARF) and (COFF):
clang -c -g -O0 typedef.cpp -o typedef.o
clang -c -g -O0 typedef.cpp -o typedef-coff.o -gcodeview
--target=x86_64-windows
Looking at the output generated by llvm-dwarfdump and llvm-diva,
the debug info shows the typedefs 'INT'and 'FLOAT' to be at the same lexical
scope (function scope).
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs