https://gcc.gnu.org/bugzilla/show_bug.cgi?id=50800

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         Depends on|                            |18174
           Assignee|unassigned at gcc dot gnu.org      |jason at gcc dot gnu.org

--- Comment #12 from Jason Merrill <jason at gcc dot gnu.org> ---
This is related to the fix for bug 18174, which made int& a different type from
A::TA&.  But this difference is not reflected in the mangling, so B<int&> and
B<A::TA&> have the same mangling, which we can't allow.

The compiler tries to handle this by stripping attributes from template
arguments, so that B<A::TA&> is treated as B<int&>.  This was failing in this
case because the middle end was giving the two types different TYPE_CANONICAL. 
I guess we need to work harder at stripping the attributes.

Reply via email to