File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22
33#include " telnetpp/core.hpp"
44
5- #include < boost/exception/all .hpp>
5+ #include < boost/exception/exception .hpp>
66
7+ #include < functional>
78#include < stdexcept>
89
910namespace telnetpp ::options::mccp {
@@ -49,12 +50,12 @@ class TELNETPP_EXPORT codec
4950 // * =====================================================================
5051 // / \brief A hook for when the transformation stream starts.
5152 // * =====================================================================
52- virtual void do_start (){};
53+ virtual void do_start () {};
5354
5455 // * =====================================================================
5556 // / \brief A hook for when transformation stream ends.
5657 // * =====================================================================
57- virtual void do_finish (continuation const & /* cont*/ ){};
58+ virtual void do_finish (continuation const & /* cont*/ ) {};
5859
5960 // * =====================================================================
6061 // / \brief Transform the given bytes, sending the transformed data
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ class TELNETPP_EXPORT client : public telnetpp::client_option
2020 explicit client (telnetpp::session &sess) noexcept ;
2121
2222 boost::signals2::signal<void (window_dimension, window_dimension)>
23- on_window_size_changed;
23+ on_window_size_changed; // NOLINT
2424
2525private:
2626 // * =====================================================================
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ class TELNETPP_EXPORT client : public telnetpp::client_option
2323 // * =====================================================================
2424 void request_terminal_type ();
2525
26- boost::signals2::signal<void (telnetpp::bytes)> on_terminal_type;
26+ boost::signals2::signal<void (telnetpp::bytes)> on_terminal_type; // NOLINT
2727
2828private:
2929 // * =====================================================================
Original file line number Diff line number Diff line change 11#include " telnetpp/options/mccp/zlib/compressor.hpp"
22
3- #include < boost/core/ignore_unused.hpp>
43#include < zlib.h>
54
65#include < optional>
@@ -36,8 +35,8 @@ struct compressor::impl
3635
3736 stream_ = z_stream{};
3837
39- auto result = deflateInit (&*stream_, Z_DEFAULT_COMPRESSION);
40- boost::ignore_unused (result );
38+ [[maybe_unused]] auto result =
39+ deflateInit (&*stream_, Z_DEFAULT_COMPRESSION );
4140 assert (result == Z_OK);
4241 }
4342
@@ -48,8 +47,7 @@ struct compressor::impl
4847 {
4948 assert (stream_ != std::nullopt );
5049
51- auto result = deflateEnd (&*stream_);
52- boost::ignore_unused (result);
50+ [[maybe_unused]] auto result = deflateEnd (&*stream_);
5351 assert (result == Z_OK || result == Z_STREAM_ERROR || Z_DATA_ERROR);
5452
5553 stream_ = std::nullopt ;
@@ -134,8 +132,7 @@ telnetpp::bytes compressor::transform_chunk(
134132 pimpl_->stream_ ->avail_out = output_buffer_size;
135133 pimpl_->stream_ ->next_out = output_buffer;
136134
137- auto response = deflate (&*pimpl_->stream_ , Z_SYNC_FLUSH);
138- boost::ignore_unused (response);
135+ [[maybe_unused]] auto response = deflate (&*pimpl_->stream_ , Z_SYNC_FLUSH);
139136 assert (response == Z_OK);
140137
141138 auto const output_data =
Original file line number Diff line number Diff line change 11#include " telnetpp/options/mccp/zlib/decompressor.hpp"
22
3- #include < boost/core/ignore_unused.hpp>
43#include < zlib.h>
54
65#include < optional>
@@ -36,8 +35,7 @@ struct decompressor::impl
3635
3736 stream_ = z_stream{};
3837
39- auto result = inflateInit (&*stream_);
40- boost::ignore_unused (result);
38+ [[maybe_unused]] auto result = inflateInit (&*stream_);
4139 assert (result == Z_OK);
4240 }
4341
@@ -48,8 +46,7 @@ struct decompressor::impl
4846 {
4947 assert (stream_ != std::nullopt );
5048
51- auto result = inflateEnd (&*stream_);
52- boost::ignore_unused (result);
49+ [[maybe_unused]] auto result = inflateEnd (&*stream_);
5350 assert (result == Z_OK || result == Z_STREAM_ERROR);
5451
5552 stream_ = std::nullopt ;
You can’t perform that action at this time.
0 commit comments