Function mz_transform::normalize_lets::let_motion::promote_let_rec

source ยท
pub(crate) fn promote_let_rec(expr: &mut MirRelationExpr)
Expand description

Promotes all Let and LetRec nodes to the roots of their expressions.

We cannot (without further reasoning) fuse stacked LetRec stages, and instead we just promote LetRec to the roots of their expressions (e.g. as children of another LetRec stage).