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

Trailing comma in enum causes compiler error #12

Closed
tkralphs opened this issue Sep 12, 2015 · 2 comments
Closed

Trailing comma in enum causes compiler error #12

tkralphs opened this issue Sep 12, 2015 · 2 comments

Comments

@tkralphs
Copy link
Member

The trailing comma in the enum here causes an error with gcc when called -pedantic-errors.

@bradbell
Copy link
Contributor

I see why this error was not caught by my testing. When you compile using g++ 5.1.1 with
-Wall -ansi -pedantic-errors -Wshadow -g
you get the warning, but with
-Wall -ansi -pedantic-errors -Wshadow -g -std=c++11
you do not. I guess that the C++11 standard allows for trailing commas like this ?

I have tested and check in the change to github; see
3bf661d
but there seems to be a problem with the coin svn server. I will send you and Matt a separate message about that.

@tkralphs
Copy link
Member Author

Indeed, there is a pretty precise analysis here. Thanks for the fix.

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