Type-Strict Indexes: IndexedBy
anonymous via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Feb 16 12:17:54 PST 2015
On Monday, 16 February 2015 at 20:09:09 UTC, Nordlöw wrote:
> How can I prevent
>
> jx[0] = 11;
>
> from compiling?
Remove that `alias _r this;`. You don't want to forward opIndex,
so you can't use alias this which forwards everything that
doesn't compile. opDispatch may be an option to forward
everything but opIndex.
More information about the Digitalmars-d-learn
mailing list