Brummel 6c8e2df45c Refactor: Improve type propagation in optimizer
Refactor the `updated_metrics` function to `refreshed_metrics`. This
function now clones the `NodeMetrics` if the new type is identical to
the original, avoiding unnecessary allocations.

Also, adjust the `Block` and `Lambda` node kinds to correctly propagate
concrete types after inlining, especially when dealing with polymorphic
functions. This ensures that the return types of blocks and lambdas
reflect the actual computed types rather than stale type variables.

This change improves type inference accuracy and prepares for more
advanced optimizations by ensuring type information is correctly
propagated through the AST.
2026-03-29 18:50:05 +02:00
2026-03-27 15:08:28 +01:00
2026-03-27 15:08:28 +01:00
2026-03-15 22:40:45 +01:00
S
Description
No description provided
6.5 MiB
Languages
Rust 100%