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]

Re: static template specialization

[Get raw message]
Hi,

I'm not a language lawyer, but another compiler, known to be very close
to the standard, also finds many errors...

Cheers,
Paolo.


"18371.c", line 5: error: explicit specialization is not allowed in the
          current scope
    template<>
    ^

"18371.c", line 6: error: a storage class may not be specified here
      static int get(int) { return 1; }
      ^

"18371.c", line 7: error: explicit specialization is not allowed in the
          current scope
    template<>
    ^

"18371.c", line 8: error: a storage class may not be specified here
      static int get(double) { return 2; }
      ^

"18371.c", line 13: warning: variable "a" was declared but never
referenced
    A a;
      ^




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