Skip to content

Commit c38139f

Browse files
author
urvi-rav
committed
Removed warning
1 parent de4fb9a commit c38139f

File tree

3 files changed

+2
-5
lines changed

3 files changed

+2
-5
lines changed

clang/include/clang/Basic/DiagnosticParseKinds.td

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1497,9 +1497,6 @@ def err_omp_multiple_step_or_linear_modifier : Error<
14971497
"multiple %select{'step size'|'linear modifier'}0 found in linear clause">;
14981498
def err_omp_deprecate_old_syntax: Error<
14991499
"old syntax '%0' on '%1' clause was deprecated, use new syntax '%2'">;
1500-
def warn_omp_deprecate_old_syntax: Warning<
1501-
"old syntax '%0' on '%1' clause was deprecated, use new syntax '%2'">,
1502-
InGroup<Deprecated>;
15031500
def err_omp_allocator_comma_separator :
15041501
Error<"',' not allowed as separator in 'uses_allocators' clause, use ';' instead">;
15051502
def warn_omp_future_directive_spelling: Warning<

clang/lib/Parse/ParseOpenMP.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3058,7 +3058,7 @@ OMPClause *Parser::ParseOpenMPUsesAllocatorClause(OpenMPDirectiveKind DKind) {
30583058

30593059
// Deprecation diagnostic in >= 5.2
30603060
if (getLangOpts().OpenMP >= 52) {
3061-
Diag(Loc, diag::warn_omp_deprecate_old_syntax)
3061+
Diag(Loc, diag::err_omp_deprecate_old_syntax)
30623062
<< "allocator(expr)" // %0: old form
30633063
<< "uses_allocators" // %1: clause name
30643064
<< "traits(expr): alloc"; // %2: suggested new form

clang/test/OpenMP/target_uses_allocators_messages.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ int main(int argc, char **argv) {
6666
{}
6767
#pragma omp target teams uses_allocators(traits(my_traits): my_alloc, traits(aligned_traits): aligned_alloc) // omp52-error {{',' not allowed as separator in 'uses_allocators' clause, use ';' instead}}
6868
{}
69-
#pragma omp target teams uses_allocators(my_alloc(my_traits), aligned_alloc(aligned_traits)) // omp52-warning {{old syntax 'allocator(expr)' on 'uses_allocators' clause was deprecated, use new syntax 'traits(expr): alloc'}} //omp52-warning {{old syntax 'allocator(expr)' on 'uses_allocators' clause was deprecated, use new syntax 'traits(expr): alloc'}}
69+
#pragma omp target teams uses_allocators(my_alloc(my_traits), aligned_alloc(aligned_traits)) // omp52-error {{old syntax 'allocator(expr)' on 'uses_allocators' clause was deprecated, use new syntax 'traits(expr): alloc'}} //omp52-error {{old syntax 'allocator(expr)' on 'uses_allocators' clause was deprecated, use new syntax 'traits(expr): alloc'}}
7070
{}
7171
#endif
7272
return 0;

0 commit comments

Comments
 (0)