mediawiki-extensions-AbuseF.../parser_native/evaluate.cpp
River Tarnell 365234b95f - add 'evaluate' tool, evaluates a filter on the command line
- remove filter_evaluator.cpp, no longer used
2008-08-09 16:44:54 +00:00

23 lines
660 B
C++

/*
* Copyright (c) 2008 Andrew Garrett.
* Copyright (c) 2008 River Tarnell <river@wikimedia.org>
* Derived from public domain code contributed by Victor Vasiliev.
*
* Permission is granted to anyone to use this software for any purpose,
* including commercial applications, and to alter it and redistribute it
* freely. This software is provided 'as-is', without any express or
* implied warranty.
*/
#include "filter_evaluator.h"
int main(int argc, char** argv) {
afp::u32filter_evaluator f;
try {
std::cout << f.evaluate(make_u32string(argv[1])) << '\n';
} catch (std::exception &e) {
std::cerr << "exception: " << e.what() << '\n';
}
}