I didn't think TR1 had an array type. But anyways, I was focusing on C++0x (C++11). The CreateType() function was named thus because I already had an A struct in my test.cpp file, but I didn't include that struct in the post and didn't change the function name. For the array, I have to have: template<template <typename T, std::size_t Size> class Array> ... Instead of (I tried this one): template<template <typename T, int Size> class Array> ... With the second piece of code, the compiler's error messages just aren't very helpful. The first one, though, works. |
| Response Title | Author and Date |
| * I'm no genius. Just remember that arrays can't have sizes < 0. ;) | ChronoKitsune on Feb 23 |