Browse Source

Fix for Visual Studio 2019 16.10 (#1614)

pull/1621/head
Albert Szilvasy 5 years ago committed by GitHub
parent
commit
a178108c06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      src/Generator/Generators/CSharp/CSharpSources.cs

8
src/Generator/Generators/CSharp/CSharpSources.cs

@ -2690,6 +2690,14 @@ internal static{(@new ? " new" : string.Empty)} {printedClass} __GetInstance({Ty @@ -2690,6 +2690,14 @@ internal static{(@new ? " new" : string.Empty)} {printedClass} __GetInstance({Ty
{
GenerateVirtualFunctionCall(method);
}
else if (method.IsDestructor)
{
// It is possible that HasNonTrivialDestructor property different for specialization vs.
// the template. When we generate the Internal struct we only put a dtor there if the specialization
// has a non-trivial dtor. So we must make sure do the same test here.
if (@class.HasNonTrivialDestructor)
GenerateInternalFunctionCall(method, returnType: returnType);
}
else
{
GenerateInternalFunctionCall(method, returnType: returnType);

Loading…
Cancel
Save