Expand description
This module provides a way to use the standard library or loomβs types in a unified way,
depending on the loom cfg flag.
ModulesΒ§
- alloc π
- Memory allocation APIs.
- any π
- Utilities for dynamic typing or type reflection.
- arch π
- SIMD and vendor intrinsics module.
- array π
- Utilities for the array primitive type.
- ascii π
- Operations on ASCII strings and characters.
- backtrace π
- Support for capturing a stack backtrace of an OS thread
- borrow π
- A module for working with borrowed data.
- boxed π
- The
Box<T>type for heap allocation. - cell π
- Shareable mutable containers.
- char π
- Utilities for the
charprimitive type. - clone π
- The
Clonetrait for types that cannot be βimplicitly copiedβ. - cmp π
- Utilities for comparing and ordering values.
- collections π
- Collection types.
- convert π
- Traits for conversions between types.
- default π
- The
Defaulttrait for types with a default value. - env π
- Inspection and manipulation of the processβs environment.
- error π
- Interfaces for working with Errors.
- f32 π
- Constants for the
f32single-precision floating point type. - f64 π
- Constants for the
f64double-precision floating point type. - ffi π
- Utilities related to FFI bindings.
- fmt π
- Utilities for formatting and printing
Strings. - fs π
- Filesystem manipulation operations.
- future π
- Asynchronous basic functionality.
- hash π
- Generic hashing support.
- hint π
- Hints to compiler that affects how code should be emitted or optimized.
- i8 π
Deprecation planned - Redundant constants module for the
i8primitive type. - i16 π
Deprecation planned - Redundant constants module for the
i16primitive type. - i32 π
Deprecation planned - Redundant constants module for the
i32primitive type. - i64 π
Deprecation planned - Redundant constants module for the
i64primitive type. - i128 π
Deprecation planned - Redundant constants module for the
i128primitive type. - io π
- Traits, helpers, and type definitions for core I/O functionality.
- isize π
Deprecation planned - Redundant constants module for the
isizeprimitive type. - iter π
- Composable external iteration.
- marker π
- Primitive traits and types representing basic properties of types.
- mem π
- Basic functions for dealing with memory.
- net π
- Networking primitives for TCP/UDP communication.
- num π
- Additional functionality for numerics.
- ops π
- Overloadable operators.
- option π
- Optional values.
- os π
- OS-specific functionality.
- panic π
- Panic support in the standard library.
- path π
- Cross-platform path manipulation.
- pin π
- Types that pin data to a location in memory.
- prelude π
- The Rust Prelude
- primitive π
- This module reexports the primitive types to allow usage that is not possibly shadowed by other declared types.
- process π
- A module for working with processes.
- ptr π
- Manually manage memory through raw pointers.
- rc π
- Single-threaded reference-counting pointers. βRcβ stands for βReference Countedβ.
- result π
- Error handling with the
Resulttype. - slice π
- Utilities for the slice primitive type.
- str π
- Utilities for the
strprimitive type. - string π
- A UTF-8βencoded, growable string.
- sync π
- Useful synchronization primitives.
- task π
- Types and Traits for working with asynchronous tasks.
- thread π
- Native threads.
- time π
- Temporal quantification.
- u8 π
Deprecation planned - Redundant constants module for the
u8primitive type. - u16 π
Deprecation planned - Redundant constants module for the
u16primitive type. - u32 π
Deprecation planned - Redundant constants module for the
u32primitive type. - u64 π
Deprecation planned - Redundant constants module for the
u64primitive type. - u128 π
Deprecation planned - Redundant constants module for the
u128primitive type. - usize π
Deprecation planned - Redundant constants module for the
usizeprimitive type. - vec π
- A contiguous growable array type with heap-allocated contents, written
Vec<T>. - assert_
matches πExperimental - Unstable module containing the unstable
assert_matchesmacro. - async_
iter πExperimental - Composable asynchronous iteration.
- autodiff π
Experimental - This module provides support for automatic differentiation.
- bstr π
Experimental - The
ByteStrandByteStringtypes and trait implementations. - f16 π
Experimental - Constants for the
f16half-precision floating point type. - f128 π
Experimental - Constants for the
f128quadruple-precision floating point type. - from π
Experimental - Unstable module containing the unstable
Fromderive macro. - intrinsics π
Experimental - Compiler intrinsics.
- pat π
Experimental - Helper module for exporting the
pattern_typemacro - random π
Experimental - Random value generation.
- range π
Experimental - Experimental replacement range types
- simd π
Experimental - Portable SIMD module.
- unsafe_
binder πExperimental - Operators used to turn types into unsafe binders and back.
MacrosΒ§
- assert π
- Asserts that a boolean expression is
trueat runtime. - assert_
eq π - Asserts that two expressions are equal to each other (using
PartialEq). - assert_
ne π - Asserts that two expressions are not equal to each other (using
PartialEq). - cfg π
- Evaluates boolean combinations of configuration flags at compile-time.
- column π
- Expands to the column number at which it was invoked.
- compile_
error π - Causes compilation to fail with the given error message when encountered.
- concat π
- Concatenates literals into a static string slice.
- dbg π
- Prints and returns the value of a given expression for quick and dirty debugging.
- debug_
assert π - Asserts that a boolean expression is
trueat runtime. - debug_
assert_ πeq - Asserts that two expressions are equal to each other.
- debug_
assert_ πne - Asserts that two expressions are not equal to each other.
- env π
- Inspects an environment variable at compile time.
- eprint π
- Prints to the standard error.
- eprintln π
- Prints to the standard error, with a newline.
- file π
- Expands to the file name in which it was invoked.
- format π
- Creates a
Stringusing interpolation of runtime expressions. - format_
args π - Constructs parameters for the other string-formatting macros.
- include π
- Parses a file as an expression or an item according to the context.
- include_
bytes π - Includes a file as a reference to a byte array.
- include_
str π - Includes a UTF-8 encoded file as a string.
- is_
x86_ πfeature_ detected - Check for the presence of a CPU feature at runtime.
- line π
- Expands to the line number on which it was invoked.
- matches π
- Returns whether the given expression matches the provided pattern.
- module_
path π - Expands to a string that represents the current module path.
- option_
env π - Optionally inspects an environment variable at compile time.
- panic π
- Panics the current thread.
- print π
- Prints to the standard output.
- println π
- Prints to the standard output, with a newline.
- stringify π
- Stringifies its arguments.
- thread_
local π - Declare a new thread local storage key of type
std::thread::LocalKey. - todo π
- Indicates unfinished code.
- try π
Deprecated - Unwraps a result or propagates its error.
- unimplemented π
- Indicates unimplemented code by panicking with a message of βnot implementedβ.
- unreachable π
- Indicates unreachable code.
- vec π
- Creates a
Veccontaining the arguments. - write π
- Writes formatted data into a buffer.
- writeln π
- Writes formatted data into a buffer, with a newline appended.
- cfg_
select πExperimental - Selects code at compile-time based on
cfgpredicates. - concat_
bytes πExperimental - Concatenates literals into a byte slice.
- const_
format_ πargs Experimental - Same as
format_args, but can be used in some const contexts. - log_
syntax πExperimental - Prints passed tokens into the standard output.
- trace_
macros πExperimental - Enables or disables tracing functionality used for debugging other macros.
TraitsΒ§
- GetMut
- A trait for getting the inner value of an atomic type when we hold a mutable reference.