xref: /minix3/external/bsd/llvm/dist/clang/include/clang/Basic/DiagnosticCommentKinds.td (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1f4a2713aSLionel Sambuc//==--- DiagnosticCommentKinds.td - diagnostics related to comments -------===//
2f4a2713aSLionel Sambuc//
3f4a2713aSLionel Sambuc//                     The LLVM Compiler Infrastructure
4f4a2713aSLionel Sambuc//
5f4a2713aSLionel Sambuc// This file is distributed under the University of Illinois Open Source
6f4a2713aSLionel Sambuc// License. See LICENSE.TXT for details.
7f4a2713aSLionel Sambuc//
8f4a2713aSLionel Sambuc//===----------------------------------------------------------------------===//
9f4a2713aSLionel Sambuc
10f4a2713aSLionel Sambuclet Component = "Comment" in {
11f4a2713aSLionel Sambuclet CategoryName = "Documentation Issue" in {
12f4a2713aSLionel Sambuc
13f4a2713aSLionel Sambuc// HTML parsing errors.  These are under -Wdocumentation to make sure the user
14*0a6a1f1dSLionel Sambuc// knows that we didn't parse something as they might expect.
15f4a2713aSLionel Sambuc
16f4a2713aSLionel Sambucdef warn_doc_html_start_tag_expected_quoted_string : Warning<
17f4a2713aSLionel Sambuc  "expected quoted string after equals sign">,
18f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
19f4a2713aSLionel Sambuc
20f4a2713aSLionel Sambucdef warn_doc_html_start_tag_expected_ident_or_greater : Warning<
21f4a2713aSLionel Sambuc  "HTML start tag prematurely ended, expected attribute name or '>'">,
22f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
23f4a2713aSLionel Sambuc
24f4a2713aSLionel Sambucdef note_doc_html_tag_started_here : Note<
25f4a2713aSLionel Sambuc  "HTML tag started here">;
26f4a2713aSLionel Sambuc
27f4a2713aSLionel Sambuc// HTML semantic errors
28f4a2713aSLionel Sambuc
29f4a2713aSLionel Sambucdef warn_doc_html_end_forbidden : Warning<
30f4a2713aSLionel Sambuc  "HTML end tag '%0' is forbidden">,
31f4a2713aSLionel Sambuc  InGroup<DocumentationHTML>, DefaultIgnore;
32f4a2713aSLionel Sambuc
33f4a2713aSLionel Sambucdef warn_doc_html_end_unbalanced : Warning<
34f4a2713aSLionel Sambuc  "HTML end tag does not match any start tag">,
35f4a2713aSLionel Sambuc  InGroup<DocumentationHTML>, DefaultIgnore;
36f4a2713aSLionel Sambuc
37f4a2713aSLionel Sambucdef warn_doc_html_start_end_mismatch : Warning<
38f4a2713aSLionel Sambuc  "HTML start tag '%0' closed by '%1'">,
39f4a2713aSLionel Sambuc  InGroup<DocumentationHTML>, DefaultIgnore;
40f4a2713aSLionel Sambuc
41f4a2713aSLionel Sambucdef note_doc_html_end_tag : Note<
42f4a2713aSLionel Sambuc  "end tag">;
43f4a2713aSLionel Sambuc
44*0a6a1f1dSLionel Sambucdef warn_doc_html_missing_end_tag : Warning<
45*0a6a1f1dSLionel Sambuc  "HTML tag '%0' requires an end tag">,
46*0a6a1f1dSLionel Sambuc  InGroup<DocumentationHTML>, DefaultIgnore;
47*0a6a1f1dSLionel Sambuc
48f4a2713aSLionel Sambuc// Commands
49f4a2713aSLionel Sambuc
50f4a2713aSLionel Sambucdef warn_doc_block_command_empty_paragraph : Warning<
51f4a2713aSLionel Sambuc  "empty paragraph passed to '%select{\\|@}0%1' command">,
52f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
53f4a2713aSLionel Sambuc
54f4a2713aSLionel Sambucdef warn_doc_block_command_duplicate : Warning<
55f4a2713aSLionel Sambuc  "duplicated command '%select{\\|@}0%1'">,
56f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
57f4a2713aSLionel Sambuc
58f4a2713aSLionel Sambucdef note_doc_block_command_previous : Note<
59f4a2713aSLionel Sambuc  "previous command '%select{\\|@}0%1' here">;
60f4a2713aSLionel Sambuc
61f4a2713aSLionel Sambucdef note_doc_block_command_previous_alias : Note<
62f4a2713aSLionel Sambuc  "previous command '%select{\\|@}0%1' (an alias of '\\%2') here">;
63f4a2713aSLionel Sambuc
64f4a2713aSLionel Sambuc// \param command
65f4a2713aSLionel Sambuc
66f4a2713aSLionel Sambucdef warn_doc_param_invalid_direction : Warning<
67f4a2713aSLionel Sambuc  "unrecognized parameter passing direction, "
68f4a2713aSLionel Sambuc  "valid directions are '[in]', '[out]' and '[in,out]'">,
69f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
70f4a2713aSLionel Sambuc
71f4a2713aSLionel Sambucdef warn_doc_param_spaces_in_direction : Warning<
72f4a2713aSLionel Sambuc  "whitespace is not allowed in parameter passing direction">,
73f4a2713aSLionel Sambuc  InGroup<DocumentationPedantic>, DefaultIgnore;
74f4a2713aSLionel Sambuc
75f4a2713aSLionel Sambucdef warn_doc_param_not_attached_to_a_function_decl : Warning<
76f4a2713aSLionel Sambuc  "'%select{\\|@}0param' command used in a comment that is not attached to "
77f4a2713aSLionel Sambuc  "a function declaration">,
78f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
79f4a2713aSLionel Sambuc
80f4a2713aSLionel Sambucdef warn_doc_function_method_decl_mismatch : Warning<
81f4a2713aSLionel Sambuc  "'%select{\\|@}0%select{function|functiongroup|method|methodgroup|callback}1' "
82f4a2713aSLionel Sambuc  "command should be used in a comment attached to "
83f4a2713aSLionel Sambuc  "%select{a function|a function|an Objective-C method|an Objective-C method|"
84f4a2713aSLionel Sambuc  "a pointer to function}2 declaration">,
85f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
86f4a2713aSLionel Sambuc
87f4a2713aSLionel Sambucdef warn_doc_api_container_decl_mismatch : Warning<
88f4a2713aSLionel Sambuc  "'%select{\\|@}0%select{class|interface|protocol|struct|union}1' "
89f4a2713aSLionel Sambuc  "command should not be used in a comment attached to a "
90f4a2713aSLionel Sambuc  "non-%select{class|interface|protocol|struct|union}2 declaration">,
91f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
92f4a2713aSLionel Sambuc
93f4a2713aSLionel Sambucdef warn_doc_container_decl_mismatch : Warning<
94f4a2713aSLionel Sambuc  "'%select{\\|@}0%select{classdesign|coclass|dependency|helper"
95f4a2713aSLionel Sambuc  "|helperclass|helps|instancesize|ownership|performance|security|superclass}1' "
96f4a2713aSLionel Sambuc  "command should not be used in a comment attached to a non-container declaration">,
97f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
98f4a2713aSLionel Sambuc
99f4a2713aSLionel Sambucdef warn_doc_param_duplicate : Warning<
100f4a2713aSLionel Sambuc  "parameter '%0' is already documented">,
101f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
102f4a2713aSLionel Sambuc
103f4a2713aSLionel Sambucdef note_doc_param_previous : Note<
104f4a2713aSLionel Sambuc  "previous documentation">;
105f4a2713aSLionel Sambuc
106f4a2713aSLionel Sambucdef warn_doc_param_not_found : Warning<
107f4a2713aSLionel Sambuc  "parameter '%0' not found in the function declaration">,
108f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
109f4a2713aSLionel Sambuc
110f4a2713aSLionel Sambucdef note_doc_param_name_suggestion : Note<
111f4a2713aSLionel Sambuc  "did you mean '%0'?">;
112f4a2713aSLionel Sambuc
113f4a2713aSLionel Sambuc// tparam command
114f4a2713aSLionel Sambuc
115f4a2713aSLionel Sambucdef warn_doc_tparam_not_attached_to_a_template_decl : Warning<
116f4a2713aSLionel Sambuc  "'%select{\\|@}0tparam' command used in a comment that is not attached to "
117f4a2713aSLionel Sambuc  "a template declaration">,
118f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
119f4a2713aSLionel Sambuc
120f4a2713aSLionel Sambucdef warn_doc_tparam_duplicate : Warning<
121f4a2713aSLionel Sambuc  "template parameter '%0' is already documented">,
122f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
123f4a2713aSLionel Sambuc
124f4a2713aSLionel Sambucdef note_doc_tparam_previous : Note<
125f4a2713aSLionel Sambuc  "previous documentation">;
126f4a2713aSLionel Sambuc
127f4a2713aSLionel Sambucdef warn_doc_tparam_not_found : Warning<
128f4a2713aSLionel Sambuc  "template parameter '%0' not found in the template declaration">,
129f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
130f4a2713aSLionel Sambuc
131f4a2713aSLionel Sambucdef note_doc_tparam_name_suggestion : Note<
132f4a2713aSLionel Sambuc  "did you mean '%0'?">;
133f4a2713aSLionel Sambuc
134f4a2713aSLionel Sambuc// \returns command
135f4a2713aSLionel Sambuc
136f4a2713aSLionel Sambucdef warn_doc_returns_not_attached_to_a_function_decl : Warning<
137f4a2713aSLionel Sambuc  "'%select{\\|@}0%1' command used in a comment that is not attached to "
138f4a2713aSLionel Sambuc  "a function or method declaration">,
139f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
140f4a2713aSLionel Sambuc
141f4a2713aSLionel Sambucdef warn_doc_returns_attached_to_a_void_function : Warning<
142f4a2713aSLionel Sambuc  "'%select{\\|@}0%1' command used in a comment that is attached to a "
143f4a2713aSLionel Sambuc  "%select{function returning void|constructor|destructor|"
144f4a2713aSLionel Sambuc  "method returning void}2">,
145f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
146f4a2713aSLionel Sambuc
147f4a2713aSLionel Sambuc// \deprecated command
148f4a2713aSLionel Sambuc
149f4a2713aSLionel Sambucdef warn_doc_deprecated_not_sync : Warning<
150f4a2713aSLionel Sambuc  "declaration is marked with '\\deprecated' command but does not have "
151f4a2713aSLionel Sambuc  "a deprecation attribute">,
152f4a2713aSLionel Sambuc  InGroup<DocumentationDeprecatedSync>, DefaultIgnore;
153f4a2713aSLionel Sambuc
154f4a2713aSLionel Sambucdef note_add_deprecation_attr : Note<
155f4a2713aSLionel Sambuc  "add a deprecation attribute to the declaration to silence this warning">;
156f4a2713aSLionel Sambuc
157f4a2713aSLionel Sambuc// verbatim block commands
158f4a2713aSLionel Sambuc
159f4a2713aSLionel Sambucdef warn_verbatim_block_end_without_start : Warning<
160f4a2713aSLionel Sambuc  "'%select{\\|@}0%1' command does not terminate a verbatim text block">,
161f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
162f4a2713aSLionel Sambuc
163f4a2713aSLionel Sambucdef warn_unknown_comment_command_name : Warning<
164f4a2713aSLionel Sambuc  "unknown command tag name">,
165f4a2713aSLionel Sambuc  InGroup<DocumentationUnknownCommand>, DefaultIgnore;
166f4a2713aSLionel Sambuc
167f4a2713aSLionel Sambucdef warn_correct_comment_command_name : Warning<
168f4a2713aSLionel Sambuc  "unknown command tag name '%0'; did you mean '%1'?">,
169f4a2713aSLionel Sambuc  InGroup<Documentation>, DefaultIgnore;
170f4a2713aSLionel Sambuc
171f4a2713aSLionel Sambuc} // end of documentation issue category
172f4a2713aSLionel Sambuc} // end of AST component
173