This is the mail archive of the gcc-bugs@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]

[Bug c++/11078] [ABI] ICE in write_type with typeof and templates


------- Additional Comments From boris at kolpackov dot net  2004-08-03 21:27 -------
Subject: Re:  [ABI] ICE in write_type with typeof and templates

ian at wasabisystems dot com <gcc-bugzilla@gcc.gnu.org> writes:

> In fact, in general the compiler can resolve typeof.  
> In what cases will it not be able to?

The only thing I can think of is code like this:

struct
{
} a;

static void
fa (typeof (a)&)
{
}

struct
{
} b;

static void
fb (typeof (b)&)
{
}


void
f ()
{
  fa (a);
  fb (b);
}


It compiles with g++ 3.4.1. nm shows the following:

0000000c T f()
00000000 t fa(._0&)
00000006 t fb(._1&)
00000000 B a
00000001 B b

Which suggest that gcc assigns internal names even to anonymous
types. So I think it's true that any typeof-expression can be 
reduced to a type-name.



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11078


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]