aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs
diff options
context:
space:
mode:
authorkartynnik <kartynnik@yandex-team.ru>2022-02-10 16:48:07 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:48:07 +0300
commitdf6128370874866447314ec18d8e67fc7bde40b4 (patch)
treeb222e5ac2e2e98872661c51ccceee5da0d291e13 /contrib/libs
parentca2a705e6e39e85df30054d7e806e572de9cfe23 (diff)
downloadydb-df6128370874866447314ec18d8e67fc7bde40b4.tar.gz
Restoring authorship annotation for <kartynnik@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'contrib/libs')
-rw-r--r--contrib/libs/pire/pire/extra/count.cpp2
-rw-r--r--contrib/libs/pire/pire/inline.l10
-rw-r--r--contrib/libs/pire/pire/run.h18
3 files changed, 15 insertions, 15 deletions
diff --git a/contrib/libs/pire/pire/extra/count.cpp b/contrib/libs/pire/pire/extra/count.cpp
index c4aa3d62c1..468ff61d92 100644
--- a/contrib/libs/pire/pire/extra/count.cpp
+++ b/contrib/libs/pire/pire/extra/count.cpp
@@ -801,7 +801,7 @@ CountingScanner::CountingScanner(const Fsm& re, const Fsm& sep)
Y_ASSERT(!"Wrong transition size for backup");
NewState ns(*mr.begin(), *br.begin());
- PIRE_IFDEBUG(NewState savedNs = ns);
+ PIRE_IFDEBUG(NewState savedNs = ns);
unsigned long outputs = 0;
PIRE_IFDEBUG(ystring dbgout);
diff --git a/contrib/libs/pire/pire/inline.l b/contrib/libs/pire/pire/inline.l
index a79e857b77..a4d2e1a836 100644
--- a/contrib/libs/pire/pire/inline.l
+++ b/contrib/libs/pire/pire/inline.l
@@ -137,7 +137,7 @@ void eatComment(void (*action)(char));
Pire::Lexer lexer(i->c_str(), i->c_str() + i->size());
bool surround = false;
bool greedy = false;
- bool reverse = false;
+ bool reverse = false;
for (const char* option = (i+1)->c_str(); *option; ++option) {
if (*option == 'i')
lexer.AddFeature(Pire::Features::CaseInsensitive());
@@ -149,8 +149,8 @@ void eatComment(void (*action)(char));
lexer.AddFeature(Pire::Features::AndNotSupport());
else if (*option == 'g')
greedy = true;
- else if (*option == 'r')
- reverse = true;
+ else if (*option == 'r')
+ reverse = true;
else
Die() << "unknown option " << *option << "";
}
@@ -162,8 +162,8 @@ void eatComment(void (*action)(char));
catch (std::exception& e) {
Die() << "" << filename << ":" << line << ": " << e.what() << "";
}
- if (reverse)
- fsm.Reverse();
+ if (reverse)
+ fsm.Reverse();
if (greedy && surround)
Die() << "greedy and surround options are incompatible";
if (greedy)
diff --git a/contrib/libs/pire/pire/run.h b/contrib/libs/pire/pire/run.h
index b3d3f3fc4f..f6e1ff734d 100644
--- a/contrib/libs/pire/pire/run.h
+++ b/contrib/libs/pire/pire/run.h
@@ -11,7 +11,7 @@
* it under the terms of the GNU Lesser Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
- *
+ *
* Pire 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
@@ -68,7 +68,7 @@ namespace Impl {
PIRE_FORCED_INLINE PIRE_HOT_FUNCTION
Action operator()(const Scanner&, const typename Scanner::State&, const char*) const { return Continue; }
};
-
+
template<class Scanner>
struct ShortestPrefixPred {
explicit ShortestPrefixPred(const char*& pos): m_pos(&pos) {}
@@ -80,17 +80,17 @@ namespace Impl {
*m_pos = pos;
return Stop;
} else {
- return (sc.Dead(st) ? Stop : Continue);
+ return (sc.Dead(st) ? Stop : Continue);
}
}
private:
const char** m_pos;
};
-
+
template<class Scanner>
struct LongestPrefixPred {
explicit LongestPrefixPred(const char*& pos): m_pos(&pos) {}
-
+
PIRE_FORCED_INLINE PIRE_HOT_FUNCTION
Action operator()(const Scanner& sc, const typename Scanner::State& st, const char* pos) const
{
@@ -270,7 +270,7 @@ namespace Impl {
}
#endif
-
+
template<class Scanner>
void Run(const Scanner& sc, typename Scanner::State& st, TStringBuf str)
{
@@ -337,7 +337,7 @@ const char* ShortestPrefix(const Scanner& sc, const char* begin, const char* end
return prefix.data() + prefix.size();
}
-
+
/// The same as above, but scans string in reverse direction
/// (consider using Fsm::Reverse() for using in this function).
/// Returns default constructed string_view{} if there is no matching suffix
@@ -389,12 +389,12 @@ inline std::string_view ShortestSuffix(const Scanner& scanner, std::string_view
if (throughEndMark)
Step(scanner, state, EndMark);
PIRE_IFDEBUG(Cdbg << "Running ShortestSuffix on string " << ystring(str) << Endl);
- PIRE_IFDEBUG(Cdbg << "Initial state " << StDump(scanner, state) << Endl);
+ PIRE_IFDEBUG(Cdbg << "Initial state " << StDump(scanner, state) << Endl);
while (begin != str.data() && !scanner.Final(state) && !scanner.Dead(state)) {
--begin;
scanner.Next(state, (unsigned char)*begin);
- PIRE_IFDEBUG(Cdbg << *rbegin << " => state " << StDump(scanner, state) << Endl);
+ PIRE_IFDEBUG(Cdbg << *rbegin << " => state " << StDump(scanner, state) << Endl);
}
if (throughBeginMark)
Step(scanner, state, BeginMark);