On Sunday, 21 February 2016 at 21:48:21 UTC, Steven Schveighoffer
wrote:
This isn't a bug. Here is what happens.
1. template this is assigned the compile-time type of the
object *when the function is called*.
2. A base class constructor is called from the next derived
constructor. So C2's c
On 02/21/2016 01:48 PM, Steven Schveighoffer wrote:
> So it follows that the template this type will be the next derived
> constructor (or the type itself if that is the most derived type),
I've just checked: Adding a C4 to the interitance chain (and
constructing a C4) confirms that to be the c
On 2/21/16 11:48 AM, Vlad Leberstein wrote:
Hi! I'm struggling to use "Template This Parameters" feature(as
described in https://dlang.org/spec/template.html#TemplateThisParameter)
in class constructor. But it's usage isn't documented very clearly and
I'm not even sure if it's supposed to work th
Hi! I'm struggling to use "Template This Parameters" feature(as
described in
https://dlang.org/spec/template.html#TemplateThisParameter) in
class constructor. But it's usage isn't documented very clearly
and I'm not even sure if it's supposed to work this way. Consider
the following example: