Просмотр исходного кода

Restoring authorship annotation for <trifon@yandex-team.ru>. Commit 2 of 2.

trifon 3 лет назад
Родитель
Сommit
dd6b55b117

+ 19 - 19
library/cpp/uri/assign.cpp

@@ -1,6 +1,6 @@
 #include "uri.h"
 #include "parse.h"
- 
+
 #include <contrib/libs/libidn/idna.h>
 
 #include <library/cpp/charset/recyr.hh>
@@ -9,7 +9,7 @@
 #include <util/string/cast.h>
 #include <util/system/yassert.h>
 #include <util/system/sys_alloc.h>
- 
+
 namespace NUri {
     TMallocPtr<char> TUri::IDNToAscii(const wchar32* idna) {
         // XXX: don't use punycode_encode directly as it doesn't include
@@ -138,18 +138,18 @@ namespace NUri {
 
         const TSection& scheme = parser.Get(FieldScheme);
         const TSchemeInfo& schemeInfo = SetSchemeImpl(parser.Scheme);
- 
+
         // set the scheme always if available
         if (schemeInfo.Str.empty() && scheme.IsSet())
             FldSet(FieldScheme, scheme.Get());
- 
+
         if (ParsedOK != ret)
             return ret;
- 
+
         size_t buflen = 0;
- 
+
         // special processing for fields
- 
+
         const bool convertIDN = parser.Flags & FeatureConvertHostIDN;
         long flags = parser.Flags.Allow;
         if (convertIDN)
@@ -196,7 +196,7 @@ namespace NUri {
         // https://developers.google.com/webmasters/ajax-crawling/docs/specification
 
         static const TStringBuf escFragPrefix(TStringBuf("_escaped_fragment_="));
- 
+
         bool encHashBangFrag = false;
         TStringBuf qryBeforeEscapedFragment;
         TStringBuf qryEscapedFragment;
@@ -250,7 +250,7 @@ namespace NUri {
 
             if (FieldFrag == fld && qryEscapedFragment.IsInited())
                 continue;
- 
+
             char* beg = out.Buf();
             TStringBuf val = section.Get();
             long careFlags = section.GetFlagsEncode();
@@ -299,7 +299,7 @@ namespace NUri {
 
                 Y_ASSERT(beg >= out.Beg());
                 out.SetPos(end);
-            } 
+            }
 
             FldSetNoDirty(fld, TStringBuf(beg, end));
 
@@ -312,8 +312,8 @@ namespace NUri {
             }
 
             out << '\0';
-        } 
- 
+        }
+
         if (hostConverted) {
             char* beg = out.Buf();
             out << hostascii;
@@ -322,7 +322,7 @@ namespace NUri {
             FldSetNoDirty(fld, TStringBuf(beg, end));
             out << '\0';
         }
- 
+
         Buffer.Resize(out.Len());
 
         if (GetScheme() == SchemeEmpty && SchemeEmpty != defscheme) {
@@ -330,7 +330,7 @@ namespace NUri {
                 ret = ParsedBadScheme;
             else
                 SetSchemeImpl(defscheme);
-        } 
+        }
 
         if (0 == (parser.Flags & FeatureAllowEmptyPath))
             CheckMissingFields();
@@ -340,7 +340,7 @@ namespace NUri {
             if (!TryFromString<ui16>(port, Port))
                 ret = ParsedBadPort;
         }
- 
+
         if (ParsedOK != ret)
             return ret;
 
@@ -370,7 +370,7 @@ namespace NUri {
 
         if (url.empty())
             return ParsedEmpty;
- 
+
         if (maxlen > 0 && url.length() > maxlen)
             return ParsedTooLong;
 
@@ -392,7 +392,7 @@ namespace NUri {
                 return ret;
             Merge(base, PathOperationFlag(flags));
         }
- 
+
         Rewrite();
         return ret;
     }
@@ -408,7 +408,7 @@ namespace NUri {
         Rewrite();
         return ret;
     }
- 
+
     TState::EParsed TUri::ParseAbsUri(const TStringBuf& url, const TParseFlags& flags, ui32 maxlen, TScheme::EKind defscheme, ECharset enc) {
         const TState::EParsed ret = ParseImpl(
             url, flags | FeatureNoRelPath, maxlen, defscheme, enc);
@@ -417,7 +417,7 @@ namespace NUri {
 
         if (IsNull(FlagHost))
             return ParsedBadHost;
- 
+
         Rewrite();
         return ParsedOK;
     }

+ 23 - 23
library/cpp/uri/common.h

@@ -1,5 +1,5 @@
 #pragma once
- 
+
 #include <util/stream/output.h>
 #include <util/system/compat.h>
 #include <util/generic/strbuf.h>
@@ -10,7 +10,7 @@ namespace NUri {
         class TEncodeMapperBase;
         struct TCharFlags;
     }
- 
+
     namespace NParse {
         class TRange;
     }
@@ -60,7 +60,7 @@ namespace NUri {
             FIELD_FLAG(UrlMAX),
             FIELD_FLAG(HostAscii),
             FIELD_FLAG(AllMAX),
- 
+
             FlagHostPort = FlagHost | FlagPort,
             FlagAuth = FlagUser | FlagPass,
             FlagFragment = FlagFrag,
@@ -92,8 +92,8 @@ namespace NUri {
             // add before this line
             ParsedMAX
         };
-    }; 
- 
+    };
+
     struct TScheme {
         // don't forget to define a SchemeRegistry entry
         enum EKind {
@@ -110,19 +110,19 @@ namespace NUri {
             ,
             SchemeUnknown
         };
-    }; 
- 
+    };
+
     class TFeature {
         friend class NEncode::TEncoder;
         friend class NEncode::TEncodeMapperBase;
         friend struct NEncode::TCharFlags;
         friend class TParser;
         friend class NParse::TRange;
- 
+
 #define FEATURE_NAME(f) _BitFeature##f
 #define FEATURE_FLAG_NAME(f) Feature##f
 #define FEATURE_FLAG(f) FEATURE_FLAG_NAME(f) = 1UL << FEATURE_NAME(f)
- 
+
     protected:
         enum EBit {
             //==============================
@@ -134,10 +134,10 @@ namespace NUri {
 
             // allows all known schemes in URL
             FEATURE_NAME(SchemeKnown),
- 
+
             // allows all schemes, not only known
             FEATURE_NAME(SchemeFlexible),
- 
+
             // allow opaque (RFC 2396) or rootless (RFC 3986) urls
             FEATURE_NAME(AllowRootless),
 
@@ -156,7 +156,7 @@ namespace NUri {
             // in scheme and host segments:
             // change upper case letters onto lower case ones
             FEATURE_NAME(ToLower),
- 
+
             // decode unreserved symbols
             FEATURE_NAME(DecodeUnreserved),
 
@@ -209,7 +209,7 @@ namespace NUri {
 
             // tries to fix errors (in particular, in fragment)
             FEATURE_NAME(TryToFix),
- 
+
             // check host for DNS compliance
             FEATURE_NAME(CheckHost),
 
@@ -228,7 +228,7 @@ namespace NUri {
 
             // robot interpreted network paths as BadFormat urls
             FEATURE_NAME(DenyNetworkPath),
- 
+
             // robot interprets URLs without a host as BadFormat
             FEATURE_NAME(RemoteOnly),
 
@@ -315,15 +315,15 @@ namespace NUri {
             FeaturesEncodeExtended = 0 | FeatureEncodeExtendedASCII | FeatureEncodeExtendedDelim,
 
             FeaturesEncode = 0 | FeatureEncodeForSQL | FeatureEncodeSpace | FeatureEncodeCntrl | FeatureEncodePercent | FeaturesEncodeExtended,
- 
+
             // these are not guaranteed to apply to a given field
 
             FeatureDecodeAllowed = 0 | FeatureDecodeUnreserved | FeatureDecodeFieldAllowed,
- 
+
             FeaturesMaybeDecode = 0 | FeaturesDecode | FeatureDecodeAllowed,
- 
+
             FeaturesMaybeEncode = 0 | FeaturesEncode,
- 
+
             FeaturesEncodeDecode = 0 | FeaturesMaybeEncode | FeaturesMaybeDecode,
 
             FeaturesAllEncoder = 0 | FeaturesEncodeDecode | FeatureDecodeANY | FeatureToLower | FeatureUpperEncoded | FeatureEncodeSpaceAsPlus,
@@ -333,12 +333,12 @@ namespace NUri {
 
             FeaturesDefault = 0 // it reproduces old parsedURL
                               | FeaturePathOperation | FeaturePathDenyRootParent | FeatureCheckHost,
- 
+
             // essentially allows all valid RFC urls and keeps them as-is
             FeaturesBare = 0 | FeatureAuthSupported | FeatureSchemeFlexible | FeatureAllowEmptyPath,
 
             FeaturesAll = 0 | FeatureAuthSupported | FeatureSchemeFlexible | FeatureCheckHost | FeaturesNormalizeSet,
- 
+
             // Deprecated, use FeaturesRecommended
             FeaturesRobotOld = 0
                                // http://tools.ietf.org/html/rfc3986#section-6.2.2
@@ -367,7 +367,7 @@ namespace NUri {
     static inline int strnicmp(const char* lt, const char* rt, size_t len) {
         return lt == rt ? 0 : ::strnicmp(lt, rt, len);
     }
- 
+
     static inline int CompareNoCasePrefix(const TStringBuf& lt, const TStringBuf& rt) {
         return strnicmp(lt.data(), rt.data(), rt.length());
     }
@@ -381,7 +381,7 @@ namespace NUri {
             return CompareNoCasePrefix(lt, rt);
         return lt.length() < rt.length() ? -1 : 1;
     }
- 
+
     class TSchemeInfo {
     public:
         const TScheme::EKind Kind;
@@ -413,7 +413,7 @@ namespace NUri {
         static ui16 GetDefaultPort(TScheme::EKind scheme) {
             return Get(scheme).Port;
         }
- 
+
     private:
         static const TSchemeInfo Registry[];
     };

+ 10 - 10
library/cpp/uri/encode.cpp

@@ -1,7 +1,7 @@
 #include "encode.h"
- 
+
 #include <util/generic/singleton.h>
- 
+
 namespace NUri {
     namespace NEncode {
 // http://tools.ietf.org/html/rfc3986#section-2.2
@@ -9,9 +9,9 @@ namespace NUri {
 #define SUBDELIMS0 "!$&'()*+,;="
 // http://tools.ietf.org/html/rfc3986#section-2.3
 #define UNRESERVED "-._~"
- 
+
 // now find subsets which can sometimes be decoded
- 
+
 // remove '#' which can't ever be decoded
 // don't mark anything allowed for pass (pass is completely encoded)
 // safe in path, qry, frag
@@ -73,7 +73,7 @@ namespace NUri {
             GetMutable('&').EncodeFld |= TField::FlagQuery;
             GetMutable('+').EncodeFld |= TField::FlagQuery;
         }
- 
+
         // should we decode an encoded character
         bool TCharFlags::IsDecode(ui32 fldmask, ui64 flags) const {
             const ui64 myflags = flags & FeatFlags;
@@ -162,7 +162,7 @@ namespace NUri {
                 Encode(out, val[i]);
             return out;
         }
- 
+
         IOutputStream& TEncoder::EncodeNotAlnum(IOutputStream& out, const TStringBuf& val) {
             for (size_t i = 0; i != val.length(); ++i) {
                 const char c = val[i];
@@ -186,7 +186,7 @@ namespace NUri {
             }
             return out;
         }
- 
+
         IOutputStream& TEncoder::EncodeField(
             IOutputStream& out, const TStringBuf& val, TField::EField fld, ui64 flags) {
             const ui32 fldmask = ui32(1) << fld;
@@ -199,10 +199,10 @@ namespace NUri {
             }
             return out;
         }
- 
+
         void TEncoder::Do(unsigned char ch, int res) {
             OutFlags |= GetFlags(ch).FeatFlags;
- 
+
             bool escapepct = false;
             if (0 < res) // definitely encode
                 escapepct = FldDst.Enabled();
@@ -217,4 +217,4 @@ namespace NUri {
             Hex(Out, ch);
         }
     }
-} 
+}

+ 17 - 17
library/cpp/uri/encode.h

@@ -3,12 +3,12 @@
 #include "common.h"
 
 #include <util/stream/output.h>
- 
+
 namespace NUri {
     namespace NEncode {
 #define CHAR_TYPE_NAME(f) _ECT##f
 #define CHAR_TYPE_FLAG(f) ECF##f = 1u << CHAR_TYPE_NAME(f)
- 
+
         enum ECharType {
             CHAR_TYPE_NAME(Digit),
             CHAR_TYPE_NAME(Lower),
@@ -29,10 +29,10 @@ namespace NUri {
             ECGUnres = ECGAlnum | ECFUnres,
             ECGStdrd = ECGUnres | ECFStdrd,
         };
- 
+
 #undef CHAR_TYPE_NAME
 #undef CHAR_TYPE_FLAG
- 
+
         struct TCharFlags {
             ui32 TypeFlags;
             ui64 FeatFlags;
@@ -135,7 +135,7 @@ namespace NUri {
             static bool IsType(unsigned char c, ui64 flags) {
                 return GetFlags(c).TypeFlags & flags;
             }
- 
+
         public:
             static bool IsDigit(unsigned char c) {
                 return IsType(c, ECFDigit);
@@ -158,7 +158,7 @@ namespace NUri {
             static const TCharFlags& GetFlags(unsigned char c) {
                 return Grammar().Get(c);
             }
- 
+
         public:
             // process an encoded string, decoding safe chars and encoding unsafe
             static IOutputStream& ReEncode(IOutputStream& out, const TStringBuf& val, const TEncodeMapper& srcfld) {
@@ -169,13 +169,13 @@ namespace NUri {
                 TEncoder(out, srcfld, dstfld).ReEncode(val);
                 return out;
             }
- 
+
             // see also UrlUnescape() from string/quote.h
             static IOutputStream& Decode(
                 IOutputStream& out, const TStringBuf& val, ui64 flags) {
                 return ReEncode(out, val, flags | TFeature::FeatureDecodeANY);
             }
- 
+
         public:
             // process a raw string or char, encode as needed
             static IOutputStream& Hex(IOutputStream& out, unsigned char val);
@@ -185,18 +185,18 @@ namespace NUri {
             }
             static IOutputStream& EncodeAll(IOutputStream& out, const TStringBuf& val);
             static IOutputStream& EncodeNotAlnum(IOutputStream& out, const TStringBuf& val);
- 
+
             static IOutputStream& EncodeField(IOutputStream& out, const TStringBuf& val, TField::EField fld);
             static IOutputStream& EncodeField(IOutputStream& out, const TStringBuf& val, TField::EField fld, ui64 flags);
 
             static IOutputStream& Encode(IOutputStream& out, const TStringBuf& val) {
                 return EncodeField(out, val, TField::FieldAllMAX);
             }
- 
+
             static IOutputStream& Encode(IOutputStream& out, const TStringBuf& val, ui64 flags) {
                 return EncodeField(out, val, TField::FieldAllMAX, flags);
             }
- 
+
         public:
             class TGrammar {
                 TCharFlags Map_[256];
@@ -239,12 +239,12 @@ namespace NUri {
             const TEncodeToMapper FldDst;
             ui64 OutFlags;
             int HexValue;
- 
+
         protected:
             void HexReset() {
                 HexValue = 0;
             }
- 
+
             void HexDigit(char c) {
                 HexAdd(c - '0');
             }
@@ -254,7 +254,7 @@ namespace NUri {
             void HexLower(char c) {
                 HexAdd(c - 'a' + 10);
             }
- 
+
             void HexAdd(int val) {
                 HexValue <<= 4;
                 HexValue += val;
@@ -275,8 +275,8 @@ namespace NUri {
             }
             void Do(unsigned char, int);
         };
-    } 
+    }
 
     using TEncoder = NEncode::TEncoder;
- 
-} 
+
+}

+ 15 - 15
library/cpp/uri/encodefsm.rl6

@@ -1,5 +1,5 @@
 #include <library/cpp/uri/encode.h>
- 
+
 #ifdef __clang__
     #pragma clang diagnostic ignored "-Wunused-variable"
 #endif
@@ -7,45 +7,45 @@
 namespace NUri {
 namespace NEncode {
 
-%%{ 
+%%{
     machine TEncoder;
- 
+
     hex = (
         digit >{ HexDigit(fc); } |
         [A-F] >{ HexUpper(fc); } |
         [a-f] >{ HexLower(fc); }
     );
- 
+
     escaped = ( "%" hex hex )
             > { HexReset(); }
             % { DoHex(); };
- 
+
     bad_escaped = ( "%" hex )
                 % {
                       DoSym(*(fpc - 2));
                       DoSym(*(fpc - 1));
                   };
- 
+
     sym = (any - bad_escaped - escaped) %{ DoSym(*(fpc - 1)); };
- 
+
     main := ( escaped | bad_escaped | sym )**;
 
     write data;
-}%% 
- 
+}%%
+
 ui64 TEncoder::ReEncode(const TStringBuf &url)
-{ 
+{
     const char *p  = url.data();
     const char *pe = p + url.length();
     const char *eof = pe;
-    int cs; 
+    int cs;
     OutFlags = 0;
- 
-    %% write init; 
-    %% write exec; 
+
+    %% write init;
+    %% write exec;
 
     return OutFlags;
-} 
+}
 
 }
 }

+ 7 - 7
library/cpp/uri/http_url.h

@@ -1,26 +1,26 @@
 #pragma once
- 
+
 #include "uri.h"
 #include "other.h"
 
 // XXX: use NUri::TUri directly; this whole file is for backwards compatibility
 
-class THttpURL 
+class THttpURL
    : public NUri::TUri {
 public:
     typedef TField::EFlags TFlags;
     typedef TField::EField TField;
     typedef TScheme::EKind TSchemeKind;
     typedef TState::EParsed TParsedState;
- 
+
 public:
     enum {
         FeatureUnescapeStandard = TFeature::FeatureDecodeStandard,
         FeatureEscSpace = TFeature::FeatureEncodeSpaceAsPlus,
         FeatureEscapeUnescaped = TFeature::FeatureEncodeExtendedASCII,
         FeatureNormalPath = TFeature::FeaturePathStripRootParent,
-    }; 
- 
+    };
+
 public:
     THttpURL(unsigned defaultPort = 80)
         : TUri(defaultPort)
@@ -31,7 +31,7 @@ public:
         : TUri(host, port, path, query, scheme, defaultPort)
     {
     }
- 
+
     THttpURL(const TUri& url)
         : TUri(url)
     {
@@ -67,7 +67,7 @@ public: // use TUri::FldXXX methods for better control
     void Reset(EField field) {
         FldClr(field);
     }
-}; 
+};
 
 static inline const char* HttpURLParsedStateToString(const NUri::TState::EParsed& t) {
     return NUri::ParsedStateToString(t);

+ 2 - 2
library/cpp/uri/other.cpp

@@ -3,8 +3,8 @@
 #include <util/string/util.h>
 #include <util/system/yassert.h>
 
-/********************************************************/ 
-/********************************************************/ 
+/********************************************************/
+/********************************************************/
 
 static const Tr InvertTr(".:/?#", "\005\004\003\002\001");
 static const Tr RevertTr("\005\004\003\002\001", ".:/?#");

+ 2 - 2
library/cpp/uri/other.h

@@ -1,7 +1,7 @@
 #pragma once
- 
+
 #include <util/generic/string.h>
- 
+
 // Some functions for inverted url representation
 // No scheme cut-off, no 80th port normalization
 

+ 16 - 16
library/cpp/uri/parse.cpp

@@ -1,24 +1,24 @@
 #include "parse.h"
 #include "common.h"
 #include "encode.h"
- 
+
 namespace NUri {
     const TParseFlags TParser::FieldFlags[] =
         {
             TParseFlags(0 // FieldScheme
                             | TFeature::FeatureToLower,
                         0)
- 
+
                 ,
             TParseFlags(0 // FieldUsername
                             | TFeature::FeatureDecodeANY | TFeature::FeaturesDecode | TFeature::FeatureEncodePercent,
                         0 | TFeature::FeatureToLower)
- 
+
                 ,
             TParseFlags(0 // FieldPassword
                             | TFeature::FeatureDecodeANY | TFeature::FeaturesDecode | TFeature::FeatureEncodePercent,
                         0 | TFeature::FeatureToLower)
- 
+
                 ,
             TParseFlags(0 // FieldHost
                             | TFeature::FeatureToLower | TFeature::FeatureUpperEncoded | (TFeature::FeaturesMaybeEncode & ~TFeature::FeatureEncodeExtendedDelim),
@@ -57,7 +57,7 @@ namespace NUri {
             if (mask & TFeature::FeaturesDecode)
                 Decode += range.Decode;
         }
- 
+
     }
 
     void TParser::copyRequirementsImpl(const char* ptr) {
@@ -89,8 +89,8 @@ namespace NUri {
             section.AddRange(CurRange, GetFieldFlags(fld));
         }
         CurRange.Reset();
-    } 
- 
+    }
+
     void TParser::PctEndImpl(const char* ptr) {
 #ifdef DO_PRN
         PrintHead(PctBegin, __FUNCTION__);
@@ -111,10 +111,10 @@ namespace NUri {
         PctBegin = nullptr;
         const unsigned char ch = HexValue;
         ui64 flags = TEncoder::GetFlags('%').FeatFlags | TEncoder::GetFlags(ch).FeatFlags;
- 
+
         setRequirementExcept(ptr, flags, TFeature::FeaturesMaybeEncode);
     }
- 
+
     TState::EParsed TParser::ParseImpl() {
 #ifdef DO_PRN
         PrintHead(UriStr.data(), "[Parsing]") << "URL";
@@ -142,7 +142,7 @@ namespace NUri {
 
         if ((Flags & TFeature::FeatureDenyNetworkPath) && IsNetPath())
             return TState::ParsedBadFormat;
- 
+
         const TSection& scheme = Sections[TField::FieldScheme];
         Scheme = scheme.IsSet() ? TSchemeInfo::GetKind(scheme.Get()) : TScheme::SchemeEmpty;
         const TSchemeInfo& schemeInfo = TSchemeInfo::Get(Scheme);
@@ -157,7 +157,7 @@ namespace NUri {
 
             if (Flags & TFeature::FeatureAllowRootless)
                 return TState::ParsedOK;
- 
+
             if (!(Flags & TFeature::FeatureSchemeFlexible))
                 return TState::ParsedBadScheme;
 
@@ -166,16 +166,16 @@ namespace NUri {
 
         checkSectionCollision(TField::FieldUser, TField::FieldHost);
         checkSectionCollision(TField::FieldPass, TField::FieldPort);
- 
+
         if (0 == (Flags & TFeature::FeatureAuthSupported))
             if (Sections[TField::FieldUser].IsSet() || Sections[TField::FieldPass].IsSet())
                 return TState::ParsedBadAuth;
- 
+
         TSection& host = Sections[TField::FieldHost];
         if (host.IsSet())
             for (; host.End != host.Beg && '.' == host.End[-1];)
                 --host.End;
- 
+
         if (scheme.IsSet()) {
             ui64 wantCareFlags = 0;
             switch (Scheme) {
@@ -193,7 +193,7 @@ namespace NUri {
                         TFeature::FeatureSchemeFlexible | TFeature::FeatureSchemeKnown;
                     break;
             }
- 
+
             if (0 != wantCareFlags && 0 == (Flags & wantCareFlags))
                 return TState::ParsedBadScheme;
             if ((schemeInfo.FldReq & TField::FlagHost) || (Flags & TFeature::FeatureRemoteOnly))
@@ -204,4 +204,4 @@ namespace NUri {
         return TState::ParsedOK;
     }
 
-} 
+}

+ 13 - 13
library/cpp/uri/parse.h

@@ -1,17 +1,17 @@
 #pragma once
- 
+
 // #define DO_PRN
- 
+
 #include <cstddef>
 
 #include "common.h"
- 
+
 #include <library/cpp/charset/doccodes.h>
 #include <util/generic/strbuf.h>
 #include <util/stream/output.h>
 #include <util/string/cast.h>
 #include <util/system/yassert.h>
- 
+
 namespace NUri {
     class TParser;
 
@@ -123,12 +123,12 @@ namespace NUri {
             End = pc;
             return true;
         }
- 
+
         void Set(const TStringBuf& buf) {
             Enter(buf.data());
             Leave(buf.data() + buf.length());
         }
- 
+
     public:
         bool IsSet() const {
             return End;
@@ -191,7 +191,7 @@ namespace NUri {
                      || TFeature::FeaturesPath != (Flags & TFeature::FeaturesPath));
             State = ParseImpl();
         }
- 
+
     public:
         const TSection& Get(TField::EField fld) const {
             return Sections[fld];
@@ -253,7 +253,7 @@ namespace NUri {
 #endif
             Sections[fld].Reset(pc);
         }
- 
+
         void storeSection(const TStringBuf& val, TField::EField fld) {
 #ifdef DO_PRN
             PrintHead(val.data(), __FUNCTION__, fld);
@@ -270,7 +270,7 @@ namespace NUri {
             copyRequirements(pc);
             Sections[fld].Enter(pc);
         }
- 
+
         void finishSection(const char* pc, TField::EField fld) {
 #ifdef DO_PRN
             PrintHead(pc, __FUNCTION__, fld);
@@ -279,7 +279,7 @@ namespace NUri {
             if (Sections[fld].Leave(pc))
                 copyRequirements(pc);
         }
- 
+
         void setRequirement(const char* ptr, ui64 flags) {
 #ifdef DO_PRN
             PrintHead(ptr, __FUNCTION__) << IntToString<16>(flags)
@@ -315,7 +315,7 @@ namespace NUri {
             if (nullptr != CurRange.Beg && CurRange.Beg != ptr)
                 copyRequirementsImpl(ptr);
         }
- 
+
         void HexDigit(const char* ptr, char c) {
             Y_UNUSED(ptr);
             HexAdd(c - '0');
@@ -336,7 +336,7 @@ namespace NUri {
             HexValue = 0;
         }
         void HexSet(const char* ptr);
- 
+
         void PctEndImpl(const char* ptr);
         void PctEnd(const char* ptr) {
             if (nullptr != PctBegin && ptr != PctBegin)
@@ -358,4 +358,4 @@ namespace NUri {
         TState::EParsed ParseImpl();
     };
 
-} 
+}

Некоторые файлы не были показаны из-за большого количества измененных файлов