Skip to content
9 changes: 4 additions & 5 deletions src/librustc_mir/dataflow/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -612,11 +612,10 @@ pub trait BitDenotation: BitwiseOperator {
/// `sets.on_entry` to that local clone into `statement_effect` and
/// `terminator_effect`).
///
/// When its false, no local clone is constucted; instead a
/// reference directly into `on_entry` is passed along via
/// `sets.on_entry` instead, which represents the flow state at
/// the block's start, not necessarily the state immediately prior
/// to the statement/terminator under analysis.
/// When its false, no local clone is constucted; instead it is
/// undefined what `on_entry` points to (in practice, it will
/// frequently be a reference the flow state at the block's start,
/// but you should not rely on that).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is a good change (in that no one should be or have been using the stronger guarantee in the earlier version of the comment). But I am curious: Did you actually concoct some scenario that invalidated the comment's stronger claim? Or are you figuring that we're better off not defining the semantics in this case?

///
/// In either case, the passed reference is mutable; but this is a
/// wart from using the `BlockSets` type in the API; the intention
Expand Down