Skip to main content

Module types

Module types 

Source
Expand description

Core MIR types: Place, Statement, Terminator, BasicBlock.

These represent the mid-level IR that the borrow solver operates on. Places track what can be borrowed (locals, fields, indices). Statements and terminators form basic blocks in a control flow graph.

Structs§

BasicBlock
A basic block: a sequence of statements ending in a terminator.
BasicBlockId
Index of a basic block within a MIR function.
FieldIdx
Index of a struct/object field.
LoanId
Unique identifier for a loan (borrow).
MirFunction
The MIR representation of a single function.
MirStatement
A statement within a basic block (doesn’t affect control flow).
Point
A program point (statement index within the function’s linearized MIR). Used as the “point” dimension in Datafrog relations.
SlotId
Index of a local variable slot.
Terminator
A block terminator (controls flow between basic blocks).

Enums§

BinOp
Binary operations in MIR.
BorrowKind
The kind of borrow.
LocalTypeInfo
Type information for a local variable, used for Copy/Clone inference.
MirConstant
A constant value in MIR.
Operand
An operand in an Rvalue or terminator.
Place
A place is something that can be borrowed or assigned to. Tracks granular access paths for disjoint borrow analysis.
ProjectionStep
A normalized step in a place projection chain.
Rvalue
Right-hand side of an assignment.
StatementKind
TaskBoundaryKind
Distinguishes detached vs structured async task boundaries.
TerminatorKind
UnOp
Unary operations in MIR.