From 58868c9908e803cd7297112940b5f1b61f906fdf Mon Sep 17 00:00:00 2001 From: Chris Fallin Date: Sat, 11 Dec 2021 22:36:01 -0800 Subject: [PATCH] WIP. --- src/frontend.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/frontend.rs b/src/frontend.rs index 80a2379..9ad5854 100644 --- a/src/frontend.rs +++ b/src/frontend.rs @@ -356,7 +356,9 @@ impl LocalTracker { let mut non_self = results.iter().filter(|&&v| v != value); let trivial_alias = match non_self.next() { None => None, - Some(&first) if non_self.all(|&v| v == first) => Some(first), + Some(&first) if non_self.all(|&v| v == first) && body.resolve_alias(first) != value => { + Some(first) + } Some(_) => None, };