r175450 - Prevent crash on multiple user errors (which I cannot reproduce in
David Blaikie
dblaikie at gmail.com
Mon Feb 18 09:38:22 PST 2013
On Mon, Feb 18, 2013 at 9:22 AM, Fariborz Jahanian <fjahanian at apple.com>wrote:
> Author: fjahanian
> Date: Mon Feb 18 11:22:23 2013
> New Revision: 175450
>
> URL: http://llvm.org/viewvc/llvm-project?rev=175450&view=rev
> Log:
> Prevent crash on multiple user errors (which I cannot reproduce in
> a small test case). // rdar://13178483.
>
This seems like something pretty reliably reproducable - I assume you have
a larger program that consistently reproduces the problem? Is there any way
you could provide that (sufficiently anonymized) so someone could reproduce
(& hopefully reduce) this issue?
>
> Modified:
> cfe/trunk/lib/Sema/SemaExpr.cpp
>
> Modified: cfe/trunk/lib/Sema/SemaExpr.cpp
> URL:
> http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaExpr.cpp?rev=175450&r1=175449&r2=175450&view=diff
>
> ==============================================================================
> --- cfe/trunk/lib/Sema/SemaExpr.cpp (original)
> +++ cfe/trunk/lib/Sema/SemaExpr.cpp Mon Feb 18 11:22:23 2013
> @@ -1976,6 +1976,10 @@ Sema::LookupInObjCMethod(LookupResult &L
> IdentifierInfo *II, bool AllowBuiltinCreation) {
> SourceLocation Loc = Lookup.getNameLoc();
> ObjCMethodDecl *CurMethod = getCurMethodDecl();
> +
> + // Check for error condition which is already reported.
> + if (!CurMethod)
> + return ExprError();
>
> // There are two cases to handle here. 1) scoped lookup could have
> failed,
> // in which case we should look for an ivar. 2) scoped lookup could
> have
>
>
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130218/cdc5cda0/attachment.html>
More information about the cfe-commits
mailing list