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

Typo in flatc options (warning-as-errors instead of warnings-as-errors) #7180

Merged
merged 1 commit into from
Mar 21, 2022

Conversation

stefan301
Copy link
Contributor

No description provided.

@github-actions github-actions bot added c++ codegen Involving generating code from schema labels Mar 21, 2022
@CasperN
Copy link
Collaborator

CasperN commented Mar 21, 2022

Hello, thanks for contributing.

  • You have to update opts.warnings_as_errors too, which is where the changed string is consumed

This is also a breaking change for people who use flatc in scripts. Can you:

  • Make a new flag with the correct spelling (instead of replacing the old one)
  • Add a TODO comment to delete the old flag in the next breaking release.
  • Update the old flag's description to say it's deprecated in favor of the new flag
  • Warn when the old flag is used

@stefan301
Copy link
Contributor Author

This was only a typo in flatc -h
The real option is already --warnings-as-error

      } else if (arg == "--warnings-as-errors") {
        opts.warnings_as_errors = true;

@CasperN
Copy link
Collaborator

CasperN commented Mar 21, 2022

sgtm

@CasperN CasperN merged commit 824763b into google:master Mar 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ codegen Involving generating code from schema
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants