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

Allow suppression of cargo warning instructions in output #916

Closed
scootermon opened this issue Jan 13, 2024 · 1 comment · Fixed by #917
Closed

Allow suppression of cargo warning instructions in output #916

scootermon opened this issue Jan 13, 2024 · 1 comment · Fixed by #917

Comments

@scootermon
Copy link
Contributor

Right now cc allows for the suppression of specific cargo instructions using .cargo_metdata(false), but this doesn't affect the output of cargo:warning= lines.
I'm working on a bindings library which uses compilation tests to determine whether certain features are supported or not. CC already almost fully supports this use-case1, the only issue being that the warnings and errors show up as though they're part of the "main compilation".

Since I belive this feature is unrelated to the behaviour of cargo_metadata, how would you feel about adding a .cargo_warnings(false) setting that allows us to disable the warnings?
I'm of course happy to contribute the implementation.

Footnotes

  1. Shoutout to Expose function compile to an object file #912, which will also help here because it helps remove an otherwise unnecessary step from the compilation tests

@NobodyXu
Copy link
Collaborator

Yes I'm willing to review a PR disabling the warnings.

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

Successfully merging a pull request may close this issue.

2 participants