]> www.ginac.de Git - ginac.git/blobdiff - ginac/fail.h
* Supplement some (now deprecated) macros by inlined template functions:
[ginac.git] / ginac / fail.h
index 5b9c2147f8ff1fb32eb776549e4a79e5f3f2f5b7..240509239851bdd68e4ec0810d9978fa07820a5f 100644 (file)
@@ -39,6 +39,12 @@ protected:
        unsigned return_type(void) const { return return_types::noncommutative_composite; };
 };
 
+/** Specialization of is_exactly_a<fail>(obj) for fail objects. */
+template<> inline bool is_exactly_a<fail>(const basic & obj)
+{
+       return obj.tinfo()==TINFO_fail;
+}
+
 } // namespace GiNaC
 
 #endif // ndef __GINAC_FAIL_H__