This is the mail archive of the
gdb-prs@sources.redhat.com
mailing list for the GDB project.
c++/1342: Data inspection does not work in conversion operator with static variable.
- From: duma at gorodok dot net
- To: gdb-gnats at sources dot redhat dot com
- Date: 19 Aug 2003 11:24:08 -0000
- Subject: c++/1342: Data inspection does not work in conversion operator with static variable.
- Reply-to: duma at gorodok dot net
>Number: 1342
>Category: c++
>Synopsis: Data inspection does not work in conversion operator with static variable.
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Aug 19 11:28:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator: duma@gorodok.net
>Release: unknown-1.0
>Organization:
>Environment:
Linux 2.4.21-0.13mdk #1 Fri Mar 14 15:08:06 EST 2003 i686 unknown unknown GNU/Linux
gcc:
Reading specs from /usr/lib/gcc-lib/i586-mandrake-linux-gnu/3.2.2/specs
Configured with: ../configure --prefix=/usr --libdir=/usr/lib --with-slibdir=/lib --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --enable-long-long --enable-__cxa_atexit --enable-languages=c,c++,ada,f77,objc,java --host=i586-mandrake-linux-gnu --with-system-zlib
Thread model: posix
gcc version 3.2.2 (Mandrake Linux 9.1 3.2.2-3mdk)
gdb:
GNU gdb 5.3-22mdk (Mandrake Linux)
i586-mandrake-linux-gnu
>Description:
Wrong address of local variable is displayed.
Consequently displayed value is wrong
>How-To-Repeat:
while debugging step in conversion operator and try to print &a
verify that result is incorrect using assembler dump
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: text/x-c++src; name="Test.cpp"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="Test.cpp"
dGVtcGxhdGUgPHVuc2lnbmVkIFc+CnN0cnVjdCBBCnsKCWxvbmcgbG9uZyBhOwoJc2lnbmVkIGI7
Cglib29sIGM7Cn07CnRlbXBsYXRlPHVuc2lnbmVkIFY+CnN0cnVjdCBCCnsKCWludCBmOwpwdWJs
aWM6CglCKCl7fQoJdGVtcGxhdGUgPHVuc2lnbmVkIFc+CglvcGVyYXRvciBBPFc+KCkgY29uc3QK
CXsKCQlzdGF0aWMgQjxWPiBnOwoJCQoJCWcuZiA9IDA7CgkJCgkJLy9wcmludCAmYSBpbiBnZGIg
cHJvbXB0IGRpc3BsYXlzIGFkZHJlc3Mgb2YgbWVtb3J5IGNlbGwgb24gc3RhY2sgd2hlcmUgYWRk
cmVzcyBvZiBhIGlzIHN0b3JlZAoJCS8vSXQgc2VlbXMgdGhhdCByZW1vdmluZyBzdGF0aWMgdmFy
aWFibGUgZyBmaXhlcyBwcm9ibGVtLgoJCUE8Vz4gYTsKCQlhLmEgPSBnLmY7CgkJYS5iID0gMTsK
CQlhLmMgPSB0cnVlOwoJCXJldHVybiBhOwoJfQp9OwppbnQgbWFpbigpCnsKCUI8MT4gYjsKCUE8
Mj4gYTsKCWEgPSAoQTwyPiliOwoJcmV0dXJuIDA7Cn0K