summaryrefslogtreecommitdiffstats
path: root/clang/include
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2008-10-14 05:35:18 +0000
committerDaniel Dunbar <daniel@zuster.org>2008-10-14 05:35:18 +0000
commit5460374cd986a6ec52aeed1d61e25f00eb8bca66 (patch)
tree91c253b45f078c22c1e0454778ce99b054e8495e /clang/include
parent3db01846db11381a274aa93a221633d8bd0cdc83 (diff)
downloadbcm5719-llvm-5460374cd986a6ec52aeed1d61e25f00eb8bca66.tar.gz
bcm5719-llvm-5460374cd986a6ec52aeed1d61e25f00eb8bca66.zip
Add Sema implementation of #pragma pack stack.
- Follows the MSVC (original) implementation, including support of pack(show) (useful for testing). - Implements support for named pack records which gcc seems to ignore (or implements incorrectly). - Not currently wired to anything, only functionality change is the type checking of the pragma. llvm-svn: 57476
Diffstat (limited to 'clang/include')
-rw-r--r--clang/include/clang/Basic/DiagnosticKinds.def10
1 files changed, 10 insertions, 0 deletions
diff --git a/clang/include/clang/Basic/DiagnosticKinds.def b/clang/include/clang/Basic/DiagnosticKinds.def
index 691f83e1b97..9cae8efaf28 100644
--- a/clang/include/clang/Basic/DiagnosticKinds.def
+++ b/clang/include/clang/Basic/DiagnosticKinds.def
@@ -571,6 +571,16 @@ DIAG(warn_pragma_pack_invalid_constant, WARNING,
"invalid constant for '#pragma pack', expected %0 - ignored")
DIAG(warn_pragma_pack_malformed, WARNING,
"malformed '#pragma pack', expected '#pragma pack(%0 [, id] [, n])' - ignored")
+// Follow the MSVC implementation.
+DIAG(warn_pragma_pack_show, WARNING,
+ "value of #pragma pack(show) == %0")
+// FIXME: Dehardcode.
+DIAG(warn_pragma_pack_invalid_alignment, WARNING,
+ "expected #pragma pack parameter to be '1', '2', '4', '8', or '16'")
+DIAG(warn_pragma_pack_pop_identifer_and_alignment, WARNING,
+ "specifying both a name and alignment to pragma pack(pop, ...) is undefined")
+DIAG(warn_pragma_pack_pop_failed, WARNING,
+ "#pragma pack(pop, ...) failed: %0")
//===----------------------------------------------------------------------===//
// Semantic Analysis
OpenPOWER on IntegriCloud