mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-05 18:20:34 +00:00
a70a2193ad
The syslog and ioctl macros in sys_util were originally written to be imported through `#[macro_use] extern crate sys_util` which is essentially a glob import of all macros from the crate. In 2018 edition, extern crate is deprecated and macros are imported the same as any other item. As these sys_util macros are currently written, importing an individual macro requires the caller to also import any other sys_util macros that the invocation internally expands to. Example: use sys_util::{error, log}; fn main() { error!("..."); } This CL adjusts all sys_util macros to invoke helper macros through a `$crate::` prefix so that the caller is not required to have the helper macros in scope themselves. use sys_util::error; fn main() { error!("..."); } TEST=kokoro Change-Id: I2d9f16dca8e7a4a4c0e63d9f10ead9f7413d9c3c Reviewed-on: https://chromium-review.googlesource.com/1565544 Commit-Ready: David Tolnay <dtolnay@chromium.org> Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Tested-by: David Tolnay <dtolnay@chromium.org> Tested-by: kokoro <noreply+kokoro@google.com> Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> |
||
---|---|---|
.. | ||
poll_token_derive | ||
src | ||
Cargo.toml |