r178120 - Pass the diagnostic in for better error messages.

Evgeniy Stepanov eugeni.stepanov at gmail.com
Wed Mar 27 07:08:22 PDT 2013


Hi Bill,

since this change I see 100% reproducible failures in Clang :: Sema/asm.c test.

Exit Code: 1
Command Output (stderr):
--
error: 'note' diagnostics seen but not expected:
  Line 128: forward declaration of 'struct S'
1 error generated.
--

I'm puzzled why it does not appear on the official bots.
Output of the test command without -verify attached.

On Wed, Mar 27, 2013 at 10:06 AM, Bill Wendling <isanbard at gmail.com> wrote:
> Author: void
> Date: Wed Mar 27 01:06:26 2013
> New Revision: 178120
>
> URL: http://llvm.org/viewvc/llvm-project?rev=178120&view=rev
> Log:
> Pass the diagnostic in for better error messages.
>
> Modified:
>     cfe/trunk/lib/Sema/SemaStmtAsm.cpp
>
> Modified: cfe/trunk/lib/Sema/SemaStmtAsm.cpp
> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaStmtAsm.cpp?rev=178120&r1=178119&r2=178120&view=diff
> ==============================================================================
> --- cfe/trunk/lib/Sema/SemaStmtAsm.cpp (original)
> +++ cfe/trunk/lib/Sema/SemaStmtAsm.cpp Wed Mar 27 01:06:26 2013
> @@ -129,10 +129,9 @@ StmtResult Sema::ActOnGCCAsmStmt(SourceL
>                              diag::err_asm_invalid_lvalue_in_output)
>                         << OutputExpr->getSourceRange());
>
> -    if (RequireCompleteType(OutputExpr->getLocStart(), Exprs[i]->getType(), 0))
> -      return StmtError(Diag(OutputExpr->getLocStart(),
> -                            diag::err_dereference_incomplete_type)
> -                       << Exprs[i]->getType());
> +    if (RequireCompleteType(OutputExpr->getLocStart(), Exprs[i]->getType(),
> +                            diag::err_dereference_incomplete_type))
> +      return StmtError();
>
>      OutputConstraintInfos.push_back(Info);
>    }
> @@ -189,10 +188,9 @@ StmtResult Sema::ActOnGCCAsmStmt(SourceL
>        continue;
>
>      if (!Ty->isVoidType() || !Info.allowsMemory())
> -      if (RequireCompleteType(InputExpr->getLocStart(), Exprs[i]->getType(), 0))
> -        return StmtError(Diag(InputExpr->getLocStart(),
> -                              diag::err_dereference_incomplete_type)
> -                         << Exprs[i]->getType());
> +      if (RequireCompleteType(InputExpr->getLocStart(), Exprs[i]->getType(),
> +                              diag::err_dereference_incomplete_type))
> +        return StmtError();
>
>      unsigned Size = Context.getTypeSize(Ty);
>      if (!Context.getTargetInfo().validateInputSize(Literal->getString(),
>
>
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
-------------- next part --------------
A non-text attachment was scrubbed...
Name: asm.log
Type: application/octet-stream
Size: 8050 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130327/5ead41f0/attachment.obj>


More information about the cfe-commits mailing list