Puzzled

Don Allen donaldcallen at gmail.com
Wed Dec 13 15:27:13 UTC 2023


On Wednesday, 13 December 2023 at 06:52:59 UTC, Walter Bright 
wrote:
> On 12/12/2023 11:02 AM, Don Allen wrote:
>> Since ceasing my use of D out of concern for the direction and 
>> health of the project, I've nonetheless been following these 
>> forums and have seen what I consider to be sincere efforts to 
>> improve things.
>
> Welcome back!
[snip]
>> But I'm failing to understand why the problem exists in the 
>> first place.
>
> The misunderstanding appears to be the assumption that `field` 
> is resolved inside the definition of `bletch`. It is not, it is 
> resolved at the point of instantiation of the template `bletch`.
>

Not quite. I do understand the above, because it is evident from 
the behavior I am seeing. What I'm puzzled by is why template 
processing behaves this way, requiring that the symbol  be 
defined at the point where it is *passed (by symbol)*, rather 
than where it is *used*, which is the place where having a valid 
definition really matters.


More in my reply to your second message.


More information about the Digitalmars-d mailing list