[cfe-commits] r53882 - in /cfe/trunk: lib/Sema/SemaDeclAttr.cpp	test/Sema/nonnull.c
    Chris Lattner 
    clattner at apple.com
       
    Mon Jul 21 15:57:50 PDT 2008
    
    
  
On Jul 21, 2008, at 3:09 PM, Ted Kremenek wrote:
> Author: kremenek
> Date: Mon Jul 21 17:09:15 2008
> New Revision: 53882
>
> URL: http://llvm.org/viewvc/llvm-project?rev=53882&view=rev
> Log:
> Add test case for nonnull attribute.
> Fix indexing bug.
Hey Ted,
Please use utostr in llvm/ADT/StringExtras.h instead of  
ostringstream.  Thanks!
-Chris
>     if (x < 1 || x > NumArgs) {
> +      std::ostringstream os;
> +      os << I.getArgNum();
>       S.Diag(Attr.getLoc(),  
> diag::err_attribute_argument_out_of_bounds,
> -             "nonnull", Ex->getSourceRange());
> +             "nonnull", os.str(), Ex->getSourceRange());
>       return;
>     }
    
    
More information about the cfe-commits
mailing list