Skip to content

Commit cccdd2c

Browse files
matthiasrichtersawenzel
authored andcommitted
Fix #428: adding missing include for std::array
std::array is used in test_DataDeflater.cxx, but the include was missing, some compilers seem to be more strict on that and fail. Also suppressing a warning by using the static_assert with two arguments (condition and error string)
1 parent 234dc3c commit cccdd2c

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

Utilities/DataCompression/include/DataCompression/DataDeflater.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ template<typename CodeType, std::size_t Length = 8 * sizeof(CodeType)>
4444
class CodecIdentity {
4545
public:
4646
using code_type = CodeType;
47-
static_assert(Length <= 8 * sizeof(code_type));
47+
static_assert(Length <= 8 * sizeof(code_type), "CodeType must allow specified bit length");
4848
static const std::size_t sMaxLength = Length;
4949

5050
CodecIdentity() = default;

Utilities/DataCompression/test/test_DataDeflater.cxx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
#include <iostream>
3333
#include <iomanip>
3434
#include <vector>
35+
#include <array>
3536
#include <bitset>
3637
#include <thread>
3738
#include <stdexcept> // exeptions, runtime_error

0 commit comments

Comments
 (0)