mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 14:45:14 +00:00
Xcode build now uses codegen_style/numbers. Xcode projects created.
This commit is contained in:
@@ -49,7 +49,7 @@ bool isWhitespaceChar(char ch) {
|
||||
}
|
||||
|
||||
Token invalidToken() {
|
||||
return { Type::Invalid, QString(), ConstUtf8String(nullptr, 0) };
|
||||
return { Type::Invalid, QString(), ConstUtf8String(nullptr, 0), false };
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
@@ -40,8 +40,9 @@ bool readFile(const QString &filepath, QByteArray *outResult) {
|
||||
logError(kErrorFileNotFound, filepath) << ": error: file does not exist.";
|
||||
return false;
|
||||
}
|
||||
if (f.size() > CleanFile::MaxSize) {
|
||||
logError(kErrorFileTooLarge, filepath) << "' is too large, size=" << f.size() << " > maxsize=" << CleanFile::MaxSize;
|
||||
auto limit = CleanFile::MaxSize;
|
||||
if (f.size() > limit) {
|
||||
logError(kErrorFileTooLarge, filepath) << "' is too large, size=" << f.size() << " > maxsize=" << limit;
|
||||
return false;
|
||||
}
|
||||
if (!f.open(QIODevice::ReadOnly)) {
|
||||
|
@@ -48,7 +48,7 @@ QByteArray replaceStrings(const QString &filepath) {
|
||||
|
||||
QStringList lines = string.toString().split('\n');
|
||||
for (auto &line : lines) {
|
||||
auto match = QRegularExpression("^(\\d+;[A-Z]+;)([^;]+)(;.+)?$").match(line);
|
||||
auto match = QRegularExpression("^(\\d+;[A-Z]+;)([^;]+)(;.*)?$").match(line);
|
||||
if (match.hasMatch()) {
|
||||
line = match.captured(1) + '"' + match.captured(2) + '"' + match.captured(3);
|
||||
}
|
||||
|
Reference in New Issue
Block a user