They have different use cases.
if x != nil is to do some work without needing x, because you'd still have to unwrap it if you used it.
That's what if let y = x is for, it creates a safe lexical context to use the unwrapped value.
And then you have guard let y = x which is a stronger guarantee that no code further down in the context is executed if x is nil. This helps to write happy-path code with early returns, avoiding pyramids of doom and encouraging writing code where all the assumptions are listed up front with logic handling exceptional cases before finally arriving at the logic that works under all the assumptions.
Dart feels like a step backwards after seeing the benefits these provide.
That's what if let y = x is for, it creates a safe lexical context to use the unwrapped value.
And then you have guard let y = x which is a stronger guarantee that no code further down in the context is executed if x is nil. This helps to write happy-path code with early returns, avoiding pyramids of doom and encouraging writing code where all the assumptions are listed up front with logic handling exceptional cases before finally arriving at the logic that works under all the assumptions.
Dart feels like a step backwards after seeing the benefits these provide.