/include/clang/Basic/DiagnosticSemaKinds.td
Unknown | 3166 lines | 2969 code | 197 blank | 0 comment | 0 complexity | 843804699b53431aec84986d4b94b16e MD5 | raw file
Possible License(s): JSON
Large files files are truncated, but you can click here to view the full file
- //==--- DiagnosticSemaKinds.td - libsema diagnostics ----------------------===//
- //
- // The LLVM Compiler Infrastructure
- //
- // This file is distributed under the University of Illinois Open Source
- // License. See LICENSE.TXT for details.
- //
- //===----------------------------------------------------------------------===//
- //===----------------------------------------------------------------------===//
- // Semantic Analysis
- //===----------------------------------------------------------------------===//
- let Component = "Sema" in {
- let CategoryName = "Semantic Issue" in {
- // Constant expressions
- def err_expr_not_ice : Error<
- "expression is not an integer constant expression">;
- def ext_expr_not_ice : Extension<
- "expression is not integer constant expression "
- "(but is allowed as an extension)">;
- def ext_null_pointer_expr_not_ice : Extension<
- "null pointer expression is not an integer constant expression "
- "(but is allowed as an extension)">;
- // Semantic analysis of constant literals.
- def ext_predef_outside_function : Warning<
- "predefined identifier is only valid inside function">;
- def warn_float_overflow : Warning<
- "magnitude of floating-point constant too large for type %0; maximum is %1">,
- InGroup<LiteralRange>;
- def warn_float_underflow : Warning<
- "magnitude of floating-point constant too small for type %0; minimum is %1">,
- InGroup<LiteralRange>;
- // C99 variable-length arrays
- def ext_vla : Extension<
- "variable length arrays are a C99 feature, accepted as an extension">,
- InGroup<VLA>;
- def err_vla_non_pod : Error<"variable length array of non-POD element type %0">;
- def err_vla_in_sfinae : Error<
- "variable length array cannot be formed during template argument deduction">;
- def err_array_star_in_function_definition : Error<
- "variable length array must be bound in function definition">;
- def err_vla_decl_in_file_scope : Error<
- "variable length array declaration not allowed at file scope">;
- def err_vla_decl_has_static_storage : Error<
- "variable length array declaration can not have 'static' storage duration">;
- def err_vla_decl_has_extern_linkage : Error<
- "variable length array declaration can not have 'extern' linkage">;
-
- // C99 variably modified types
- def err_variably_modified_template_arg : Error<
- "variably modified type %0 cannot be used as a template argument">;
- def err_variably_modified_nontype_template_param : Error<
- "non-type template parameter of variably modified type %0">;
- // C99 Designated Initializers
- def err_array_designator_negative : Error<
- "array designator value '%0' is negative">;
- def err_array_designator_empty_range : Error<
- "array designator range [%0, %1] is empty">;
- def err_array_designator_non_array : Error<
- "array designator cannot initialize non-array type %0">;
- def err_array_designator_too_large : Error<
- "array designator index (%0) exceeds array bounds (%1)">;
- def err_field_designator_non_aggr : Error<
- "field designator cannot initialize a "
- "%select{non-struct, non-union|non-class}0 type %1">;
- def err_field_designator_unknown : Error<
- "field designator %0 does not refer to any field in type %1">;
- def err_field_designator_nonfield : Error<
- "field designator %0 does not refer to a non-static data member">;
- def note_field_designator_found : Note<"field designator refers here">;
- def err_designator_for_scalar_init : Error<
- "designator in initializer for scalar type %0">;
- def warn_subobject_initializer_overrides : Warning<
- "subobject initialization overrides initialization of other fields "
- "within its enclosing subobject">, InGroup<InitializerOverrides>;
- def warn_initializer_overrides : Warning<
- "initializer overrides prior initialization of this subobject">,
- InGroup<InitializerOverrides>;
- def note_previous_initializer : Note<
- "previous initialization %select{|with side effects }0is here"
- "%select{| (side effects may not occur at run time)}0">;
- def err_designator_into_flexible_array_member : Error<
- "designator into flexible array member subobject">;
- def note_flexible_array_member : Note<
- "initialized flexible array member %0 is here">;
- def ext_flexible_array_init : Extension<
- "flexible array initialization is a GNU extension">, InGroup<GNU>;
- // Declarations.
- def ext_anon_param_requires_type_specifier : Extension<
- "type specifier required for unnamed parameter, defaults to int">;
- def err_bad_variable_name : Error<
- "'%0' cannot be the name of a variable or data member">;
- def err_parameter_name_omitted : Error<"parameter name omitted">;
- def warn_unused_parameter : Warning<"unused parameter %0">,
- InGroup<UnusedParameter>, DefaultIgnore;
- def warn_unused_variable : Warning<"unused variable %0">,
- InGroup<UnusedVariable>, DefaultIgnore;
- def warn_unused_exception_param : Warning<"unused exception parameter %0">,
- InGroup<UnusedExceptionParameter>, DefaultIgnore;
- def warn_decl_in_param_list : Warning<
- "declaration of %0 will not be visible outside of this function">;
- def warn_unused_function : Warning<"unused function %0">,
- InGroup<UnusedFunction>, DefaultIgnore;
-
- def warn_implicit_function_decl : Warning<
- "implicit declaration of function %0">,
- InGroup<ImplicitFunctionDeclare>, DefaultIgnore;
- def ext_implicit_function_decl : ExtWarn<
- "implicit declaration of function %0 is invalid in C99">,
- InGroup<ImplicitFunctionDeclare>;
- def err_ellipsis_first_arg : Error<
- "ISO C requires a named argument before '...'">;
- def err_declarator_need_ident : Error<"declarator requires an identifier">;
- def err_bad_language : Error<"unknown linkage language">;
- def warn_use_out_of_scope_declaration : Warning<
- "use of out-of-scope declaration of %0">;
- def err_inline_non_function : Error<
- "'inline' can only appear on functions">;
- def warn_decl_shadow :
- Warning<"declaration shadows a %select{"
- "local variable|"
- "variable in %2|"
- "static data member of %2|"
- "field of %2}1">,
- InGroup<Shadow>, DefaultIgnore;
- // C++ using declarations
- def err_using_requires_qualname : Error<
- "using declaration requires a qualified name">;
- def err_using_typename_non_type : Error<
- "'typename' keyword used on a non-type">;
- def err_using_dependent_value_is_type : Error<
- "dependent using declaration resolved to type without 'typename'">;
- def err_using_decl_nested_name_specifier_is_not_class : Error<
- "using declaration in class refers into '%0', which is not a class">;
- def err_using_decl_nested_name_specifier_is_current_class : Error<
- "using declaration refers to its own class">;
- def err_using_decl_nested_name_specifier_is_not_base_class : Error<
- "using declaration refers into '%0', which is not a base class of %1">;
- def err_using_decl_can_not_refer_to_class_member : Error<
- "using declaration can not refer to class member">;
- def err_using_decl_can_not_refer_to_namespace : Error<
- "using declaration can not refer to namespace">;
- def err_using_decl_constructor : Error<
- "using declaration can not refer to a constructor">;
- def err_using_decl_destructor : Error<
- "using declaration can not refer to a destructor">;
- def err_using_decl_template_id : Error<
- "using declaration can not refer to a template specialization">;
- def note_using_decl_target : Note<"target of using declaration">;
- def note_using_decl_conflict : Note<"conflicting declaration">;
- def err_using_decl_redeclaration : Error<"redeclaration of using decl">;
- def err_using_decl_conflict : Error<
- "target of using declaration conflicts with declaration already in scope">;
- def err_using_decl_conflict_reverse : Error<
- "declaration conflicts with target of using declaration already in scope">;
- def note_using_decl : Note<"%select{|previous }0using declaration">;
- def warn_access_decl_deprecated : Warning<
- "access declarations are deprecated; use using declarations instead">,
- InGroup<Deprecated>;
- def err_invalid_thread : Error<
- "'__thread' is only allowed on variable declarations">;
- def err_thread_non_global : Error<
- "'__thread' variables must have global storage">;
- def err_thread_unsupported : Error<
- "thread-local storage is unsupported for the current target">;
- def warn_maybe_falloff_nonvoid_function : Warning<
- "control may reach end of non-void function">,
- InGroup<ReturnType>;
- def warn_falloff_nonvoid_function : Warning<
- "control reaches end of non-void function">,
- InGroup<ReturnType>;
- def err_maybe_falloff_nonvoid_block : Error<
- "control may reach end of non-void block">;
- def err_falloff_nonvoid_block : Error<
- "control reaches end of non-void block">;
- def warn_suggest_noreturn_function : Warning<
- "function could be attribute 'noreturn'">,
- InGroup<DiagGroup<"missing-noreturn">>, DefaultIgnore;
- def warn_suggest_noreturn_block : Warning<
- "block could be attribute 'noreturn'">,
- InGroup<DiagGroup<"missing-noreturn">>, DefaultIgnore;
- def warn_unreachable : Warning<"will never be executed">,
- InGroup<DiagGroup<"unreachable-code">>, DefaultIgnore;
- /// Built-in functions.
- def ext_implicit_lib_function_decl : ExtWarn<
- "implicitly declaring C library function '%0' with type %1">;
- def note_please_include_header : Note<
- "please include the header <%0> or explicitly provide a "
- "declaration for '%1'">;
- def note_previous_builtin_declaration : Note<"%0 is a builtin with type %1">;
- def err_implicit_decl_requires_stdio : Error<
- "implicit declaration of '%0' requires inclusion of the header <stdio.h>">;
- def err_implicit_decl_requires_setjmp : Error<
- "implicit declaration of '%0' requires inclusion of the header <setjmp.h>">;
- def warn_redecl_library_builtin : Warning<
- "incompatible redeclaration of library function %0">;
- def err_builtin_definition : Error<"definition of builtin function %0">;
- def err_types_compatible_p_in_cplusplus : Error<
- "__builtin_types_compatible_p is not valid in C++">;
- def warn_builtin_unknown : Warning<"use of unknown builtin %0">, DefaultError;
- /// main()
- // static/inline main() are not errors in C, just in C++.
- def warn_unusual_main_decl : Warning<"'main' should not be declared "
- "%select{static|inline|static or inline}0">;
- def err_unusual_main_decl : Error<"'main' is not allowed to be declared "
- "%select{static|inline|static or inline}0">;
- 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">;
- def warn_main_one_arg : Warning<"only one parameter on 'main' declaration">;
- 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">;
- /// parser diagnostics
- def ext_typedef_without_a_name : ExtWarn<"typedef requires a name">;
- def err_statically_allocated_object : Error<
- "interface type cannot be statically allocated">;
- def err_object_cannot_be_passed_returned_by_value : Error<
- "interface type %1 cannot be %select{returned|passed}0 by value"
- "; did you forget * in %1">;
- def warn_enum_value_overflow : Warning<"overflow in enumeration value">;
- def warn_pragma_options_align_unsupported_option : Warning<
- "unsupported alignment option in '#pragma options align'">;
- def warn_pragma_options_align_reset_failed : Warning<
- "#pragma options align=reset failed: %0">;
- def err_pragma_options_align_mac68k_target_unsupported : Error<
- "mac68k alignment pragma is not supported on this target">;
- def warn_pragma_pack_invalid_alignment : Warning<
- "expected #pragma pack parameter to be '1', '2', '4', '8', or '16'">;
- // Follow the MSVC implementation.
- def warn_pragma_pack_show : Warning<"value of #pragma pack(show) == %0">;
- def warn_pragma_pack_pop_identifer_and_alignment : Warning<
- "specifying both a name and alignment to 'pop' is undefined">;
- def warn_pragma_pack_pop_failed : Warning<"#pragma pack(pop, ...) failed: %0">;
- def warn_pragma_unused_undeclared_var : Warning<
- "undeclared variable %0 used as an argument for '#pragma unused'">;
- def warn_pragma_unused_expected_localvar : Warning<
- "only local variables can be arguments to '#pragma unused'">;
- def err_unsupported_pragma_weak : Error<
- "using '#pragma weak' to refer to an undeclared identifier is not yet supported">;
- /// Objective-C parser diagnostics
- def err_duplicate_class_def : Error<
- "duplicate interface definition for class %0">;
- def err_undef_superclass : Error<
- "cannot find interface declaration for %0, superclass of %1">;
- def err_no_nsconstant_string_class : Error<
- "cannot find interface declaration for %0">;
- def err_recursive_superclass : Error<
- "trying to recursively use %0 as superclass of %1">;
- def warn_previous_alias_decl : Warning<"previously declared alias is ignored">;
- def err_conflicting_aliasing_type : Error<"conflicting types for alias %0">;
- def warn_undef_interface : Warning<"cannot find interface declaration for %0">;
- def warn_duplicate_protocol_def : Warning<"duplicate protocol definition of %0 is ignored">;
- def err_protocol_has_circular_dependency : Error<
- "protocol has circular dependency">;
- def err_undeclared_protocol : Error<"cannot find protocol declaration for %0">;
- def warn_undef_protocolref : Warning<"cannot find protocol definition for %0">;
- def warn_readonly_property : Warning<
- "attribute 'readonly' of property %0 restricts attribute "
- "'readwrite' of property inherited from %1">;
- def warn_property_attribute : Warning<
- "property %0 '%1' attribute does not match the property inherited from %2">;
- def warn_property_types_are_incompatible : Warning<
- "property type %0 is incompatible with type %1 inherited from %2">;
- def err_undef_interface : Error<"cannot find interface declaration for %0">;
- def err_class_extension_after_impl : Error<
- "cannot declare class extension for %0 after class implementation">;
- def note_implementation_declared : Note<
- "class implementation is declared here">;
- def warn_dup_category_def : Warning<
- "duplicate definition of category %1 on interface %0">;
- def err_conflicting_super_class : Error<"conflicting super class name %0">;
- def err_dup_implementation_class : Error<"reimplementation of class %0">;
- def err_dup_implementation_category : Error<
- "reimplementation of category %1 for class %0">;
- def err_conflicting_ivar_type : Error<
- "instance variable %0 has conflicting type: %1 vs %2">;
- def err_duplicate_ivar_declaration : Error<
- "instance variable is already declared">;
- def warn_on_superclass_use : Warning<
- "class implementation may not have super class">;
- def err_conflicting_ivar_bitwidth : Error<
- "instance variable %0 has conflicting bit-field width">;
- def err_conflicting_ivar_name : Error<
- "conflicting instance variable names: %0 vs %1">;
- def err_inconsistant_ivar_count : Error<
- "inconsistent number of instance variables specified">;
- def warn_incomplete_impl : Warning<"incomplete implementation">;
- def note_undef_method_impl : Note<"method definition for %0 not found">;
- def note_required_for_protocol_at :
- Note<"required for direct or indirect protocol %0">;
- def warn_conflicting_ret_types : Warning<
- "conflicting return type in implementation of %0: %1 vs %2">;
- def warn_conflicting_param_types : Warning<
- "conflicting parameter types in implementation of %0: %1 vs %2">;
- def warn_conflicting_variadic :Warning<
- "conflicting variadic declaration of method and its implementation">;
- def warn_implements_nscopying : Warning<
- "default assign attribute on property %0 which implements "
- "NSCopying protocol is not appropriate with -fobjc-gc[-only]">;
- def warn_multiple_method_decl : Warning<"multiple methods named %0 found">;
- def warn_accessor_property_type_mismatch : Warning<
- "type of property %0 does not match type of accessor %1">;
- def note_declared_at : Note<"declared here">;
- def err_setter_type_void : Error<"type of setter must be void">;
- def err_duplicate_method_decl : Error<"duplicate declaration of method %0">;
- def warn_missing_atend : Warning<"'@end' is missing in implementation context">;
- def err_objc_var_decl_inclass :
- Error<"cannot declare variable inside @interface or @protocol">;
- def error_missing_method_context : Error<
- "missing context for method declaration">;
- def err_objc_property_attr_mutually_exclusive : Error<
- "property attributes '%0' and '%1' are mutually exclusive">;
- def err_objc_property_requires_object : Error<
- "property with '%0' attribute must be of object type">;
- def warn_objc_property_no_assignment_attribute : Warning<
- "no 'assign', 'retain', or 'copy' attribute is specified - "
- "'assign' is assumed">;
- def warn_objc_property_default_assign_on_object : Warning<
- "default property attribute 'assign' not appropriate for non-gc object">;
- def warn_property_attr_mismatch : Warning<
- "property attribute in continuation class does not match the primary class">;
- def warn_objc_property_copy_missing_on_block : Warning<
- "'copy' attribute must be specified for the block property "
- "when -fobjc-gc-only is specified">;
- def warn_atomic_property_rule : Warning<
- "writable atomic property %0 cannot pair a synthesized setter/getter "
- "with a user defined setter/getter">;
- def err_use_continuation_class : Error<
- "illegal declaration of property in continuation class %0"
- ": attribute must be readwrite, while its primary must be readonly">;
- def err_continuation_class : Error<"continuation class has no primary class">;
- def err_property_type : Error<"property cannot have array or function type %0">;
- def error_missing_property_context : Error<
- "missing context for property implementation declaration">;
- def error_bad_property_decl : Error<
- "property implementation must have its declaration in interface %0">;
- def error_category_property : Error<
- "property declared in category %0 cannot be implemented in "
- "class implementation">;
- def note_property_declare : Note<
- "property declared here">;
- def error_synthesize_category_decl : Error<
- "@synthesize not allowed in a category's implementation">;
- def error_reference_property : Error<
- "property of reference type is not supported">;
- def error_missing_property_interface : Error<
- "property implementation in a category with no category declaration">;
- def error_bad_category_property_decl : Error<
- "property implementation must have its declaration in the category %0">;
- def error_bad_property_context : Error<
- "property implementation must be in a class or category implementation">;
- def error_missing_property_ivar_decl : Error<
- "synthesized property %0 must either be named the same as a compatible"
- " ivar or must explicitly name an ivar">;
- def error_synthesized_ivar_yet_not_supported : Error<
- "instance variable synthesis not yet supported"
- " (need to declare %0 explicitly)">;
- def error_property_ivar_type : Error<
- "type of property %0 (%1) does not match type of ivar %2 (%3)">;
- def error_ivar_in_superclass_use : Error<
- "property %0 attempting to use ivar %1 declared in super class %2">;
- def error_weak_property : Error<
- "existing ivar %1 for __weak property %0 must be __weak">;
- def error_strong_property : Error<
- "existing ivar %1 for a __strong property %0 must be garbage collectable">;
- def error_dynamic_property_ivar_decl : Error<
- "dynamic property can not have ivar specification">;
- def error_duplicate_ivar_use : Error<
- "synthesized properties %0 and %1 both claim ivar %2">;
- def error_property_implemented : Error<"property %0 is already implemented">;
- def warn_objc_property_attr_mutually_exclusive : Warning<
- "property attributes '%0' and '%1' are mutually exclusive">,
- InGroup<ReadOnlySetterAttrs>, DefaultIgnore;
- def warn_undeclared_selector : Warning<
- "undeclared selector %0">, InGroup<UndeclaredSelector>, DefaultIgnore;
- def warn_unimplemented_protocol_method : Warning<
- "method in protocol not implemented">, InGroup<Protocol>;
- // C++ declarations
- def err_static_assert_expression_is_not_constant : Error<
- "static_assert expression is not an integral constant expression">;
- def err_static_assert_failed : Error<"static_assert failed \"%0\"">;
- def err_unexpected_friend : Error<
- "friends can only be classes or functions">;
- def ext_enum_friend : ExtWarn<
- "enumeration type %0 cannot be a friend">;
- def ext_nonclass_type_friend : ExtWarn<
- "non-class type %0 cannot be a friend">;
- def err_friend_is_member : Error<
- "friends cannot be members of the declaring class">;
- def ext_unelaborated_friend_type : ExtWarn<
- "must specify '%select{struct|union|class|enum}0' to befriend %1">;
- def err_qualified_friend_not_found : Error<
- "no function named %0 with type %1 was found in the specified scope">;
- def err_introducing_special_friend : Error<
- "must use a qualified name when declaring a %select{constructor|"
- "destructor|conversion operator}0 as a friend">;
- def err_tagless_friend_type_template : Error<
- "friend type templates must use an elaborated type">;
- def err_abstract_type_in_decl : Error<
- "%select{return|parameter|variable|field}0 type %1 is an abstract class">;
- def err_allocation_of_abstract_type : Error<
- "allocation of an object of abstract type %0">;
- def err_throw_abstract_type : Error<
- "cannot throw an object of abstract type %0">;
- def err_array_of_abstract_type : Error<"array of abstract class type %0">;
- def err_multiple_final_overriders : Error<
- "virtual function %q0 has more than one final overrider in %1">;
- def note_final_overrider : Note<"final overrider of %q0 in %1">;
- def err_type_defined_in_type_specifier : Error<
- "%0 can not be defined in a type specifier">;
- def err_type_defined_in_result_type : Error<
- "%0 can not be defined in the result type of a function">;
- def err_type_defined_in_param_type : Error<
- "%0 can not be defined in a parameter type">;
- def note_pure_virtual_function : Note<
- "pure virtual function %0">;
- def err_deleted_non_function : Error<
- "only functions can have deleted definitions">;
- def err_deleted_decl_not_first : Error<
- "deleted definition must be first declaration">;
- def warn_weak_vtable : Warning<
- "%0 has no out-of-line virtual method definitions; its vtable will be "
- "emitted in every translation unit">,
- InGroup<DiagGroup<"weak-vtables">>, DefaultIgnore;
- // C++ exception specifications
- def err_exception_spec_in_typedef : Error<
- "exception specifications are not allowed in typedefs">;
- def err_distant_exception_spec : Error<
- "exception specifications are not allowed beyond a single level "
- "of indirection">;
- def err_incomplete_in_exception_spec : Error<
- "%select{|pointer to |reference to }0incomplete type %1 is not allowed "
- "in exception specification">;
- def err_mismatched_exception_spec : Error<
- "exception specification in declaration does not match previous declaration">;
- def err_override_exception_spec : Error<
- "exception specification of overriding function is more lax than "
- "base version">;
- def err_incompatible_exception_specs : Error<
- "target exception specification is not superset of source">;
- def err_deep_exception_specs_differ : Error<
- "exception specifications of %select{return|argument}0 types differ">;
- def warn_missing_exception_specification : Warning<
- "%0 is missing exception specification '%1'">;
- // C++ access checking
- def err_class_redeclared_with_different_access : Error<
- "%0 redeclared with '%1' access">;
- def err_access : Error<
- "%1 is a %select{private|protected}0 member of %3">, NoSFINAE;
- def err_access_ctor : Error<
- "calling a %select{private|protected}0 constructor of class %2">, NoSFINAE;
- def ext_rvalue_to_reference_access_ctor : ExtWarn<
- "C++98 requires an accessible copy constructor for class %2 when binding "
- "a reference to a temporary; was %select{private|protected}0">,
- NoSFINAE, InGroup<BindToTemporaryCopy>;
- def err_access_base : Error<
- "%select{base class|inherited virtual base class}0 %1 has %select{private|"
- "protected}3 %select{constructor|copy constructor|copy assignment operator|"
- "destructor}2">, NoSFINAE;
- def err_access_field: Error<
- "field of type %0 has %select{private|protected}2 %select{constructor|copy "
- "constructor|copy assignment operator|destructor}1">, NoSFINAE;
- def err_access_ctor_field :
- Error<"field of type %1 has %select{private|protected}2 constructor">,
- NoSFINAE;
- def err_access_dtor_base :
- Error<"base class %0 has %select{private|protected}1 destructor">,
- NoSFINAE;
- def err_access_dtor_vbase :
- Error<"inherited virtual base class %0 has "
- "%select{private|protected}1 destructor">,
- NoSFINAE;
- def err_access_dtor_temp :
- Error<"temporary of type %0 has %select{private|protected}1 destructor">,
- NoSFINAE;
- def err_access_dtor_field :
- Error<"field of type %1 has %select{private|protected}2 destructor">,
- NoSFINAE;
- def err_access_dtor_var :
- Error<"variable of type %1 has %select{private|protected}2 destructor">,
- NoSFINAE;
- def err_access_assign_field :
- Error<"field of type %1 has %select{private|protected}2 copy assignment"
- " operator">,
- NoSFINAE;
- def err_access_assign_base :
- Error<"base class %0 has %select{private|protected}1 copy assignment"
- " operator">,
- NoSFINAE;
- def err_access_copy_field :
- Error<"field of type %1 has %select{private|protected}2 copy constructor">,
- NoSFINAE;
- def err_access_copy_base :
- Error<"base class %0 has %select{private|protected}1 copy constructor">,
- NoSFINAE;
- def err_access_dtor_ivar :
- Error<"instance variable of type %0 has %select{private|protected}1 "
- "destructor">,
- NoSFINAE;
- def note_previous_access_declaration : Note<
- "previously declared '%1' here">;
- def err_access_outside_class : Error<
- "access to %select{private|protected}0 member outside any class context">;
- def note_access_natural : Note<
- "%select{|implicitly }1declared %select{private|protected}0 here">;
- def note_access_constrained_by_path : Note<
- "constrained by %select{|implicitly }1%select{private|protected}0"
- " inheritance here">;
-
- // C++ name lookup
- def err_incomplete_nested_name_spec : Error<
- "incomplete type %0 named in nested name specifier">;
- def err_dependent_nested_name_spec : Error<
- "nested name specifier for a declaration cannot depend on a template "
- "parameter">;
- def err_nested_name_member_ref_lookup_ambiguous : Error<
- "lookup of %0 in member access expression is ambiguous">;
- def ext_nested_name_member_ref_lookup_ambiguous : ExtWarn<
- "lookup of %0 in member access expression is ambiguous; using member of %1">,
- InGroup<AmbigMemberTemplate>;
- def note_ambig_member_ref_object_type : Note<
- "lookup in the object type %0 refers here">;
- def note_ambig_member_ref_scope : Note<
- "lookup from the current scope refers here">;
- def err_qualified_member_nonclass : Error<
- "qualified member access refers to a member in %0">;
- def err_incomplete_member_access : Error<
- "member access into incomplete type %0">;
- def err_incomplete_type : Error<
- "incomplete type %0 where a complete type is required">;
-
- // C++ class members
- def err_storageclass_invalid_for_member : Error<
- "storage class specified for a member declaration">;
- def err_mutable_function : Error<"'mutable' cannot be applied to functions">;
- def err_mutable_reference : Error<"'mutable' cannot be applied to references">;
- def err_mutable_const : Error<"'mutable' and 'const' cannot be mixed">;
- def err_mutable_nonmember : Error<
- "'mutable' can only be applied to member variables">;
- def err_virtual_non_function : Error<
- "'virtual' can only appear on non-static member functions">;
- def err_virtual_out_of_class : Error<
- "'virtual' can only be specified inside the class definition">;
- def err_explicit_non_function : Error<
- "'explicit' can only appear on non-static member functions">;
- def err_explicit_out_of_class : Error<
- "'explicit' can only be specified inside the class definition">;
- def err_explicit_non_ctor_or_conv_function : Error<
- "'explicit' can only be applied to a constructor or conversion function">;
- def err_static_not_bitfield : Error<"static member %0 cannot be a bit-field">;
- def err_static_out_of_line : Error<
- "'static' can only be specified inside the class definition">;
- def err_typedef_not_bitfield : Error<"typedef member %0 cannot be a bit-field">;
- def err_not_integral_type_bitfield : Error<
- "bit-field %0 has non-integral type %1">;
- def err_not_integral_type_anon_bitfield : Error<
- "anonymous bit-field has non-integral type %0">;
- def err_member_initialization : Error<
- "%0 can only be initialized if it is a static const integral data member">;
- def err_member_function_initialization : Error<
- "initializer on function does not look like a pure-specifier">;
- def err_non_virtual_pure : Error<
- "%0 is not virtual and cannot be declared pure">;
- def err_implicit_object_parameter_init : Error<
- "cannot initialize object parameter of type %0 with an expression "
- "of type %1">;
- def err_qualified_member_of_unrelated : Error<
- "%q0 is not a member of class %1">;
- def note_field_decl : Note<"member is declared here">;
- def note_ivar_decl : Note<"ivar is declared here">;
- def note_bitfield_decl : Note<"bit-field is declared here">;
- def note_previous_decl : Note<"%0 declared here">;
- def note_member_synthesized_at : Note<
- "implicit default %select{constructor|copy constructor|"
- "copy assignment operator|destructor}0 for %1 first required here">;
- def err_missing_default_ctor : Error<
- "%select{|implicit default }0constructor for %1 must explicitly initialize "
- "the %select{base class|member}2 %3 which does not have a default "
- "constructor">;
- def err_illegal_union_member : Error<
- "union member %0 has a non-trivial %select{constructor|"
- "copy constructor|copy assignment operator|destructor}1">;
- def note_nontrivial_has_virtual : Note<
- "because type %0 has a virtual %select{member function|base class}1">;
- def note_nontrivial_has_nontrivial : Note<
- "because type %0 has a %select{member|base class}1 with a non-trivial "
- "%select{constructor|copy constructor|copy assignment operator|destructor}2">;
- def note_nontrivial_user_defined : Note<
- "because type %0 has a user-declared %select{constructor|copy constructor|"
- "copy assignment operator|destructor}1">;
- def err_different_return_type_for_overriding_virtual_function : Error<
- "virtual function %0 has a different return type (%1) than the "
- "function it overrides (which has return type %2)">;
- def note_overridden_virtual_function : Note<
- "overridden virtual function is here">;
- def err_covariant_return_inaccessible_base : Error<
- "invalid covariant return for virtual function: %1 is a "
- "%select{private|protected}2 base class of %0">, NoSFINAE;
- def err_covariant_return_ambiguous_derived_to_base_conv : Error<
- "return type of virtual function %3 is not covariant with the return type of "
- "the function it overrides (ambiguous conversion from derived class "
- "%0 to base class %1:%2)">;
- def err_covariant_return_not_derived : Error<
- "return type of virtual function %0 is not covariant with the return type of "
- "the function it overrides (%1 is not derived from %2)">;
- def err_covariant_return_incomplete : Error<
- "return type of virtual function %0 is not covariant with the return type of "
- "the function it overrides (%1 is incomplete)">;
- def err_covariant_return_type_different_qualifications : Error<
- "return type of virtual function %0 is not covariant with the return type of "
- "the function it overrides (%1 has different qualifiers than %2)">;
- def err_covariant_return_type_class_type_more_qualified : Error<
- "return type of virtual function %0 is not covariant with the return type of "
- "the function it overrides (class type %1 is more qualified than class "
- "type %2">;
-
- // C++ constructors
- def err_constructor_cannot_be : Error<"constructor cannot be declared '%0'">;
- def err_invalid_qualified_constructor : Error<
- "'%0' qualifier is not allowed on a constructor">;
- def err_constructor_return_type : Error<
- "constructor cannot have a return type">;
- def err_constructor_redeclared : Error<"constructor cannot be redeclared">;
- def err_constructor_byvalue_arg : Error<
- "copy constructor must pass its first argument by reference">;
- def warn_no_constructor_for_refconst : Warning<
- "%select{struct|union|class|enum}0 %1 does not declare any constructor to "
- "initialize its non-modifiable members">;
- def note_refconst_member_not_initialized : Note<
- "%select{const|reference}0 member %1 will never be initialized">;
- // C++ destructors
- def err_destructor_not_member : Error<
- "destructor must be a non-static member function">;
- def err_destructor_cannot_be : Error<"destructor cannot be declared '%0'">;
- def err_invalid_qualified_destructor : Error<
- "'%0' qualifier is not allowed on a destructor">;
- def err_destructor_return_type : Error<"destructor cannot have a return type">;
- def err_destructor_redeclared : Error<"destructor cannot be redeclared">;
- def err_destructor_with_params : Error<"destructor cannot have any parameters">;
- def err_destructor_variadic : Error<"destructor cannot be variadic">;
- def err_destructor_typedef_name : Error<
- "destructor cannot be declared using a typedef %0 of the class name">;
- def err_destructor_name : Error<
- "expected the class name after '~' to name the enclosing class">;
- def err_destructor_class_name : Error<
- "expected the class name after '~' to name a destructor">;
- def err_ident_in_pseudo_dtor_not_a_type : Error<
- "identifier %0 in pseudo-destructor expression does not name a type">;
- // C++ initialization
- def err_init_conversion_failed : Error<
- "cannot initialize %select{a variable|a parameter|return object|an "
- "exception object|a member subobject|an array element|a new value|a value|a "
- "base class|a vector element}0 of type %1 with an %select{rvalue|lvalue}2 of "
- "type %3">;
- def err_lvalue_to_rvalue_ref : Error<"rvalue reference cannot bind to lvalue">;
- def err_invalid_initialization : Error<
- "invalid initialization of reference of type %0 from expression of type %1">;
- def err_lvalue_to_rvalue_ambig_ref : Error<"rvalue reference cannot bind to lvalue "
- "due to multiple conversion functions">;
- def err_not_reference_to_const_init : Error<
- "%select{non-const|volatile}0 lvalue reference to type %1 cannot be "
- "initialized with a %select{value|temporary}2 of type %3">;
- def err_lvalue_reference_bind_to_temporary : Error<
- "%select{non-const|volatile}0 lvalue reference to type %1 cannot bind to a "
- "temporary of type %2">;
- def err_lvalue_reference_bind_to_unrelated : Error<
- "%select{non-const|volatile}0 lvalue reference to type %1 cannot bind to a "
- "value of unrelated type %2">;
- def err_reference_bind_drops_quals : Error<
- "binding of reference to type %0 to a value of type %1 drops qualifiers">;
- def err_reference_bind_failed : Error<
- "reference to type %0 could not bind to an %select{rvalue|lvalue}1 of type "
- "%2">;
- def err_reference_bind_init_list : Error<
- "reference to type %0 cannot bind to an initializer list">;
- def err_init_list_bad_dest_type : Error<
- "%select{|non-aggregate }0type %1 cannot be initialized with an initializer "
- "list">;
- def err_reference_init_drops_quals : Error<
- "initialization of reference to type %0 with a %select{value|temporary}1 of type %2 drops "
- "qualifiers">;
- def err_reference_bind_to_bitfield : Error<
- "%select{non-const|volatile}0 reference cannot bind to bit-field %1">;
- def err_reference_bind_to_vector_element : Error<
- "%select{non-const|volatile}0 reference cannot bind to vector element">;
- def err_reference_var_requires_init : Error<
- "declaration of reference variable %0 requires an initializer">;
- def err_const_var_requires_init : Error<
- "declaration of const variable '%0' requires an initializer">;
- def err_reference_without_init : Error<
- "reference to type %0 requires an initializer">;
- def err_reference_has_multiple_inits : Error<
- "reference cannot be initialized with multiple values">;
- def err_init_non_aggr_init_list : Error<
- "initialization of non-aggregate type %0 with an initializer list">;
- def err_init_reference_member_uninitialized : Error<
- "reference member of type %0 uninitialized">;
- def note_uninit_reference_member : Note<
- "uninitialized reference member is here">;
- def warn_field_is_uninit : Warning<"field is uninitialized when used here">,
- InGroup<DiagGroup<"uninitialized">>;
- def err_init_incomplete_type : Error<"initialization of incomplete type %0">;
- def err_temp_copy_no_viable : Error<
- "no viable constructor %select{copying variable|copying parameter|"
- "returning object|throwing object|copying member subobject|copying array "
- "element|allocating object|copying temporary|initializing base subobject|"
- "initializing vector element}0 of type %1">;
- def ext_rvalue_to_reference_temp_copy_no_viable : ExtWarn<
- "no viable constructor %select{copying variable|copying parameter|"
- "returning object|throwing object|copying member subobject|copying array "
- "element|allocating object|copying temporary|initializing base subobject|"
- "initializing vector element}0 of type %1; C++98 requires a copy "
- "constructor when binding a reference to a temporary">,
- InGroup<BindToTemporaryCopy>;
- def err_temp_copy_ambiguous : Error<
- "ambiguous constructor call when %select{copying variable|copying "
- "parameter|returning object|throwing object|copying member subobject|copying "
- "array element|allocating object|copying temporary|initializing base subobject|"
- "initializing vector element}0 of type %1">;
- def err_temp_copy_deleted : Error<
- "%select{copying variable|copying parameter|returning object|throwing "
- "object|copying member subobject|copying array element|allocating object|"
- "copying temporary|initializing base subobject|initializing vector element}0 "
- "of type %1 invokes deleted constructor">;
- def err_temp_copy_incomplete : Error<
- "copying a temporary object of incomplete type %0">;
- // C++0x decltype
- def err_cannot_determine_declared_type_of_overloaded_function : Error<
- "cannot determine the %select{type|declared type}0 of an overloaded "
- "function">;
-
- // C++0x auto
- def err_auto_variable_cannot_appear_in_own_initializer : Error<
- "variable %0 declared with 'auto' type cannot appear in its own initializer">;
- def err_illegal_decl_array_of_auto : Error<
- "'%0' declared as array of 'auto'">;
- def err_auto_not_allowed : Error<
- "'auto' not allowed in %select{function prototype|struct member|union member"
- "|class member|exception declaration|template parameter|block literal}0">;
- def err_auto_var_requires_init : Error<
- "declaration of variable %0 with type %1 requires an initializer">;
-
- // C++0x attributes
- def err_repeat_attribute : Error<"'%0' attribute cannot be repeated">;
- // C++0x [[final]]
- def err_final_function_overridden : Error<
- "declaration of %0 overrides a 'final' function">;
- def err_final_base : Error<
- "derivation from 'final' %0">;
-
- // Objective-C++
- def err_objc_decls_may_only_appear_in_global_scope : Error<
- "Objective-C declarations may only appear in global scope">;
- def err_nsobject_attribute : Error<
- "__attribute ((NSObject)) is for pointer types only">;
- // Attributes
- def err_attribute_can_be_applied_only_to_symbol_declaration : Error<
- "%0 attribute can be applied only to symbol declaration">;
- def err_attributes_are_not_compatible : Error<
- "%0 and %1 attributes are not compatible">;
- def err_attribute_wrong_number_arguments : Error<
- "attribute requires %0 argument(s)">;
- def err_attribute_missing_parameter_name : Error<
- "attribute requires unquoted parameter">;
- def err_attribute_invalid_vector_type : Error<"invalid vector type %0">;
- def err_attribute_argument_not_int : Error<
- "'%0' attribute requires integer constant">;
- def err_attribute_argument_outof_range : Error<
- "init_priority attribute requires integer constant between "
- "101 and 65535 inclusive">;
- def err_init_priority_object_attr : Error<
- "can only use ‘init_priority’ attribute on file-scope definitions "
- "of objects of class type">;
- def err_attribute_argument_n_not_int : Error<
- "'%0' attribute requires parameter %1 to be an integer constant">;
- def err_attribute_argument_n_not_string : Error<
- "'%0' attribute requires parameter %1 to be a string">;
- def err_attribute_argument_out_of_bounds : Error<
- "'%0' attribute parameter %1 is out of bounds">;
- def err_attribute_requires_objc_interface : Error<
- "attribute may only be applied to an Objective-C interface">;
- def err_nonnull_pointers_only : Error<
- "nonnull attribute only applies to pointer arguments">;
- def err_format_strftime_third_parameter : Error<
- "strftime format attribute requires 3rd parameter to be 0">;
- def err_format_attribute_requires_variadic : Error<
- "format attribute requires variadic function">;
- def err_format_attribute_not : Error<"format argument not %0">;
- def err_format_attribute_result_not : Error<"function does not return %0">;
- def err_attribute_invalid_size : Error<
- "vector size not an integral multiple of component size">;
- def err_attribute_zero_size : Error<"zero vector size">;
- def err_typecheck_vector_not_convertable : Error<
- "can't convert between vector values of different size (%0 and %1)">;
- def err_typecheck_ext_vector_not_typedef : Error<
- "ext_vector_type only applies to types, not variables">;
- def err_unsupported_vector_size : Error<
- "unsupported type %0 for vector_size attribute, please use on typedef">;
- def err_ext_vector_component_exceeds_length : Error<
- "vector component access exceeds type %0">;
- def err_ext_vector_component_name_illegal : Error<
- "illegal vector component name '%0'">;
- def err_attribute_address_space_not_int : Error<
- "address space attribute requires an integer constant">;
- def err_attribute_address_space_negative : Error<
- "address space is negative">;
- def err_attribute_address_space_too_high : Error<
- "address space is larger than the maximum supported (%0)">;
- def err_attribute_address_multiple_qualifiers : Error<
- "multiple address spaces specified for type">;
- def err_implicit_pointer_address_space_cast : Error<
- "illegal implicit cast between two pointers with different address spaces">;
- def err_as_qualified_auto_decl : Error<
- "automatic variable qualified with an address space">;
- def err_arg_with_address_space : Error<
- "parameter may not be qualified with an address space">;
- def err_attribute_not_string : Error<
- "argument to %0 attribute was not a string literal">;
- def err_attribute_section_invalid_for_target : Error<
- "argument to 'section' attribute is not valid for this target: %0">;
- def err_attribute_section_local_variable : Error<
- "'section' attribute is not valid on local variables">;
- def err_attribute_aligned_not_power_of_two : Error<
- "requested alignment is not a power of 2">;
- def warn_redeclaration_without_attribute_prev_attribute_ignored : Warning<
- "'%0' redeclared without %1 attribute: previous %1 ignored">;
- def warn_attribute_ignored : Warning<"%0 attribute ignored">;
- def warn_attribute_precede_definition : Warning<
- "attribute declaration must precede definition">;
- def warn_attribute_void_function_method : Warning<
- "attribute %0 cannot be applied to "
- "%select{functions|Objective-C method}1 without return value">;
- def warn_attribute_weak_on_field : Warning<
- "__weak attribute cannot be specified on a field declaration">;
- def warn_attribute_weak_on_local : Warning<
- "__weak attribute cannot be specified on an automatic variable">;
- def warn_weak_identifier_undeclared : Warning<
- "weak identifier %0 never declared">;
- def err_attribute_weak_static : Error<
- "weak declaration of '%0' must be public">;
- def warn_attribute_weak_import_invalid_on_definition : Warning<
- "'weak_import' attribute cannot be specified on a definition">;
- def err_attribute_weakref_not_static : Error<
- "weakref declaration of '%0' must be static">;
- def err_attribute_weakref_not_global_context : Error<
- "weakref declaration of '%0' must be in a global context">;
- def err_attribute_weakref_without_alias : Error<
- "weakref declaration of '%0' must also have an alias attribute">;
- def warn_attribute_wrong_decl_type : Warning<
- "%0 attribute only applies to %select{function|union|"
- "variable and function|function or method|parameter|"
- "parameter or Objective-C method |function, method or block|"
- "virtual method or class|function, method, or parameter|class|virtual method"
- "|member}1 types">;
- def err_attribute_wrong_decl_type : Error<
- "%0 attribute only applies to %select{function|union|"
- "variable and function|function or method|parameter|"
- "parameter or Objective-C method |function, method or block|"
- "virtual method or class|function, method, or parameter|class|virtual method"
- "|member}1 types">;
- def warn_function_attribute_wrong_type : Warning<
- "%0 only applies to function types; type here is %1">;
- def warn_gnu_inline_attribute_requires_inline : Warning<
- "'gnu_inline' attribute requires function to be marked 'inline',"
- " attribute ignored">;
- def err_cconv_change : Error<
- "function declared '%0' here was previously declared "
- "%select{'%2'|without calling convention}1">;
- def err_cconv_knr : Error<
- "function with no prototype cannot use %0 calling convention">;
- def err_cconv_varargs : Error<
- "variadic function cannot use %0 calling convention">;
- def err_regparm_mismatch : Error<"function declared with with regparm(%0) "
- "attribute was previously declared %plural{0:without the regparm|1:"
- "with the regparm(1)|2:with the regparm(2)|3:with the regparm(3)|:with the"
- "regparm}1 attribute">;
- def warn_impcast_vector_scalar : Warning<
- "implicit cast turns vector to scalar: %0 to %1">,
- InGroup<DiagGroup<"conversion">>, DefaultIgnore;
- def warn_impcast_complex_scalar : Warning<
- "implicit cast discards imaginary component: %0 to %1">,
- InGroup<DiagGroup<"conversion">>, DefaultIgnore;
- def warn_impcast_float_precision : Warning<
- "implicit cast loses floating-point precision: %0 to %1">,
- InGroup<DiagGroup<"conversion">>, DefaultIgnore;
- def warn_impcast_float_integer : Warning<
- "implicit cast turns floating-point number into integer: %0 to %1">,
- InGroup<DiagGroup<"conversion">>, DefaultIgnore;
- def warn_impcast_integer_sign : Warning<
- "implicit cast changes signedness: %0 to %1">,
- InGroup<DiagGroup<"conversion">>, DefaultIgnore;
- def warn_impcast_integer_sign_conditional : Warning<
- "operand of ? changes signedness: %0 to %1">,
- InGroup<DiagGroup<"conversion">>, DefaultIgnore;
- def warn_impcast_integer_precision : Warning<
- "implicit cast loses integer precision: %0 to %1">,
- InGroup<DiagGroup<"conversion">>, DefaultIgnore;
- def warn_impcast_integer_64_32 : Warning<
- "implicit cast loses integer precision: %0 to %1">,
- InGroup<DiagGroup<"shorten-64-to-32">>, DefaultIgnore;
- def warn_attribute_ignored_for_field_of_type : Warning<
- "%0 attribute ignored for field of type %1">;
- def warn_transparent_union_attribute_field_size_align : Warning<
- "%select{alignment|size}0 of field %1 (%2 bits) does not match the "
- "%select{alignment|size}0 of the first field in transparent union; "
- "transparent_union attribute ignored">;
- def note_transparent_union_first_field_size_align : Note<
- "%select{alignment|size}0 of first field is %1 bits">;
- def warn_transparent_union_attribute_not_definition : Warning<
- "transparent_union attribute can only be applied to a union definition; "
- "attribute ignored">;
- def warn_transparent_union_attribute_floating : Warning<
- "first field of a transparent union cannot have floating point or vector "
- "type; transparent_union attribute ignored">;
- def warn_transparent_union_attribute_zero_fields : Warning<
- "transparent union definition must contain at least one field; "
- "transparent_union attribute ignored">;
- def warn_attribute_type_not_supported : Warning<
- "'%0' attribute argument not supported: %1">;
- def warn_attribute_unknown_visibility : Warning<"unknown visibility '%1'">;
- def err_unknown_machine_mode : Error<"unknown machine mode %0">;
- def err_unsupported_machine_mode : Error<"unsupported machine mode %0">;
- def err_mode_not_primitive : Error<
- "mode attribute only supported for integer and floating-point types">;
- def err_mode_wrong_type : Error<
- "type of machine mode does not match type of base type">;
- def err_attr_wrong_decl : Error<
- "'%0' attribute invalid on this declaration, requires typedef or value">;
- def warn_attribute_nonnull_no_pointers : Warning<
- "'nonnull' attribute applied to function with no pointer arguments">;
- def warn_attribute_malloc_pointer_only : Warning<
- "'malloc' attribute only applies to functions returning a pointer type">;
- def warn_transparent_union_nonpointer : Warning<
- "'transparent_union' attribute support incomplete; only supported for "
- "pointer unions">;
- def warn_attribute_sentinel_named_arguments : Warning<
- "'sentinel' attribute requires named arguments">;
- def warn_attribute_sentinel_not_variadic : Warning<
- "'sentinel' attribute only supported for variadic %select{functions|blocks}0">;
- def err_attribute_sentinel_less_than_zero : Error<
- "'sentinel' parameter 1 less than zero">;
- def err_attribute_sentinel_not_zero_or_one : Error<
- "'sentinel' parameter 2 not 0 or 1">;
- def err_attribute_cleanup_arg_not_found : Error<
- "'cleanup' argument %0 not found">;
- def err_attribute_cleanup_arg_not_function : Error<
- "'cleanup' argument %0 is not a function">;
- def err_attribute_cleanup_func_must_take_one_arg : Error<
- "'cleanup' function %0 must take 1 parameter">;
- def err_attribute_cleanup_func_arg_incompatible_type : Error<
- "'cleanup' function %0 parameter has type %1 which is incompatible with "
- "type %2">;
- def err_attribute_regparm_wrong_platform : Error<
- "'regparm' is not valid on this platform">;
- def err_attribute_regparm_invalid_number : Error<
- "'regparm' parameter must be between 0 and %0 inclusive">;
- // Clang-Specific Attributes
- def err_attribute_iboutlet : Error<
- "%0 attribute can only be applied to instance variables or properties">;
- def err_attribute_ibaction: Error<
- "ibaction attribute can only be applied to…
Large files files are truncated, but you can click here to view the full file