Ignore:
Timestamp:
Mar 11, 2018, 9:30:05 AM (15 months ago)
Author:
cameron
Message:

Unicode-lines option; set default linebreak to LF

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/icgrep.cpp

    r5894 r5900  
    3737static cl::list<std::string> inputFiles(cl::Positional, cl::desc("<regex> <input file ...>"), cl::OneOrMore);
    3838
    39 static cl::opt<bool> UnixBreaks("Unix-line-breaks", cl::desc("Enable Unix line breaks"));
    4039static cl::opt<bool> ByteMode("enable-byte-mode", cl::desc("Process regular expressions in byte mode"));
    4140
     
    198197    }
    199198               
    200     if (UnixBreaks) {
    201         grepEngine->setRecordBreak(grep::GrepRecordBreakKind::LF);
     199    if (grep::UnicodeLinesFlag) {
     200        grepEngine->setRecordBreak(grep::GrepRecordBreakKind::Unicode);
    202201    } else if (grep::NullDataFlag) {
    203202        grepEngine->setRecordBreak(grep::GrepRecordBreakKind::Null);
     203    } else {
     204        grepEngine->setRecordBreak(grep::GrepRecordBreakKind::LF);
    204205    }
    205206   
Note: See TracChangeset for help on using the changeset viewer.