source: icGREP/icgrep-devel/icgrep/re/re_analysis.h @ 6153

Last change on this file since 6153 was 6153, checked in by xwa163, 8 months ago

lz4_grep: 1. fix typo 2. analyse the requirement of u8 non final

File size: 1.2 KB
RevLine 
[4393]1#ifndef RE_ANALYSIS_H
2#define RE_ANALYSIS_H
3
[5267]4#include <utility>
[5682]5namespace re { class RE; class Name; class CC;}
[4393]6
7namespace re {
8
[5682]9// Does the RE match the empty string, considering that ^ and $ each
10// do match an empty string.
11bool matchesEmptyString(const RE * re);
12
13//  Determine the set of all codepoints cp such that the given RE
14//  matches a string consisting of a single Unicode character whose
15//  codepoint value is cp.
16const CC * matchableCodepoints(const RE * re);
17
[5267]18bool isByteLength(const RE * re);
[6130]19
20bool isAllCcByteLength(const RE * re);
[6153]21bool isRequireNonFinal(const RE * re, bool checkByteLength = true);
[4393]22   
[4829]23bool isUnicodeUnitLength(const RE * re);
[4393]24
[4829]25std::pair<int, int> getUnicodeUnitLengthRange(const RE * re);
26
[5951]27bool isFixedLength(const RE * re);
[4442]28
[5951]29int minMatchLength(const RE * re);
30
[5604]31bool unitBoundedRep(const RE * re);
32
33bool isTypeForLocal(const RE * re);
[5649]34   
[5723]35bool hasAssertion(const RE * re);
36   
[5902]37bool byteTestsWithinLimit(RE * re, unsigned limit);
[5891]38   
[5908]39bool hasTriCCwithinLimit(RE * r, unsigned byteCClimit, RE * & prefixRE, RE * & suffixRE);
40
[5910]41bool hasEndAnchor(const RE * r);
[5908]42   
[5951]43bool DefiniteLengthBackReferencesOnly(const RE * re);
44   
[5649]45void UndefinedNameError (const Name * n);
[4393]46}
47
48#endif // RE_ANALYSIS_H
Note: See TracBrowser for help on using the repository browser.