I have a function written in C++ and would like to generate a MEX file from it to use in MATLAB 7.13 (R2011b). The code uses the old SGI standard template library (STL).
However, when I try to compile, I get numerous errors such as:
.\stl_function.h(146) : warning C4346: '_Predicate::argument_type' : dependent name is not a type prefix with 'typename' to indicate a type .\stl_function.h(154) : see reference to class template instantiation 'std::unary_negate<_Predicate>' being compiled .\stl_function.h(146) : error C2923: 'std::unary_function' : '_Predicate::argument_type' is not a valid template type argument for parameter '_Arg' .\stl_function.h(146) : error C2955: 'std::unary_function' : use of class template requires template argument list .\stl_function.h(37) : see declaration of 'std::unary_function' .\stl_function.h(151) : warning C4346: '_Predicate::argument_type' : dependent name is not a type prefix with 'typename' to indicate a type .\stl_function.h(151) : error C2061: syntax error : identifier 'argument_type' .\iterator.h(38) : fatal error C1083: Cannot open include file: 'iostream.h': No such file or directory
and much more.
Best Answer