From ffe0884bc43c686d2496b75a01f2b2c5a03789c5 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Fri, 23 Apr 2010 03:19:53 +0000 Subject: Emit a lame diagnostic when we can't mangle operator names llvm-svn: 102168 --- clang/lib/CodeGen/Mangle.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'clang/lib/CodeGen/Mangle.cpp') diff --git a/clang/lib/CodeGen/Mangle.cpp b/clang/lib/CodeGen/Mangle.cpp index 16823127732..9dc3e2cf87b 100644 --- a/clang/lib/CodeGen/Mangle.cpp +++ b/clang/lib/CodeGen/Mangle.cpp @@ -767,7 +767,11 @@ void CXXNameMangler::mangleTemplatePrefix(TemplateName Template) { if (Dependent->isIdentifier()) mangleSourceName(Dependent->getIdentifier()); else { - // FIXME: We can't possibly know the arity for mangling operators! + // FIXME: We can't possibly know the arity of the operator here! + Diagnostic &Diags = Context.getDiags(); + unsigned DiagID = Diags.getCustomDiagID(Diagnostic::Error, + "cannot mangle dependent operator name"); + Diags.Report(FullSourceLoc(), DiagID); } } -- cgit v1.2.3