Hi! I have another question. If ctor was called from other ctor then additional parameter must be equal 0 otherwise it`s equal 1. How can I determine who call constructor? - Dmitry.
John McCall
2012-Mar-08 02:25 UTC
[LLVMdev] [cfe-dev] Microsoft constructors implementation problem.
On Mar 5, 2012, at 12:40 AM, r4start wrote:> I have another question. > If ctor was called from other ctor then additional parameter must be > equal 0 otherwise it`s equal 1.The rule isn't "Is this constructor being called from another constructor?", it's "Is this constructor being used to initialize a base subobject?". That's equivalent to the Itanium ABI's concept of a constructor variant. EmitCXXConstructorCall gets this information already. John.
r4start
2012-Mar-11 08:04 UTC
[LLVMdev] [cfe-dev] Microsoft constructors implementation problem.
On 08/03/2012 06:25, John McCall wrote:> On Mar 5, 2012, at 12:40 AM, r4start wrote: >> I have another question. >> If ctor was called from other ctor then additional parameter must be >> equal 0 otherwise it`s equal 1. > The rule isn't "Is this constructor being called from another constructor?", > it's "Is this constructor being used to initialize a base subobject?". That's > equivalent to the Itanium ABI's concept of a constructor variant. > EmitCXXConstructorCall gets this information already. >Thx for your response. I forgot about CXXCtorType. - Dmitry.