alias this
Explore how alias this works in D programming to enable automatic type conversions for user-defined types. Understand its difference from explicit casts and see practical examples that help simplify code interactions between types.
We'll cover the following...
We'll cover the following...
Use of alias this
You have seen the individual meanings of the alias and the this keywords in previous chapters. These two keywords have a completely different meaning when used together as alias this.
alias this enables automatic type conversions (also known as implicit type conversions) of user-defined types. As have seen in the ...