On Wednesday, 10 June 2015 at 13:43:45 UTC, Shachar Shemesh wrote:
On 10/06/15 15:37, Kagamin wrote:
On Wednesday, 10 June 2015 at 08:53:40 UTC, Shachar Shemesh
wrote:
On 10/06/15 11:31, Kagamin wrote:
Huh? If you have type's method diskIdx and a local variable
diskIdx, and
they are confusing, what it has to do with UFCS?
auto diskIdx = data.diskIdx();
auto diskIdx1 = this.diskIdx;
diskIdx1 = f(diskIdx1);
return diskIdx;
Was this meant to prove that you can make it confusing?
It was your requirement that variables and methods must be
similar.
What does "diskIdx1" mean?
Same as in your example, a variable, which receives the disk
index.
What does f do?
Processes the disk index and returns another index according to
its logic.
Is "this.diskIdx" a member or a function?
A property, which extracts the disk index as you described the
function.
where did the diskIdx you returned came from?
It's defined as a member of the type.