@@ -727,6 +727,10 @@ Sema::ActOnDependentIdExpression(const CXXScopeSpec &SS,
727
727
bool isAddressOfOperand,
728
728
const TemplateArgumentListInfo *TemplateArgs) {
729
729
if (SS.isEmpty()) {
730
+ // FIXME: This codepath is only used by dependent unqualified names
731
+ // (e.g. a dependent conversion-function-id, or operator= once we support
732
+ // it). It doesn't quite do the right thing, and it will silently fail if
733
+ // getCurrentThisType() returns null.
730
734
QualType ThisType = getCurrentThisType();
731
735
if (ThisType.isNull())
732
736
return ExprError();
@@ -735,8 +739,8 @@ Sema::ActOnDependentIdExpression(const CXXScopeSpec &SS,
735
739
Context, /*Base=*/nullptr, ThisType,
736
740
/*IsArrow=*/!Context.getLangOpts().HLSL,
737
741
/*OperatorLoc=*/SourceLocation(),
738
- /*QualifierLoc*/ NestedNameSpecifierLoc(), TemplateKWLoc,
739
- /*FirstQualifierFoundInScope*/ nullptr, NameInfo, TemplateArgs);
742
+ /*QualifierLoc=*/ NestedNameSpecifierLoc(), TemplateKWLoc,
743
+ /*FirstQualifierFoundInScope=*/ nullptr, NameInfo, TemplateArgs);
740
744
}
741
745
return BuildDependentDeclRefExpr(SS, TemplateKWLoc, NameInfo, TemplateArgs);
742
746
}
0 commit comments