4 ms·
Then what would you use for testing equality? And what would you use if you were pattern matching _and_ assigning in the same statement? I.e. {:ok, value}
by Ndymium 5y ago
Then what would you use for testing equality?
And what would you use if you were pattern matching _and_ assigning in the same statement? I.e.
{:ok, value} = function()
- claudiojulio 5y agoCould be like that: // equality with is already 1 == 1.0 //true 1 === 1.0 //false // assigning x = 1 // pattern matching x ^ 1 // pattern matching and assigning x =^ 1 or x ^= 1 And they should remove the rebinding that is useless. But I find it very difficult for that to happen at that time. Automatically translated.