prelude.rs 437 B

1234567891011121314151617181920
  1. // SPDX-License-Identifier: GPL-2.0
  2. //! The `kernel` prelude.
  3. //!
  4. //! These are the most common items used by Rust code in the kernel,
  5. //! intended to be imported by all Rust code, for convenience.
  6. //!
  7. //! # Examples
  8. //!
  9. //! ```
  10. //! use kernel::prelude::*;
  11. //! ```
  12. pub use super::{
  13. error::{Error, Result},
  14. pr_emerg, pr_info, ThisModule,
  15. };
  16. pub use alloc::{boxed::Box, vec::Vec};
  17. pub use core::pin::Pin;
  18. pub use macros::module;