From 334c6c7f39a2a7f7324bd5f3a3a80e5309b54caa Mon Sep 17 00:00:00 2001 From: lazaray <104470294+lazaray@users.noreply.github.com> Date: Tue, 3 May 2022 15:46:26 +0200 Subject: [PATCH] Fix parser code style --- parser/raylib_parser.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/parser/raylib_parser.c b/parser/raylib_parser.c index 76c3d08d8..a141422c9 100644 --- a/parser/raylib_parser.c +++ b/parser/raylib_parser.c @@ -260,8 +260,8 @@ int main(int argc, char* argv[]) { char v = lines[i][c]; if (v == ' ') spaceCount++; - if (v == ';' && spaceCount == 2) validAlias = true; - if (v == ';' || v == '(' || v == '\0') break; + if ((v == ';') && (spaceCount == 2)) validAlias = true; + if ((v == ';') || (v == '(') || (v == '\0')) break; } if (!validAlias) continue; aliasLines[aliasCount] = i; @@ -273,7 +273,7 @@ int main(int argc, char* argv[]) for (int i = 0; i < linesCount; i++) { // Read enum line - if (IsTextEqual(lines[i], "typedef enum {", 14) && lines[i][TextLength(lines[i])-1] != ';') // ignore inline enums + if (IsTextEqual(lines[i], "typedef enum {", 14) && (lines[i][TextLength(lines[i])-1] != ';')) // ignore inline enums { // Keep the line position in the array of lines, // so, we can scan that position and following lines @@ -286,7 +286,7 @@ int main(int argc, char* argv[]) for (int i = 0; i < linesCount; i++) { int j = 0; - while (lines[i][j] == ' ' || lines[i][j] == '\t') j++; // skip spaces and tabs in the begining + while ((lines[i][j] == ' ') || (lines[i][j] == '\t')) j++; // skip spaces and tabs in the begining // Read define line if (IsTextEqual(lines[i]+j, "#define ", 8)) {