[Lldb-commits] [PATCH] D13947: [lldb-mi] Fix expansion of anonymous structures and unions
Eugene Leviant via lldb-commits
lldb-commits at lists.llvm.org
Wed Oct 21 08:30:05 PDT 2015
evgeny777 created this revision.
evgeny777 added reviewers: ki.stfu, abidh.
evgeny777 added subscribers: lldb-commits, KLapshin.
Suppose we have the following type
```
struct S {
union {
int i1;
unsigned u1;
};
union {
int i2;
unsigned u2;
};
};
```
Current revision makes it impossible to evaluate it using MI, because MI assigns '??' as variable name to each of the unnamed unions after "-var-list-children" command. Also '??' incorrectly goes to 'exp' field which is treated by IDE as a structure field name and is displayed in watch window.
The patch fixes this returning empty string as type name for unnamed union and assigning $N to variable name, where N is the field number in the parent entity.
http://reviews.llvm.org/D13947
Files:
test/tools/lldb-mi/variable/TestMiVar.py
test/tools/lldb-mi/variable/main.cpp
tools/lldb-mi/MICmdCmdVar.cpp
tools/lldb-mi/MICmnLLDBUtilSBValue.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D13947.38017.patch
Type: text/x-patch
Size: 4644 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20151021/63a2c427/attachment-0001.bin>
More information about the lldb-commits
mailing list