|
@ -169,10 +169,12 @@ static FunctionInfo *funcs = NULL; |
|
|
// Command line variables |
|
|
// Command line variables |
|
|
static char apiDefine[32] = { 0 }; // Functions define (i.e. RLAPI for raylib.h, RMDEF for raymath.h, etc.) |
|
|
static char apiDefine[32] = { 0 }; // Functions define (i.e. RLAPI for raylib.h, RMDEF for raymath.h, etc.) |
|
|
static char truncAfter[32] = { 0 }; // Truncate marker (i.e. "RLGL IMPLEMENTATION" for rlgl.h) |
|
|
static char truncAfter[32] = { 0 }; // Truncate marker (i.e. "RLGL IMPLEMENTATION" for rlgl.h) |
|
|
static char inFileName[512] = { 0 }; // Input file name (required in case of provided through CLI) |
|
|
|
|
|
static char outFileName[512] = { 0 }; // Output file name (required for file save/export) |
|
|
|
|
|
static int outputFormat = DEFAULT; |
|
|
static int outputFormat = DEFAULT; |
|
|
|
|
|
|
|
|
|
|
|
// NOTE: Max length depends on OS, in Windows MAX_PATH = 256 |
|
|
|
|
|
static char inFileName[512] = { 0 }; // Input file name (required in case of drag & drop over executable) |
|
|
|
|
|
static char outFileName[512] = { 0 }; // Output file name (required for file save/export) |
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------- |
|
|
//---------------------------------------------------------------------------------- |
|
|
// Module Functions Declaration |
|
|
// Module Functions Declaration |
|
|
//---------------------------------------------------------------------------------- |
|
|
//---------------------------------------------------------------------------------- |
|
@ -499,7 +501,7 @@ int main(int argc, char* argv[]) |
|
|
(ch == '/') || |
|
|
(ch == '/') || |
|
|
(ch == ' ') || |
|
|
(ch == ' ') || |
|
|
(ch == '\t')) continue; |
|
|
(ch == '\t')) continue; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Read number operand |
|
|
// Read number operand |
|
|
else if (isdigit(ch)) |
|
|
else if (isdigit(ch)) |
|
|
{ |
|
|
{ |
|
@ -534,7 +536,7 @@ int main(int argc, char* argv[]) |
|
|
int numberType; |
|
|
int numberType; |
|
|
if (isFloat) numberType = valuePtr[c - 1] == 'f' ? FLOAT_MATH : DOUBLE_MATH; |
|
|
if (isFloat) numberType = valuePtr[c - 1] == 'f' ? FLOAT_MATH : DOUBLE_MATH; |
|
|
else numberType = valuePtr[c - 1] == 'L' ? LONG_MATH : INT_MATH; |
|
|
else numberType = valuePtr[c - 1] == 'L' ? LONG_MATH : INT_MATH; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (numberType > largestType) largestType = numberType; |
|
|
if (numberType > largestType) largestType = numberType; |
|
|
} |
|
|
} |
|
|
else |
|
|
else |
|
@ -654,7 +656,7 @@ int main(int argc, char* argv[]) |
|
|
{ |
|
|
{ |
|
|
if (structs[i].fieldName[originalIndex][c] == ',') additionalFields++; |
|
|
if (structs[i].fieldName[originalIndex][c] == ',') additionalFields++; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (additionalFields > 0) |
|
|
if (additionalFields > 0) |
|
|
{ |
|
|
{ |
|
|
int originalLength = -1; |
|
|
int originalLength = -1; |
|
@ -702,7 +704,7 @@ int main(int argc, char* argv[]) |
|
|
{ |
|
|
{ |
|
|
if (structs[i].fieldType[originalIndex][c] == ',') additionalFields++; |
|
|
if (structs[i].fieldType[originalIndex][c] == ',') additionalFields++; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (additionalFields > 0) |
|
|
if (additionalFields > 0) |
|
|
{ |
|
|
{ |
|
|
// Copy original name to last additional field |
|
|
// Copy original name to last additional field |
|
|