This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
c++/7919: using declarations screw this pointer
- From: nathan at codesourcery dot com
- To: gcc-gnats at gcc dot gnu dot org
- Date: 14 Sep 2002 19:11:47 -0000
- Subject: c++/7919: using declarations screw this pointer
- Reply-to: nathan at codesourcery dot com
>Number: 7919
>Category: c++
>Synopsis: using declarations screw this pointer
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Sep 14 12:16:03 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: nathan
>Release: 3.3 cvs
>Organization:
>Environment:
>Description:
using declarations to offset bases get wrong this pointer
>How-To-Repeat:
the attached program exits with status 1, it should
exit with status zero. Base::Return gets the unadjusted
Derived this pointer.
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="using.cc"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="using.cc"
c3RydWN0IEJhc2UgewogIGludCBtOwogIHZvaWQgKlJldHVybiAoKSB7IHJldHVybiB0aGlzOyB9
Cn07CgpzdHJ1Y3QgRGVyaXZlZCA6IEJhc2UgewogIHVzaW5nIEJhc2U6OlJldHVybjsKICB2aXJ0
dWFsIH5EZXJpdmVkICgpIHt9Cn07CgppbnQgbWFpbiAoKQp7CiAgRGVyaXZlZCBkOwogIAogIHJl
dHVybiBzdGF0aWNfY2FzdCA8QmFzZSAqPiAoJmQpICE9IGQuUmV0dXJuICgpOwp9Cg==