Expand description

Various data structures used by the Rust compiler. The intention is that code in here should be not be specific to rustc, so that it can be easily unit tested and so forth.

Note

This API is completely unstable and subject to change.

Modules

atomic_ref 🔒
Simple file-locking apis for each OS.
An immutable, owned value (except for interior mutability).
The ObligationForest is a utility data structure used in trait matching to track the set of outstanding obligations (those not yet resolved to success or error). It also tracks the “backtrace” of each pending obligation (why we are trying to figure this out in the first place).
An owning reference.
Rust Compiler Self-Profiling
This is a copy of core::hash::sip adapted to providing 128 bit hashes.
A utility class for implementing “snapshottable” things; a snapshottable data structure permits you to take a snapshot (via start_snapshot) and then, after making some changes, elect either to rollback to the start of the snapshot or commit those changes.
Calculation and management of a Strict Version Hash for crates
This module defines types which are thread safe if cfg!(parallel_compiler) is true.
This module implements tagged pointers.
A singly-linked list.
Module which contains the snapshot/rollback functionality of the ena data structures.
Union-find implementation. The main type is UnificationTable.

Macros

Type size assertion. The first argument is a type and the second argument is its expected size.

Structs

This is essentially an AtomicPtr but is guaranteed to always be valid

Functions