[C++ PATCH] Fix bug 72
Nathan Sidwell
nathan@codesourcery.com
Mon Dec 10 01:56:00 GMT 2001
Hi,
this fixes bug 72, where we rejected duplicate typedefs too early.
Duplicate typedefs are ok, if they are of the same type. In a
template declaration we could have
typedef int xxx;
typedef typename A<T>::type xxx;
we would reject this at definition time, rather than wait until
instantiation and see whether A<T>::type is or is not
an int.
Note, at definition time, it doesn't matter which of these two
a later name lookup obtains, as they must be the same for a valid
template instantiation.
booted & tested on i686-pc-linux-gnu, ok?
nathan
--
Dr Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
'But that's a lie.' - 'Yes it is. What's your point?'
nathan@codesourcery.com : http://www.cs.bris.ac.uk/~nathan/ : nathan@acm.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 72.patch
Type: application/octet-stream
Size: 1439 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20011210/2b8791d8/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 72.C
Type: application/octet-stream
Size: 367 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20011210/2b8791d8/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 72-2.C
Type: application/octet-stream
Size: 602 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20011210/2b8791d8/attachment-0002.obj>
More information about the Gcc-patches
mailing list