Fix parsing of empty parentheses

This commit is contained in:
Filyus 2024-05-11 13:04:07 +05:00
parent f62202198e
commit 1af5240455

View File

@ -1006,8 +1006,14 @@ int main(int argc, char* argv[])
{
funcEnd = c + 2;
// Check if previous word is void
if ((linePtr[c - 4] == 'v') && (linePtr[c - 3] == 'o') && (linePtr[c - 2] == 'i') && (linePtr[c - 1] == 'd')) break;
// Check if there are no parameters
if ((funcEnd - funcParamsStart == 2) ||
((linePtr[c - 4] == 'v') &&
(linePtr[c - 3] == 'o') &&
(linePtr[c - 2] == 'i') &&
(linePtr[c - 1] == 'd'))) {
break;
}
// Get parameter type + name, extract info
char funcParamTypeName[128] = { 0 };