-/**
- * @file match_bug.cpp
+/** @file match_bug.cpp
*
- * Check for bug in GiNaC::ex::match() described here:
- * http://www.ginac.de/pipermail/ginac-devel/2006-April/000942.html
+ * Check for bug in GiNaC::ex::match() described here:
+ * http://www.ginac.de/pipermail/ginac-devel/2006-April/000942.html */
+
+/*
+ * GiNaC Copyright (C) 1999-2011 Johannes Gutenberg University Mainz, Germany
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+
#include "ginac.h"
-#include "error_report.hpp"
+#include "error_report.h"
+
#include <iostream>
using namespace GiNaC;
// obviously e does NOT match the pattern
exmap repls;
bool match_p = e.match(pattern, repls);
- bug_on(match_p, "match(" << e << ", " << pattern << ") says \"Yes\"");
- bug_on(repls.size() != 0,
+ cbug_on(match_p, "match(" << e << ", " << pattern << ") says \"Yes\"");
+ cbug_on(repls.size() != 0,
"failed match have side effects: repls = " << repls);
}
ex pattern = pow(wild(0), -1)*pow(x, wild(2));
exmap repls;
bool match_p = e.match(pattern, repls);
- bug_on(!match_p, "false negative: " << e << " did not match "
+ cbug_on(!match_p, "false negative: " << e << " did not match "
<< pattern);
}
std::cout << "not found. ";
return 0;
}
-