summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/common/bit_field.h11
1 files changed, 0 insertions, 11 deletions
diff --git a/src/common/bit_field.h b/src/common/bit_field.h
index d306ce9a9..66689f398 100644
--- a/src/common/bit_field.h
+++ b/src/common/bit_field.h
@@ -125,21 +125,10 @@ public:
125 // so that we can use this within unions 125 // so that we can use this within unions
126 BitField() = default; 126 BitField() = default;
127 127
128#ifndef _WIN32
129 // We explicitly delete the copy assigment operator here, because the 128 // We explicitly delete the copy assigment operator here, because the
130 // default copy assignment would copy the full storage value, rather than 129 // default copy assignment would copy the full storage value, rather than
131 // just the bits relevant to this particular bit field. 130 // just the bits relevant to this particular bit field.
132 // Ideally, we would just implement the copy assignment to copy only the
133 // relevant bits, but this requires compiler support for unrestricted
134 // unions.
135 // MSVC 2013 has no support for this, hence we disable this code on
136 // Windows (so that the default copy assignment operator will be used).
137 // For any C++11 conformant compiler we delete the operator to make sure
138 // we never use this inappropriate operator to begin with.
139 // TODO: Implement this operator properly once all target compilers
140 // support unrestricted unions.
141 BitField& operator=(const BitField&) = delete; 131 BitField& operator=(const BitField&) = delete;
142#endif
143 132
144 FORCE_INLINE BitField& operator=(T val) 133 FORCE_INLINE BitField& operator=(T val)
145 { 134 {