Format all C++ and Java code via clang-format

Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
This commit is contained in:
Konstantin Pastbin
2025-08-17 14:32:37 +07:00
parent 9f0290c0ec
commit bfffa1fff4
2169 changed files with 56441 additions and 64188 deletions

View File

@@ -29,7 +29,6 @@ static size_t MatchZoneCode(std::string const & query, int & zoneCode)
return pos + 2;
}
// Matches zone letter ignoring spaces. Returns end position of matched chars or string::npos if no match.
size_t MatchZoneLetter(std::string const & query, char & zoneLetter, size_t startPos)
{
@@ -56,14 +55,14 @@ size_t MatchInt(std::string const & query, int & value, size_t startPos)
while (pos < query.size())
{
char const ch = query[pos];
if (ch >= '0' && ch <= '9') // Found digit
if (ch >= '0' && ch <= '9') // Found digit
{
n = n * 10 + (ch - '0');
pos++;
}
else if (kSpaceChars.find(ch) != std::string::npos) // Found space char matching end of the number
else if (kSpaceChars.find(ch) != std::string::npos) // Found space char matching end of the number
break;
else // Found invalid char
else // Found invalid char
return std::string::npos;
}
@@ -78,8 +77,8 @@ size_t MatchInt(std::string const & query, int & value, size_t startPos)
// TODO: Support additional formats listed here: https://www.killetsoft.de/t_0901_e.htm
std::optional<ms::LatLon> MatchUTMCoords(std::string const & query)
{
int easting, northing;
int zoneCode;
int easting, northing;
int zoneCode;
char zoneLetter;
size_t pos = MatchZoneCode(query, zoneCode);
@@ -206,4 +205,4 @@ std::optional<ms::LatLon> MatchMGRSCoords(std::string const & query)
return utm_mgrs_utils::MGRStoLatLon(easting, northing, zoneCode, zoneLetter, squareCode);
}
}
} // namespace search