diff options
Diffstat (limited to 'contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp')
| -rw-r--r-- | contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp | 11 | 
1 files changed, 10 insertions, 1 deletions
diff --git a/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp b/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp index 01231f8e385e..d608dd92a4b4 100644 --- a/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp +++ b/contrib/llvm-project/clang/lib/Sema/SemaDecl.cpp @@ -1219,7 +1219,7 @@ Corrected:    return NameClassification::OverloadSet(UnresolvedLookupExpr::Create(        Context, Result.getNamingClass(), SS.getWithLocInContext(Context),        Result.getLookupNameInfo(), ADL, Result.begin(), Result.end(), -      /*KnownDependent=*/false)); +      /*KnownDependent=*/false, /*KnownInstantiationDependent=*/false));  }  ExprResult @@ -18073,6 +18073,15 @@ void Sema::ActOnTagFinishDefinition(Scope *S, Decl *TagD,        if (NumInitMethods > 1 || !Def->hasInitMethod())          Diag(RD->getLocation(), diag::err_sycl_special_type_num_init_method);      } + +    // If we're defining a dynamic class in a module interface unit, we always +    // need to produce the vtable for it, even if the vtable is not used in the +    // current TU. +    // +    // The case where the current class is not dynamic is handled in +    // MarkVTableUsed. +    if (getCurrentModule() && getCurrentModule()->isInterfaceOrPartition()) +      MarkVTableUsed(RD->getLocation(), RD, /*DefinitionRequired=*/true);    }    // Exit this scope of this tag's definition.  | 
