[ Date Prev][ Date Next][ Thread Prev][ Thread Next][ Date Index][ Thread Index]
Re: [cxx-abi-dev] __cxa_demangle of type manglings
- To: Mark Mitchell <mark@xxxxxxxxxxxxxxxx>
- Subject: Re: [cxx-abi-dev] __cxa_demangle of type manglings
- From: Jason Merrill <jason@xxxxxxxxxx>
- Date: Fri, 11 Feb 2005 17:55:09 -0500
On Mon, 17 Jan 2005 22:03:10 -0800, Mark Mitchell <mark@xxxxxxxxxxxxxxxx> wrote:
> Jason Merrill wrote:
>
>> It seems to me that the specified behavior makes __cxa_demangle useless for
>> type manglings, since most of them are also valid C++ identifiers, and
>> therefore could be an extern "C" object name. I think that the ambiguity
>> should be resolved the other way by default, and that we should add another
>> way to specify that the argument is an external name, probably via another
>> entry point.
>
> I agree. Would you like to propose a change to the ABI document?
*** abi.html.~11~ 2005-02-11 17:53:28.137880943 -0500
--- abi.html 2005-02-11 17:54:22.177570893 -0500
*************** in which case the user just doesn't get
*** 3710,3719 ****
<b>Behavior</b>:
The return value is a pointer to a null-terminated array
of characters, the demangled name.
! Ambiguities are possible between extern "C" object names and internal
! built-in type names,
e.g. "i" may be either an object named "i" or the built-in "int" type.
! Such ambiguities should be resolved to user names over built-in names.
<p>
If there is an error in demangling, the return value is a null pointer.
--- 3710,3722 ----
<b>Behavior</b>:
The return value is a pointer to a null-terminated array
of characters, the demangled name.
! Ambiguities are possible between extern "C" object names and type
! manglings,
e.g. "i" may be either an object named "i" or the built-in "int" type.
! Such ambiguous arguments are assumed to be type manglings. If the user has
! a set of external names to demangle, they should check that the names are
! in fact mangled (that is, begin with "_Z") before passing them to
! <code>__cxa_demangle</code>.
<p>
If there is an error in demangling, the return value is a null pointer.
*************** significance should be attached to the f
*** 4917,4922 ****
--- 4920,4929 ----
is simply a identifying number.</p>
<p>
+ <font color=blue>[050211]</font>
+ Reverse treatment of ambiguous arguments to __cxa_demangle (3.4).
+
+ <p>
<font color=blue>[031128]</font>
Fix alphabetization of company names.
|