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

Improve error message with unsupported cpp #4207

Open
mrgriffin opened this issue Feb 17, 2024 · 3 comments
Open

Improve error message with unsupported cpp #4207

mrgriffin opened this issue Feb 17, 2024 · 3 comments
Labels
bug Bug status: unconfirmed This bug has not been reproduced yet

Comments

@mrgriffin
Copy link
Collaborator

Description

Currently, if you have a cpp that's too old you get an error like this when compiling:

src/battle_main.c:338:84: error: expected expression before ',' token
  338 |     TRAINER_CLASS(HIKER, "HIKER", 10),

This has come up a few times on Discord, most recently today. It's not at all clear what the problem is, especially because the error message doesn't even say __VA_OPT__.

We could probably give a better error message by detecting __VA_OPT__ support in metaprogram.h, and using #error to give an explicit message rather than this very weird and confusing Hiker one.

Version

upcoming (Edge)

Upcoming/master Version

No response

Discord contact info

No response

@mrgriffin mrgriffin added bug Bug status: unconfirmed This bug has not been reproduced yet labels Feb 17, 2024
@mrgriffin mrgriffin added this to the 1.8.0 milestone Feb 17, 2024
@AsparagusEduardo
Copy link
Collaborator

#4272

@AsparagusEduardo
Copy link
Collaborator

Still has the issue:
#4272 (comment)

@AsparagusEduardo AsparagusEduardo modified the milestones: 1.8.0, 1.8.1, 1.8.2 Mar 24, 2024
@AsparagusEduardo AsparagusEduardo removed this from the 1.8.2 milestone May 5, 2024
@hedara90
Copy link
Collaborator

If the problem is with unsupported cpp, couldn't the version be detected and make process made to error out completely if support doesn't exist in that version?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug status: unconfirmed This bug has not been reproduced yet
Projects
None yet
Development

No branches or pull requests

3 participants