Skip to content

Commit

Permalink
Add some override qualifiers.
Browse files Browse the repository at this point in the history
  • Loading branch information
cuavas committed Apr 22, 2024
1 parent 2b9c30a commit 44c3506
Show file tree
Hide file tree
Showing 23 changed files with 66 additions and 66 deletions.
4 changes: 2 additions & 2 deletions 3rdparty/asio/include/asio/basic_streambuf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ class basic_streambuf
/**
* Behaves according to the specification of @c std::streambuf::underflow().
*/
int_type underflow()
int_type underflow() override
{
if (gptr() < pptr())
{
Expand All @@ -280,7 +280,7 @@ class basic_streambuf
* the character to the input sequence would require the condition
* <tt>size() > max_size()</tt> to be true.
*/
int_type overflow(int_type c)
int_type overflow(int_type c) override
{
if (!traits_type::eq_int_type(c, traits_type::eof()))
{
Expand Down
4 changes: 2 additions & 2 deletions 3rdparty/asio/include/asio/cancellation_signal.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,12 @@ class cancellation_handler
{
}

void call(cancellation_type_t type)
void call(cancellation_type_t type) override
{
handler_(type);
}

std::pair<void*, std::size_t> destroy() noexcept
std::pair<void*, std::size_t> destroy() noexcept override
{
std::pair<void*, std::size_t> mem(this, size_);
this->cancellation_handler::~cancellation_handler();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class deadline_timer_service
}

// Destroy all user-defined handler objects owned by the service.
void shutdown()
void shutdown() override
{
}

Expand Down
8 changes: 4 additions & 4 deletions 3rdparty/asio/include/asio/detail/epoll_reactor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -90,11 +90,11 @@ class epoll_reactor
ASIO_DECL ~epoll_reactor();

// Destroy all user-defined handler objects owned by the service.
ASIO_DECL void shutdown();
ASIO_DECL void shutdown() override;

// Recreate internal descriptors following a fork.
ASIO_DECL void notify_fork(
asio::execution_context::fork_event fork_ev);
asio::execution_context::fork_event fork_ev) override;

// Initialise the task.
ASIO_DECL void init_task();
Expand Down Expand Up @@ -206,10 +206,10 @@ class epoll_reactor
typename timer_queue<Time_Traits>::per_timer_data& source);

// Run epoll once until interrupted or events are ready to be dispatched.
ASIO_DECL void run(long usec, op_queue<operation>& ops);
ASIO_DECL void run(long usec, op_queue<operation>& ops) override;

// Interrupt the select loop.
ASIO_DECL void interrupt();
ASIO_DECL void interrupt() override;

private:
// The hint to pass to epoll_create to size its data structures.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class posix_serial_port_service :
ASIO_DECL posix_serial_port_service(execution_context& context);

// Destroy all user-defined handler objects owned by the service.
ASIO_DECL void shutdown();
ASIO_DECL void shutdown() override;

// Construct a new serial port implementation.
void construct(implementation_type& impl)
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/asio/include/asio/detail/posix_thread.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ class posix_thread
{
}

virtual void run()
virtual void run() override
{
f_();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class reactive_descriptor_service :
ASIO_DECL reactive_descriptor_service(execution_context& context);

// Destroy all user-defined handler objects owned by the service.
ASIO_DECL void shutdown();
ASIO_DECL void shutdown() override;

// Construct a new descriptor implementation.
ASIO_DECL void construct(implementation_type& impl);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class reactive_socket_service :
}

// Destroy all user-defined handler objects owned by the service.
void shutdown()
void shutdown() override
{
this->base_shutdown();
}
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/asio/include/asio/detail/scheduler.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class scheduler
ASIO_DECL ~scheduler();

// Destroy all user-defined handler objects owned by the service.
ASIO_DECL void shutdown();
ASIO_DECL void shutdown() override;

// Initialise the task, if required.
ASIO_DECL void init_task();
Expand Down
4 changes: 2 additions & 2 deletions 3rdparty/asio/include/asio/detail/signal_set_service.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,11 +128,11 @@ class signal_set_service :
ASIO_DECL ~signal_set_service();

// Destroy all user-defined handler objects owned by the service.
ASIO_DECL void shutdown();
ASIO_DECL void shutdown() override;

// Perform fork-related housekeeping.
ASIO_DECL void notify_fork(
asio::execution_context::fork_event fork_ev);
asio::execution_context::fork_event fork_ev) override;

// Construct a new signal_set implementation.
ASIO_DECL void construct(implementation_type& impl);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class strand_executor_service
ASIO_DECL explicit strand_executor_service(execution_context& context);

// Destroy all user-defined handler objects owned by the service.
ASIO_DECL void shutdown();
ASIO_DECL void shutdown() override;

// Create a new strand_executor implementation.
ASIO_DECL implementation_type create_implementation();
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/asio/include/asio/detail/strand_service.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class strand_service
ASIO_DECL explicit strand_service(asio::io_context& io_context);

// Destroy all user-defined handler objects owned by the service.
ASIO_DECL void shutdown();
ASIO_DECL void shutdown() override;

// Construct a new strand implementation.
ASIO_DECL void construct(implementation_type& impl);
Expand Down
10 changes: 5 additions & 5 deletions 3rdparty/asio/include/asio/detail/timer_queue.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,13 @@ class timer_queue
}

// Whether there are no timers in the queue.
virtual bool empty() const
virtual bool empty() const override
{
return timers_ == 0;
}

// Get the time for the timer that is earliest in the queue.
virtual long wait_duration_msec(long max_duration) const
virtual long wait_duration_msec(long max_duration) const override
{
if (heap_.empty())
return max_duration;
Expand All @@ -130,7 +130,7 @@ class timer_queue
}

// Get the time for the timer that is earliest in the queue.
virtual long wait_duration_usec(long max_duration) const
virtual long wait_duration_usec(long max_duration) const override
{
if (heap_.empty())
return max_duration;
Expand All @@ -142,7 +142,7 @@ class timer_queue
}

// Dequeue all timers not later than the current time.
virtual void get_ready_timers(op_queue<operation>& ops)
virtual void get_ready_timers(op_queue<operation>& ops) override
{
if (!heap_.empty())
{
Expand All @@ -162,7 +162,7 @@ class timer_queue
}

// Dequeue all timers.
virtual void get_all_timers(op_queue<operation>& ops)
virtual void get_all_timers(op_queue<operation>& ops) override
{
while (timers_)
{
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/asio/include/asio/execution/bad_executor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class bad_executor
ASIO_DECL bad_executor() noexcept;

/// Obtain message associated with exception.
ASIO_DECL virtual const char* what() const noexcept;
ASIO_DECL virtual const char* what() const noexcept override;
};

} // namespace execution
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/asio/include/asio/executor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class bad_executor

/// Obtain message associated with exception.
ASIO_DECL virtual const char* what() const
noexcept;
noexcept override;
};

/// Polymorphic wrapper for executors.
Expand Down
12 changes: 6 additions & 6 deletions 3rdparty/asio/include/asio/impl/error.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ namespace detail {
class netdb_category : public asio::error_category
{
public:
const char* name() const noexcept
const char* name() const noexcept override
{
return "asio.netdb";
}

std::string message(int value) const
std::string message(int value) const override
{
if (value == error::host_not_found)
return "Host not found (authoritative)";
Expand All @@ -63,12 +63,12 @@ namespace detail {
class addrinfo_category : public asio::error_category
{
public:
const char* name() const noexcept
const char* name() const noexcept override
{
return "asio.addrinfo";
}

std::string message(int value) const
std::string message(int value) const override
{
if (value == error::service_not_found)
return "Service not found";
Expand All @@ -93,12 +93,12 @@ namespace detail {
class misc_category : public asio::error_category
{
public:
const char* name() const noexcept
const char* name() const noexcept override
{
return "asio.misc";
}

std::string message(int value) const
std::string message(int value) const override
{
if (value == error::already_open)
return "Already open";
Expand Down
4 changes: 2 additions & 2 deletions 3rdparty/asio/include/asio/impl/error_code.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@ namespace detail {
class system_category : public error_category
{
public:
const char* name() const noexcept
const char* name() const noexcept override
{
return "asio.system";
}

std::string message(int value) const
std::string message(int value) const override
{
#if defined(ASIO_WINDOWS_RUNTIME) || defined(ASIO_WINDOWS_APP)
std::wstring wmsg(128, wchar_t());
Expand Down
24 changes: 12 additions & 12 deletions 3rdparty/asio/include/asio/impl/executor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -183,64 +183,64 @@ class executor::impl<system_executor, Allocator>
{
}

impl_base* clone() const noexcept
impl_base* clone() const noexcept override
{
return const_cast<impl_base*>(static_cast<const impl_base*>(this));
}

void destroy() noexcept
void destroy() noexcept override
{
}

void on_work_started() noexcept
void on_work_started() noexcept override
{
executor_.on_work_started();
}

void on_work_finished() noexcept
void on_work_finished() noexcept override
{
executor_.on_work_finished();
}

execution_context& context() noexcept
execution_context& context() noexcept override
{
return executor_.context();
}

void dispatch(function&& f)
void dispatch(function&& f) override
{
executor_.dispatch(static_cast<function&&>(f),
std::allocator<void>());
}

void post(function&& f)
void post(function&& f) override
{
executor_.post(static_cast<function&&>(f),
std::allocator<void>());
}

void defer(function&& f)
void defer(function&& f) override
{
executor_.defer(static_cast<function&&>(f),
std::allocator<void>());
}

type_id_result_type target_type() const noexcept
type_id_result_type target_type() const noexcept override
{
return type_id<system_executor>();
}

void* target() noexcept
void* target() noexcept override
{
return &executor_;
}

const void* target() const noexcept
const void* target() const noexcept override
{
return &executor_;
}

bool equals(const impl_base* e) const noexcept
bool equals(const impl_base* e) const noexcept override
{
return this == e;
}
Expand Down
4 changes: 2 additions & 2 deletions 3rdparty/asio/include/asio/io_context.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1157,7 +1157,7 @@ class io_context::service

private:
/// Destroy all user-defined handler objects owned by the service.
ASIO_DECL virtual void shutdown();
ASIO_DECL virtual void shutdown() override;

#if !defined(ASIO_NO_DEPRECATED)
/// (Deprecated: Use shutdown().) Destroy all user-defined handler objects
Expand All @@ -1172,7 +1172,7 @@ class io_context::service
* implement it if necessary. The default implementation does nothing.
*/
ASIO_DECL virtual void notify_fork(
execution_context::fork_event event);
execution_context::fork_event event) override;

#if !defined(ASIO_NO_DEPRECATED)
/// (Deprecated: Use notify_fork().) Handle notification of a fork-related
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/asio/include/asio/ip/bad_address_cast.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class bad_address_cast :
virtual ~bad_address_cast() noexcept {}

/// Get the message associated with the exception.
virtual const char* what() const noexcept
virtual const char* what() const noexcept override
{
return "bad address cast";
}
Expand Down
2 changes: 1 addition & 1 deletion 3rdparty/asio/include/asio/multiple_exceptions.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class multiple_exceptions

/// Obtain message associated with exception.
ASIO_DECL virtual const char* what() const
noexcept;
noexcept override;

/// Obtain a pointer to the first exception.
ASIO_DECL std::exception_ptr first_exception() const;
Expand Down
Loading

0 comments on commit 44c3506

Please sign in to comment.