From: Eric Christopher Date: Fri, 12 Jun 2015 20:13:50 +0000 (+0000) Subject: Quote the user provided string in the warning message and update X-Git-Tag: llvmorg-3.7.0-rc1~2462 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0ee1c8cd0bb01406fd505c7723d4be040b3cf932;p=platform%2Fupstream%2Fllvm.git Quote the user provided string in the warning message and update tests accordingly. llvm-svn: 239635 --- diff --git a/clang/include/clang/Basic/DiagnosticSemaKinds.td b/clang/include/clang/Basic/DiagnosticSemaKinds.td index 0852010..8927a74 100644 --- a/clang/include/clang/Basic/DiagnosticSemaKinds.td +++ b/clang/include/clang/Basic/DiagnosticSemaKinds.td @@ -1975,7 +1975,7 @@ def err_attribute_invalid_vector_type : Error<"invalid vector element type %0">; def err_attribute_bad_neon_vector_size : Error< "Neon vector size must be 64 or 128 bits">; def warn_unsupported_target_attribute - : Warning<"Ignoring unsupported %0 in the target attribute string">, + : Warning<"Ignoring unsupported '%0' in the target attribute string">, InGroup; def err_attribute_unsupported : Error<"%0 attribute is not supported for this target">; diff --git a/clang/test/Sema/attr-target.c b/clang/test/Sema/attr-target.c index f8b0665..6c6b461 100644 --- a/clang/test/Sema/attr-target.c +++ b/clang/test/Sema/attr-target.c @@ -2,7 +2,7 @@ int __attribute__((target("avx,sse4.2,arch=ivybridge"))) foo() { return 4; } int __attribute__((target())) bar() { return 4; } //expected-error {{'target' attribute takes one argument}} -int __attribute__((target("tune=sandybridge"))) baz() { return 4; } //expected-warning {{Ignoring unsupported tune= in the target attribute string}} -int __attribute__((target("fpmath=387"))) walrus() { return 4; } //expected-warning {{Ignoring unsupported fpmath= in the target attribute string}} +int __attribute__((target("tune=sandybridge"))) baz() { return 4; } //expected-warning {{Ignoring unsupported 'tune=' in the target attribute string}} +int __attribute__((target("fpmath=387"))) walrus() { return 4; } //expected-warning {{Ignoring unsupported 'fpmath=' in the target attribute string}}