3

As part of CI testing, I'm byte-compiling package files to make sure there are no errors. I'd like to take this a step further and ensure there are no warnings, either (like 'function not known to be defined', etc.).

Is there a variable I can let-bind to make this happen? apropos was not very enlightening.

3
  • What do you mean exactly by "treat warnings as errors"? Are you asking for a way of having each byte-compiler warning raise an error?
    – Drew
    May 15, 2017 at 4:36
  • @Drew exactly. I want my test to fail if there are any byte-compile warnings. (By the way, I do thing package-development is appropriate here; this is part of the dev process.) May 15, 2017 at 6:15
  • 2
    Sounds like the equivalent of -Werror in contemporary C compilers to me.
    – wasamasa
    May 15, 2017 at 6:51

1 Answer 1

5

The documentation for the customisable variable byte-compile-error-on-warn says:

If true, the byte-compiler reports warnings with `error'.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.