[lldb-dev] [Bug 17494] New: False error err_ref_non_value when variable id spelling matches struct tag spelling
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Mon Oct 7 06:50:07 PDT 2013
http://llvm.org/bugs/show_bug.cgi?id=17494
Bug ID: 17494
Summary: False error err_ref_non_value when variable id
spelling matches struct tag spelling
Product: lldb
Version: unspecified
Hardware: Macintosh
OS: MacOS X
Status: NEW
Severity: normal
Priority: P
Component: All Bugs
Assignee: lldb-dev at cs.uiuc.edu
Reporter: james.widman at gmail.com
Classification: Unclassified
In the following test case, LLDB issues the undeserved error:
error: 'a' does not refer to a value
... when it should instead match a to the parameter variable. Instead, it
seems to find the struct tag 'a'.
Example:
% cat a.c
#include <stdio.h>
struct a { int m; };
void dump_a( struct a * a ) { printf( "a::m: %d\n", a->m ); }
int f(struct a* a) {
return a->m;
}
int main()
{
struct a x = { 42 };
f(&x);
return 0;
}
% cc -g a.c
% lldb -x ./a.out
Current executable set to './a.out' (x86_64).
(lldb) b f
Breakpoint 1: where = a.out`f + 8 at a.c:9, address = 0x0000000100000eb8
(lldb) r
Process 16064 launched: './a.out' (x86_64)
Process 16064 stopped
* thread #1: tid = 0x77032, 0x0000000100000eb8 a.out`f(a=0x00007fff5fbfea78) +
8 at a.c:9, queue = 'com.apple.main-thread, stop reason = breakpoint 1.1
frame #0: 0x0000000100000eb8 a.out`f(a=0x00007fff5fbfea78) + 8 at a.c:9
6 void dump_a( struct a * a ) { printf( "a::m: %d\n", a->m ); }
7
8 int f(struct a* a) {
-> 9 return a->m;
10 }
11
12 int main()
(lldb) expression -- dump_a(a)
error: 'a' does not refer to a value
note: declared here
error: 1 errors parsing expression
(lldb)
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20131007/61a029bb/attachment.html>
More information about the lldb-dev
mailing list