[PATCH] D64469: Fixing modular build issues caused by BitCodes.h
Kristina Brooks via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 9 20:36:56 PDT 2019
kristina created this revision.
kristina added reviewers: lhames, thegameg, aprantl.
Herald added a project: LLVM.
Consolidate `llvm::BWH_*` statics into an enum to fix module build issues. This fixes modular builds (`-Wmodules-ambiguous-internal-linkage`).
Repository:
rL LLVM
https://reviews.llvm.org/D64469
Files:
include/llvm/Bitstream/BitCodes.h
Index: include/llvm/Bitstream/BitCodes.h
===================================================================
--- include/llvm/Bitstream/BitCodes.h
+++ include/llvm/Bitstream/BitCodes.h
@@ -24,12 +24,14 @@
namespace llvm {
/// Offsets of the 32-bit fields of bitstream wrapper header.
-static const unsigned BWH_MagicField = 0 * 4;
-static const unsigned BWH_VersionField = 1 * 4;
-static const unsigned BWH_OffsetField = 2 * 4;
-static const unsigned BWH_SizeField = 3 * 4;
-static const unsigned BWH_CPUTypeField = 4 * 4;
-static const unsigned BWH_HeaderSize = 5 * 4;
+enum BitstreamWrapperHeader : unsigned {
+ BWH_MagicField = 0 * 4,
+ BWH_VersionField = 1 * 4,
+ BWH_OffsetField = 2 * 4,
+ BWH_SizeField = 3 * 4,
+ BWH_CPUTypeField = 4 * 4,
+ BWH_HeaderSize = 5 * 4
+};
namespace bitc {
enum StandardWidths {
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D64469.208874.patch
Type: text/x-patch
Size: 838 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190710/010a4ac8/attachment.bin>
More information about the llvm-commits
mailing list