[cfe-commits] r137983 - /cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td

Chris Lattner clattner at apple.com
Fri Aug 19 00:47:09 PDT 2011


On Aug 18, 2011, at 2:20 PM, Ted Kremenek wrote:

> Author: kremenek
> Date: Thu Aug 18 16:20:46 2011
> New Revision: 137983
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=137983&view=rev
> Log:
> Remove main() *errors* from warning group.

Can tblgen reject this as an error?

-Chris

> 
> Modified:
>    cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
> 
> Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td?rev=137983&r1=137982&r2=137983&view=diff
> ==============================================================================
> --- cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td (original)
> +++ cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td Thu Aug 18 16:20:46 2011
> @@ -292,21 +292,16 @@
>     "%select{static|inline|static or inline}0">,
>     InGroup<Main>;
> def err_unusual_main_decl : Error<"'main' is not allowed to be declared "
> -    "%select{static|inline|static or inline}0">,
> -    InGroup<Main>;
> -def err_main_template_decl : Error<"'main' cannot be a template">,
> -    InGroup<Main>;
> -def err_main_returns_nonint : Error<"'main' must return 'int'">,
> -    InGroup<Main>;
> +    "%select{static|inline|static or inline}0">;
> +def err_main_template_decl : Error<"'main' cannot be a template">;
> +def err_main_returns_nonint : Error<"'main' must return 'int'">;
> def err_main_surplus_args : Error<"too many parameters (%0) for 'main': "
> -    "must be 0, 2, or 3">,
> -    InGroup<Main>;
> +    "must be 0, 2, or 3">;
> def warn_main_one_arg : Warning<"only one parameter on 'main' declaration">,
>     InGroup<Main>;
> def err_main_arg_wrong : Error<"%select{first|second|third|fourth}0 "
>     "parameter of 'main' (%select{argument count|argument array|environment|"
> -    "platform-specific data}0) must be of type %1">,
> -    InGroup<Main>;
> +    "platform-specific data}0) must be of type %1">;
> 
> /// parser diagnostics
> def ext_typedef_without_a_name : ExtWarn<"typedef requires a name">,
> 
> 
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits




More information about the cfe-commits mailing list