Module enso_prelude::debug::logging[][src]

Expand description

This module provides several logging macros.

Because in recent Rust toolchain versions it is impossible to redirect standard ouput stream to Web Console. This made impossible to quickly add ad-hoc logs with println! during development. Macros provided by this module aim to fill this gap.

Macros intentionally defy our naming rules by being in UPPERCASE. They are not to be used in production-ready code, so they should be easy to visually catch during code reviews. Also, this gets us good names that otherwise would be already used.

Functions

debug

Writes given text either to the stdout (non-wasm) or Web Console (wasm).

error

Writes given text either to the stdout (non-wasm) or Web Console (wasm).

info

Writes given text either to the stdout (non-wasm) or Web Console (wasm).

trace

Writes given text either to the stdout (non-wasm) or Web Console (wasm).

warn

Writes given text either to the stdout (non-wasm) or Web Console (wasm).