Inconsistent chain (implicitly converts to int)

H. S. Teoh hsteoh at qfbox.info
Fri Apr 5 16:05:20 UTC 2024


On Fri, Apr 05, 2024 at 03:18:09PM +0000, Salih Dincer via Digitalmars-d-learn wrote:
> Hi everyone,
> 
> Technically r1 and r2 are different types of range. Isn't it
> inconsistent to chain both? If not, why is the char type converted to
> int?
[...]

It's not inconsistent if there exists a common type that both range
element types implicit convert to.

The real problem is the implicit conversion of char to int, which I have
been against for a long time.  Walter, however, disagrees.


T

-- 
What's worse than raining cats and dogs?  Hailing taxis!


More information about the Digitalmars-d-learn mailing list