X-Git-Url: http://git.tdb.fi/?p=libs%2Fcore.git;a=blobdiff_plain;f=grep.cpp;h=c87ee72171615ec8056adcf687f8f0e74d78b621;hp=07743072be997253e83356cd5704ea414be7c282;hb=82f9f26dde92ea0e9714fd8878db8dad186ce7af;hpb=47df471884234130a2a27f0a5fc842df3f994a3e diff --git a/grep.cpp b/grep.cpp index 0774307..c87ee72 100644 --- a/grep.cpp +++ b/grep.cpp @@ -1,20 +1,19 @@ -/* $Id$ */ #include #include #include -#include "regex.h" +#include using namespace std; using namespace Msp; int main(int argc, char **argv) { - bool debug=false; + bool debug = false; GetOpt getopt; getopt.add_option('d', "debug", debug, GetOpt::NO_ARG); getopt(argc, argv); - const vector &args=getopt.get_args(); + const vector &args = getopt.get_args(); if(args.empty()) { @@ -28,7 +27,7 @@ int main(int argc, char **argv) string line; while(getline(cin, line)) { - if(RegMatch match=regex.match(line)) + if(RegMatch match = regex.match(line)) cout<