summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGObjC.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/CodeGen/CGObjC.cpp')
-rw-r--r--clang/lib/CodeGen/CGObjC.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/clang/lib/CodeGen/CGObjC.cpp b/clang/lib/CodeGen/CGObjC.cpp
index 058278cfa4e..044368c6998 100644
--- a/clang/lib/CodeGen/CGObjC.cpp
+++ b/clang/lib/CodeGen/CGObjC.cpp
@@ -303,10 +303,9 @@ void CodeGenFunction::EmitObjCPropertySet(const ObjCPropertyRefExpr *E,
S = Setter->getSelector();
} else {
// FIXME: This should be diagnosed by sema.
- SourceRange Range = E->getSourceRange();
CGM.getDiags().Report(getContext().getFullLoc(E->getLocStart()),
- diag::err_typecheck_assign_const, 0, 0,
- &Range, 1);
+ diag::err_typecheck_assign_const)
+ << E->getSourceRange();
return;
}
} else {
OpenPOWER on IntegriCloud