This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
I understand that you are talking about ISO C, but one relevant case (in C++) to look out for that is similar is this one, which certainly constitutes legitimate and widespread use of language features:
class A {...}; class B : public A { ... };
void f() { B b; g (static_cast<A*> (&b)); }
void g(A *a) { B *b = dynamic_cast<B*>(a); // do what you please with the full object B }
-- Mark Mitchell CodeSourcery, LLC mark@codesourcery.com (916) 791-8304
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |