<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><span class="vcard"><a class="email" href="mailto:jdevlieghere@apple.com" title="Jonas Devlieghere <jdevlieghere@apple.com>"> <span class="fn">Jonas Devlieghere</span></a>
</span> changed
<a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED FIXED - LLDB expressions always error if a C++ local variable is named after a keyword"
href="https://bugs.llvm.org/show_bug.cgi?id=40189">bug 40189</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">CC</td>
<td>
</td>
<td>jdevlieghere@apple.com
</td>
</tr>
<tr>
<td style="text-align:right;">Resolution</td>
<td>---
</td>
<td>FIXED
</td>
</tr>
<tr>
<td style="text-align:right;">Status</td>
<td>NEW
</td>
<td>RESOLVED
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED FIXED - LLDB expressions always error if a C++ local variable is named after a keyword"
href="https://bugs.llvm.org/show_bug.cgi?id=40189#c4">Comment # 4</a>
on <a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED FIXED - LLDB expressions always error if a C++ local variable is named after a keyword"
href="https://bugs.llvm.org/show_bug.cgi?id=40189">bug 40189</a>
from <span class="vcard"><a class="email" href="mailto:jdevlieghere@apple.com" title="Jonas Devlieghere <jdevlieghere@apple.com>"> <span class="fn">Jonas Devlieghere</span></a>
</span></b>
<pre>This was fixed by <a href="https://reviews.llvm.org/rL359773">https://reviews.llvm.org/rL359773</a>
bash-3.2$ echo 'int main(int argc){__func__;}' | g++ -g -x c++ - && lldb -o 'br
s -n main' -o 'pr la' -o 'expr argc' a.out
<stdin>:1:5: warning: only one parameter on 'main' declaration [-Wmain]
int main(int argc){__func__;}
^
<stdin>:1:20: warning: expression result unused [-Wunused-value]
int main(int argc){__func__;}
^~~~~~~~
2 warnings generated.
(lldb) target create "a.out"
Current executable set to 'a.out' (x86_64).
(lldb) br s -n main
Breakpoint 1: where = a.out`main + 9 at <stdin>:1:29, address =
0x0000000100000fa9
(lldb) pr la
Process 51065 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = breakpoint 1.1
frame #0: 0x0000000100000fa9 a.out`main(argc=1) at <stdin>:1:29
Target 0: (a.out) stopped.
Process 51065 launched: '/private/tmp/a.out' (x86_64)
(lldb) expr argc
(int) $0 = 1</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>