Deprecation warnings and warnings as errors

I generally enable warnings_as_errors in order to have the compiler fail hard in situations like invoking non-existing remote functions.
This worked well, until I started using @deprecated. As far as I see it, I now have to choose between the following two:

  1. Keep warnings as errors, and accept that @deprecated will cause compilation errors.
  2. Treat warnings as warnings, meaning that @deprecated will only be a warning. But so will invocations of non-existing functions.

Is there a middle-ground I am missing? Where I can have warnings for deprecations, but errors for invoking non-existing remote functions.

The middleground is soft deprecation using @doc deprecated: "…", but I’m not sure you’ll see those when compiling.

1 Like

That will do it, thanks.

It would be nice to be able to differentiate between warnings (unused variables vs. invoking non-existing remote functions, for instance). But I guess that will open a can of worms and/or a substantial set of compiler options (which wouldn’t really make anyones life easier) :slight_smile: