[RFA] Extend demangler to recognize destructors/constructors
Gabriel Dos Reis
gdr@codesourcery.com
Thu Mar 15 01:15:00 GMT 2001
Stylistic notes.
Jim Blandy <jimb@zwingli.cygnus.com> writes:
[...]
| +
| + /* Set to non-zero iff this name is a constructor. The actual value
| + is '1', '2', or '3', indicating a complete object, base object,
| + or complete object allocating constructor. */
| + int is_constructor;
| +
| + /* Set to non-zero iff this name is a destructor. The actual value
| + is '0', '1', or '2', indicating a deleting, complete object, or
| + base object destructor. */
| + int is_destructor;
May I suggest use of enums to make it much more readable? I realize
that makes
dm->is_destructor = peek_char (dm);
less straigthforward but will make use of
int
is_gnu_v3_mangled_constructor (const char *name)
and
int
is_gnu_v3_mangled_destructor (const char *name)
self explanatory.
-- Gaby
CodeSourcery, LLC http://www.codesourcery.com
More information about the Gdb-patches
mailing list