fork download
  1. template <typename T>
  2. class Foo {
  3. public:
  4. static double const vals[];
  5. int run ();
  6. };
  7.  
  8. template <typename T>
  9. double const Foo<T>::vals[] = { 1, 2,3 };
  10.  
  11. template <typename T>
  12. inline
  13. int Foo<T>::run () {
  14. return sizeof(vals); // error C2070: 'const double []': illegal sizeof operand
  15. }
  16.  
  17. int main() {}
Success #stdin #stdout 0.02s 2720KB
stdin
Standard input is empty
stdout

Standard output is empty