If I wanted to check whether the assigned value is within a range, and I want to throw a certain exception if outside of it, then how I can do that?
You can't with ref, you will need to do separate getter and setter properties for that.
Adam D Ruppe via Digitalmars-d-learn Sat, 23 Oct 2021 13:26:44 -0700
If I wanted to check whether the assigned value is within a range, and I want to throw a certain exception if outside of it, then how I can do that?
You can't with ref, you will need to do separate getter and setter properties for that.