# HG changeset patch # User Michael Goffioul # Date 1319111692 -3600 # Node ID b1186adb567e9c21b6b812cbfa6cea28ea43fd5e # Parent f8bef53122c84cd59c6955760ce3929e70e387fa Add dummy template specializations with a return value. * ov.h (DEF_DUMMY_VALUE_EXTRACTOR): New macro. Use it for specialization with char and octave_value. diff -r f8bef53122c8 -r b1186adb567e src/ov.h --- a/src/ov.h Thu Oct 20 12:54:46 2011 +0100 +++ b/src/ov.h Thu Oct 20 12:54:52 2011 +0100 @@ -1371,4 +1371,13 @@ DEF_VALUE_EXTRACTOR (SparseBoolMatrix, sparse_bool_matrix) #undef DEF_VALUE_EXTRACTOR +#define DEF_DUMMY_VALUE_EXTRACTOR(VALUE,DEFVAL) \ +template<> \ +inline VALUE octave_value_extract (const octave_value& v) \ + { assert (false); return DEFVAL; } + +DEF_DUMMY_VALUE_EXTRACTOR (char, 0) +DEF_DUMMY_VALUE_EXTRACTOR (octave_value, octave_value ()) +#undef DEF_DUMMY_VALUE_EXTRACTOR + #endif