+#else // ndef NO_GINAC_NAMESPACE
+
+#define is_of_type(OBJ,TYPE) \
+ (dynamic_cast<TYPE *>(const_cast<basic *>(&OBJ))!=0)
+
+#define is_exactly_of_type(OBJ,TYPE) \
+ ((OBJ).tinfo()==TINFO_##TYPE)
+
+#define is_ex_of_type(OBJ,TYPE) \
+ (dynamic_cast<TYPE *>(const_cast<basic *>((OBJ).bp))!=0)
+
+#define is_ex_exactly_of_type(OBJ,TYPE) \
+ ((*(OBJ).bp).tinfo()==TINFO_##TYPE)
+
+#endif // ndef NO_GINAC_NAMESPACE
+
+#ifndef NO_GINAC_NAMESPACE