rusty-man/tests/snapshots/output__1.40.0_fn_log_set_logger_racy.snap
Robin Krahl 628377c83b
Refactor test suite to check multiple versions
This patch refactors the test suite:
- Instead of always generating the documentation with the available
  rustdoc version, we now store generated documentation for all
  supported rustdoc versions in the test/html directory.
- Instead of using one snapshot per test case, we now use one snapshot
  per test case and rustdoc version.
2020-09-11 20:30:05 +02:00

32 lines
1006 B
Plaintext
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
source: tests/output.rs
expression: "get_stdout(&[item])"
---
log Function log::set_logger_racy rusty-man
SYNOPSIS
pub unsafe fn set_logger_racy(
    logger: &'static dyn Log
) -> Result<(), SetLoggerError>
DESCRIPTION
A thread-unsafe version of `set_logger`.
This function is available on all platforms, even those that do not have support for atomics
that is needed by `set_logger`.
In almost all cases, `set_logger` should be preferred.
# Safety
This function is only safe to call when no other logger initialization function is called
while this function still executes.
This can be upheld by (for example) making sure that **there are no other threads**, and (on
embedded) that **interrupts are disabled**.
It is safe to use other logging functions while this function runs (including all logging
macros).