| 1774 | b: &KExpr<M>, |
| 1775 | ) { |
| 1776 | let Some(filter) = IX_PROJ_DELTA_TRACE.as_ref() else { |
| 1777 | return; |
| 1778 | }; |
| 1779 | if !self.debug_label_matches_env() { |
| 1780 | return; |
| 1781 | } |
| 1782 | let id_s = id.to_string(); |
| 1783 | if !filter.is_empty() && !id_s.contains(filter) { |
| 1784 | return; |
| 1785 | } |
| 1786 | log::info!( |
| 1787 | "[proj-delta] const={} depth={} phase={} proj={}.{} a={} b={}", |
| 1788 | self.debug_label.as_deref().unwrap_or("<unknown>"), |
| 1789 | self.def_eq_depth, |
| 1790 | phase, |
| 1791 | id, |
| 1792 | field, |
| 1793 | compact_def_eq_expr(a), |
| 1794 | compact_def_eq_expr(b) |
| 1795 | ); |
| 1796 | } |
| 1797 | |
| 1798 | /// If the head of `e` is a projection, try reducing it via whnf_no_delta. |
| 1799 | /// Returns the reduced form if it changed, None otherwise (lean4lean tryUnfoldProjApp). |