mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-04 03:07:25 +00:00

This patch adds a `MirPass` that tracks the number of back-edges and function calls in the CFG, adds a new MIR instruction to increment a counter every time they are encountered during Const Eval, and emit a warning if a configured limit is breached.
Please read the rustc-dev-guide chapter on Backend Agnostic Codegen.