Skip to main content

Module world

Module world 

Source
Expand description

Worlds, and merging the ones that have become identical.

Structs§

Flow
Worlds leaving a statement, grouped by how they left it.
World
One possible state of the program: the variables of the current frame, and how likely it is (including every observation so far).

Functions§

clear
Clear these slots: nobody will read them again.
clear_dead
Clear every slot that isn’t live, in worlds that jumped (with break or continue) past statements that would have cleared some of them.
live_slots
The live slots among a frame’s n.
merge
If enabled, merge the worlds that agree on the live slots, adding up their weights, and keeping the order of first appearance. Dead slots don’t matter, cleared or not.
merge_values
Merge returned values only when their caller-visible restrictions also agree.
state_hash
A hash of a world’s live slots, as merging computes it.
total_weight

Type Aliases§

Returned
A returned value, the weight of the world that returned it, and the restrictions on analytic draws that its caller can see.