[Bug c++/13316] g++ does not follow mangling ABI for pointer to qualified member function
ian at wasabisystems dot com
gcc-bugzilla@gcc.gnu.org
Mon Jan 12 00:24:00 GMT 2004
------- Additional Comments From ian at wasabisystems dot com 2004-01-12 00:24 -------
Subject: Re: g++ does not follow mangling ABI for pointer to qualified member function
This issue is indeed subtle. The ABI specifies that ``the type of a
non-static member function is considered to be different, for the
purposes of substitution, from the type of a namespace-scope or static
member function whose type appears similar.'' The ABI also specifies
that ``all substitutions are for entities that would appear in a
symbol table.''
What you are saying is that g++ currently does not apply a
substitution when there is a match of the function signatures of
non-static member functions in different classes. Is the function
signature of a non-static member function an ``entity that would
appear in a symbol table?'' I think it could be argued either way.
The ABI is certainly rather vague in its description of substitution,
since substitution is described using loosely defined terms like
symbol tables and types, rather than, say, in terms of literal
strings.
I don't know what the intent of the ABI is here. I think the ABI
could be changed to match the current behaviour of g++ by adding
something like ``the type of non-static member functions in different
classes are considered to be different for the purposes of
substitution.''
Or g++ could be changed to match what I agree is the most plausible
reading of the ABI. Now would be the time to do it, since g++ is
switching to abi-version=2 for 3.4.0 anyhow.
Ian
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13316
More information about the Gcc-bugs
mailing list