Skip to content

Commit a4cf344

Browse files
authored
Merge pull request #49 from jpetso/extra_warnings
More compiler warning maintenance, in addition to @thrimbor and @GTValentine patches.
2 parents 3e235c5 + bc972d6 commit a4cf344

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ if (MSVC)
2121
# fine for anything except ancient MSVC versions.
2222
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W4")
2323
else()
24-
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -pedantic")
24+
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic")
2525

2626
# CMake versions before 3.1 do not understand CMAKE_CXX_STANDARD.
2727
# Remove this block once CMake >=3.1 has fixated in the ecosystem.

cppcodec/base32_crockford.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ class base32_crockford_base
6363

6464
static CPPCODEC_ALWAYS_INLINE constexpr bool generates_padding() { return false; }
6565
static CPPCODEC_ALWAYS_INLINE constexpr bool requires_padding() { return false; }
66-
static CPPCODEC_ALWAYS_INLINE constexpr bool is_padding_symbol(char /*c*/) { return false; }
66+
static CPPCODEC_ALWAYS_INLINE constexpr bool is_padding_symbol(char) { return false; }
6767
static CPPCODEC_ALWAYS_INLINE constexpr bool is_eof_symbol(char c) { return c == '\0'; }
6868

6969
static CPPCODEC_ALWAYS_INLINE constexpr bool should_ignore(char c) {

cppcodec/data/access.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ class direct_data_access_result_state
161161
// Conditional code paths are slow so we only do it once, at the start.
162162
m_buffer = result.data();
163163
}
164-
CPPCODEC_ALWAYS_INLINE void put(Result& /*result*/, char c)
164+
CPPCODEC_ALWAYS_INLINE void put(Result&, char c)
165165
{
166166
m_buffer[m_offset++] = c;
167167
}

cppcodec/detail/stream_codec.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ struct index_if_in_alphabet {
203203
};
204204
template <typename CodecVariant, alphabet_index_t InvalidIdx>
205205
struct index_if_in_alphabet<CodecVariant, InvalidIdx, 0> { // terminating specialization
206-
static CPPCODEC_ALWAYS_INLINE constexpr alphabet_index_t for_symbol(char /*symbol*/)
206+
static CPPCODEC_ALWAYS_INLINE constexpr alphabet_index_t for_symbol(char)
207207
{
208208
return InvalidIdx;
209209
}

cppcodec/hex_lower.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ class hex_lower
5959
static CPPCODEC_ALWAYS_INLINE constexpr bool generates_padding() { return false; }
6060
// FIXME: doesn't require padding, but requires a multiple of the encoded block size (2)
6161
static CPPCODEC_ALWAYS_INLINE constexpr bool requires_padding() { return false; }
62-
static CPPCODEC_ALWAYS_INLINE constexpr bool is_padding_symbol(char /*c*/) { return false; }
62+
static CPPCODEC_ALWAYS_INLINE constexpr bool is_padding_symbol(char) { return false; }
6363
static CPPCODEC_ALWAYS_INLINE constexpr bool is_eof_symbol(char c) { return c == '\0'; }
6464

6565
// Sometimes hex strings include whitespace, but this variant forbids it.

cppcodec/hex_upper.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ class hex_upper
5959
static CPPCODEC_ALWAYS_INLINE constexpr bool generates_padding() { return false; }
6060
// FIXME: doesn't require padding, but requires a multiple of the encoded block size (2)
6161
static CPPCODEC_ALWAYS_INLINE constexpr bool requires_padding() { return false; }
62-
static CPPCODEC_ALWAYS_INLINE constexpr bool is_padding_symbol(char /*c*/) { return false; }
62+
static CPPCODEC_ALWAYS_INLINE constexpr bool is_padding_symbol(char) { return false; }
6363
static CPPCODEC_ALWAYS_INLINE constexpr bool is_eof_symbol(char c) { return c == '\0'; }
6464

6565
// Sometimes hex strings include whitespace, but this variant forbids it.

0 commit comments

Comments
 (0)