diff --git a/src/object/inheritance.cpp b/src/object/inheritance.cpp index b7258f8e..659b98f9 100644 --- a/src/object/inheritance.cpp +++ b/src/object/inheritance.cpp @@ -35,6 +35,7 @@ namespace boost { namespace { enum edge_cast_t { edge_cast = 8010 }; + template inline void unused_variable(const T&) { } } // Install properties @@ -215,7 +216,7 @@ namespace vertex_t v = add_vertex(full_graph().topology()); vertex_t v2 = add_vertex(up_graph().topology()); - (void)v2; // prevent unused var warning on non-debug compile + unused_variable(v2); assert(v == v2); return type_index().insert(p, boost::make_tuple(type, v, dynamic_id_function(0))); }