зеркало из https://github.com/microsoft/clang-1.git
PR4800: Implement -Wpointer-arith. I think this is the correct behavior
per the documentation, although I'm not completely sure. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80257 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
d28b42862b
Коммит
cbdebdd113
|
@ -58,7 +58,7 @@ def : DiagGroup<"nonportable-cfstrings">;
|
||||||
def : DiagGroup<"old-style-definition">;
|
def : DiagGroup<"old-style-definition">;
|
||||||
def : DiagGroup<"packed">;
|
def : DiagGroup<"packed">;
|
||||||
def Parentheses : DiagGroup<"parentheses">;
|
def Parentheses : DiagGroup<"parentheses">;
|
||||||
def : DiagGroup<"pointer-arith">;
|
def PointerArith : DiagGroup<"pointer-arith">;
|
||||||
def : DiagGroup<"pointer-to-int-cast">;
|
def : DiagGroup<"pointer-to-int-cast">;
|
||||||
def : DiagGroup<"redundant-decls">;
|
def : DiagGroup<"redundant-decls">;
|
||||||
def ReturnType : DiagGroup<"return-type">;
|
def ReturnType : DiagGroup<"return-type">;
|
||||||
|
|
|
@ -1225,9 +1225,9 @@ def err_func_def_incomplete_result : Error<
|
||||||
|
|
||||||
// Expressions.
|
// Expressions.
|
||||||
def ext_sizeof_function_type : Extension<
|
def ext_sizeof_function_type : Extension<
|
||||||
"invalid application of 'sizeof' to a function type">;
|
"invalid application of 'sizeof' to a function type">, InGroup<PointerArith>;
|
||||||
def ext_sizeof_void_type : Extension<
|
def ext_sizeof_void_type : Extension<
|
||||||
"invalid application of '%0' to a void type">;
|
"invalid application of '%0' to a void type">, InGroup<PointerArith>;
|
||||||
// FIXME: merge with %select
|
// FIXME: merge with %select
|
||||||
def err_sizeof_incomplete_type : Error<
|
def err_sizeof_incomplete_type : Error<
|
||||||
"invalid application of 'sizeof' to an incomplete type %0">;
|
"invalid application of 'sizeof' to an incomplete type %0">;
|
||||||
|
@ -1402,9 +1402,10 @@ def err_unexpected_interface : Error<
|
||||||
def err_property_not_found : Error<
|
def err_property_not_found : Error<
|
||||||
"property %0 not found on object of type %1">;
|
"property %0 not found on object of type %1">;
|
||||||
def ext_gnu_void_ptr : Extension<
|
def ext_gnu_void_ptr : Extension<
|
||||||
"use of GNU void* extension">;
|
"use of GNU void* extension">, InGroup<PointerArith>;
|
||||||
def ext_gnu_ptr_func_arith : Extension<
|
def ext_gnu_ptr_func_arith : Extension<
|
||||||
"arithmetic on pointer to function type %0 is a GNU extension">;
|
"arithmetic on pointer to function type %0 is a GNU extension">,
|
||||||
|
InGroup<PointerArith>;
|
||||||
def error_readonly_property_assignment : Error<
|
def error_readonly_property_assignment : Error<
|
||||||
"assigning to property with 'readonly' attribute not allowed">;
|
"assigning to property with 'readonly' attribute not allowed">;
|
||||||
def ext_integer_increment_complex : Extension<
|
def ext_integer_increment_complex : Extension<
|
||||||
|
|
Загрузка…
Ссылка в новой задаче