What is the point of this? Doesn't the case work naturally with a simple case? Besides, would this even compile if I request a cast from immutable to mutable? I expect the "return this" will fail with "can convert immutable(BigInt) to BigInt".

Is this covered? Could you add a unittest?