Closed AngelicosPhosphoros closed 9 months ago
Note that enabled is not necessarily called before this method. Implementations of log should perform all necessary filtering internally.
I found it when I get this behaviour but it is still surprising API and I think it can be considered to be changed on major release.
I found it when I get this behaviour but it is still surprising API and I think it can be considered to be changed on major release.
This won't work due to log::logger
, which has direct access to the Log
implementation, so any can call the log
method with at any log level.
Oh, OK, understood.
Version: 0.4.20
Example code:
It prints:
https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=8c70eca078d4f717845e436b2f308afe
Expected behaviour:
I expected that if my loggers
enabled()
returns false, thelog
would not be called.