OxL Reference

warning deprecated

warning Standard: [§4.9]

What it means#

The item is marked @deprecated(msg) (§4.9, part II.3) and the code still uses it. The message explains the replacement. This is a warning, configurable in [lint].

Example#

oxl✓ checked in CI
@deprecated("use newApi")
fn oldApi() -> i32 => 1

fn main() {
  print("{oldApi()}")      // <- deprecated
}
error
deprecated

How to fix#

oxl✓ checked in CI
fn newApi() -> i32 => 1

fn main() {
  print("{newApi()}")
}

Switch to the replacement named in the message before the item is removed.

See also#

OxL 1.0.0-beta · Documentation version 1.0.0-beta© OxwaldLink · generated from the Standard, the std sources and the guides