William Fulton - 2011-10-14

The expansion is failing in Swig_cparse_template_expand(). An expression evaluator needs to be added to SWIG in order to expand these integral constant expression template parameters (listed under template non-type arguments in the standard). If existing evaluator code/library can be used, it wouldn't be too much extra work to use it.

Suggested workaround is to add template specializations to SWIG so that the template parameters do not need to be evaluated, eg:

template <>
class B<1> : public A<0>
B(const A<0>& range) {}