Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

internal error when a qc function is called with an empty parameter #185

Open
terencehill opened this issue Feb 10, 2018 · 2 comments
Open

Comments

@terencehill
Copy link
Contributor

In this function call the last parameter is missing (it was a string):

    o = drawsprite_TextOrIcon(true, o, M_PI, (SPRITE_HEALTHBAR_WIDTH + 2 * SPRITE_HEALTHBAR_BORDER) * t, rgb, a, waypointsprite_fontsize * '1 1 0', txt,);
./common/turrets/cl_turrets.qc:183:148: error: internal error: parameter count mismatch: (zu+1+zu), zu
./common/turrets/cl_turrets.qc:183:148: error: there have been errors, bailing out

qc statement is wrong but gmqcc doesn't handle it properly

@graphitemaster
Copy link
Owner

This just looks like the mingw builds are linking against a really old version of msvcrt so it's not printing the # of parameters correctly (%zu is a C99 thing (and also C++11), and vsnprintf in older versions didn't support this format specifier.)

@graphitemaster
Copy link
Owner

In either case, I agree that this should not be classified as an ICE but rather a semantic failure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants