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

[PROF-6288] Enable -Werror to turn compiler warnings into errors in CI #2358

Merged
merged 1 commit into from
Nov 10, 2022

Commits on Nov 9, 2022

  1. [PROF-6288] Enable -Werror to turn compiler warnings into errors in CI

    **What does this PR do?**:
    
    This PR enables the `-Werror` compiler flag, which turns any
    compiler warnings into errors, when compiling profiler C code in CI.
    
    I also refreshed the `extconf.rb` for the
    `ddtrace_profiling_loader` to match the compiler flags from
    `ddtrace_profiling_native_extension` as well.
    
    **Motivation**:
    
    Most compiler warnings are quite useful at point out potential bugs,
    and we want to make sure our code is warning-free on all Ruby
    versions we support.
    
    **Additional Notes**:
    
    We don't enable `-Werror` always because we can't control what
    compiler our customers use. E.g. they may use a new compiler which
    introduces a new warning which we haven't seen and it doesn't
    make sense to "break" profiling for them just because of that.
    
    **How to test the change?**:
    
    Check that CI is still green.
    ivoanjo committed Nov 9, 2022
    Configuration menu
    Copy the full SHA
    13f7c9b View commit details
    Browse the repository at this point in the history