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++/45697] __restrict__ inconsistent in presence of typedefs


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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |SUSPENDED
                 CC|                            |jason at gcc dot gnu.org

--- Comment #2 from Jason Merrill <jason at gcc dot gnu.org> 2011-07-08 14:53:33 UTC ---
C++ ignores inappropriate cv-qualifications introduced through the use of a
typedef or template type parameter:

int i;
typedef int& IR;
IR const ir1 = i; // OK
int& const ir2 = i; // error

G++ is treating restrict the same way.  It's not clear to me that this is the
right thing to do, but it's not clear that it's wrong, either.


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