#debugging #macro #if

macro if_debug

A handy rust macro to exclude debugging code from your release builds

1 unstable release

0.1.0 Oct 18, 2021

#10 in #if

MIT license

3KB

if_debug

A handy rust macro to exclude debugging code from your release builds.

Example

fn main() {
  if_debug!(println!("We're debugging!"));
}

Install

Add the following line to your Cargo.toml file under [dependencies]:

if_debug = { git = "https://github.com/Humandoodlebug/if_debug" }

No runtime deps