is(this : myClass)
Steven Schveighoffer
schveiguy at yahoo.com
Fri Oct 20 22:15:36 UTC 2017
On 10/20/17 5:55 PM, Patrick wrote:
> Due to the very specific nature of the 'is' operator, why wouldn't the
> compiler know to implicitly query the class types? Why must it be
> explicitly written, typeof(this)?
The compiler generally doesn't "fix" errors for you, it tells you there
is a problem, and then you have to fix it. You have to be clear and
unambiguous to the compiler. Otherwise debugging would be hell.
-Steve
More information about the Digitalmars-d-learn
mailing list