Skip to content

Commit

Permalink
auto update to latest DPP master branch
Browse files Browse the repository at this point in the history
  • Loading branch information
D++ Update Bot committed Feb 8, 2025
1 parent 74a835c commit 2006bf5
Show file tree
Hide file tree
Showing 19 changed files with 42 additions and 46 deletions.
Binary file modified MyBot/dependencies/32/debug/bin/dpp.dll
Binary file not shown.
1 change: 0 additions & 1 deletion MyBot/dependencies/32/debug/lib/cmake/dpp/dpp.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ endif()
add_library(dpp::dpp SHARED IMPORTED)

set_target_properties(dpp::dpp PROPERTIES
INTERFACE_COMPILE_DEFINITIONS "DPP_CORO"
INTERFACE_COMPILE_FEATURES "cxx_std_17;cxx_std_20"
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include/dpp-10.1"
INTERFACE_LINK_LIBRARIES "D:/a/DPP/DPP/main/win32/32/lib/libssl.lib;D:/a/DPP/DPP/main/win32/32/lib/libcrypto.lib;D:/a/DPP/DPP/main/win32/32/lib/zlib.lib;D:/a/DPP/DPP/main/win32/32/lib/opus.lib;D:/a/DPP/DPP/main/win32/32/lib/libssl.lib;D:/a/DPP/DPP/main/win32/32/lib/libcrypto.lib;D:/a/DPP/DPP/main/win32/32/lib/zlib.lib;D:/a/DPP/DPP/main/win32/32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/libssl.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/libcrypto.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/zlib.lib;D:/a/DPP/DPP/main/win32/32/lib/opus.lib"
Expand Down
Binary file modified MyBot/dependencies/32/release/bin/dpp.dll
Binary file not shown.
1 change: 0 additions & 1 deletion MyBot/dependencies/32/release/lib/cmake/dpp/dpp.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ endif()
add_library(dpp::dpp SHARED IMPORTED)

set_target_properties(dpp::dpp PROPERTIES
INTERFACE_COMPILE_DEFINITIONS "DPP_CORO"
INTERFACE_COMPILE_FEATURES "cxx_std_17;cxx_std_20"
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include/dpp-10.1"
INTERFACE_LINK_LIBRARIES "D:/a/DPP/DPP/main/win32/32/lib/libssl.lib;D:/a/DPP/DPP/main/win32/32/lib/libcrypto.lib;D:/a/DPP/DPP/main/win32/32/lib/zlib.lib;D:/a/DPP/DPP/main/win32/32/lib/opus.lib;D:/a/DPP/DPP/main/win32/32/lib/libssl.lib;D:/a/DPP/DPP/main/win32/32/lib/libcrypto.lib;D:/a/DPP/DPP/main/win32/32/lib/zlib.lib;D:/a/DPP/DPP/main/win32/32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/libssl.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/libcrypto.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/32/lib/zlib.lib;D:/a/DPP/DPP/main/win32/32/lib/opus.lib"
Expand Down
Binary file modified MyBot/dependencies/64/debug/bin/dpp.dll
Binary file not shown.
1 change: 0 additions & 1 deletion MyBot/dependencies/64/debug/lib/cmake/dpp/dpp.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ endif()
add_library(dpp::dpp SHARED IMPORTED)

set_target_properties(dpp::dpp PROPERTIES
INTERFACE_COMPILE_DEFINITIONS "DPP_CORO"
INTERFACE_COMPILE_FEATURES "cxx_std_17;cxx_std_20"
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include/dpp-10.1"
INTERFACE_LINK_LIBRARIES "D:/a/DPP/DPP/main/library/../win32/lib/libssl.lib;D:/a/DPP/DPP/main/library/../win32/lib/libcrypto.lib;D:/a/DPP/DPP/main/library/../win32/lib/zlib.lib;D:/a/DPP/DPP/main/library/../win32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/lib/libssl.lib;D:/a/DPP/DPP/main/library/../win32/lib/libcrypto.lib;D:/a/DPP/DPP/main/library/../win32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/lib/zlib.lib;D:/a/DPP/DPP/main/library/../win32/lib/opus.lib"
Expand Down
Binary file modified MyBot/dependencies/64/release/bin/dpp.dll
Binary file not shown.
1 change: 0 additions & 1 deletion MyBot/dependencies/64/release/lib/cmake/dpp/dpp.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ endif()
add_library(dpp::dpp SHARED IMPORTED)

set_target_properties(dpp::dpp PROPERTIES
INTERFACE_COMPILE_DEFINITIONS "DPP_CORO"
INTERFACE_COMPILE_FEATURES "cxx_std_17;cxx_std_20"
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include/dpp-10.1"
INTERFACE_LINK_LIBRARIES "D:/a/DPP/DPP/main/library/../win32/lib/libssl.lib;D:/a/DPP/DPP/main/library/../win32/lib/libcrypto.lib;D:/a/DPP/DPP/main/library/../win32/lib/zlib.lib;D:/a/DPP/DPP/main/library/../win32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/lib/libssl.lib;D:/a/DPP/DPP/main/library/../win32/lib/libcrypto.lib;D:/a/DPP/DPP/main/library/../win32/lib/opus.lib;D:/a/DPP/DPP/main/library/../win32/lib/zlib.lib;D:/a/DPP/DPP/main/library/../win32/lib/opus.lib"
Expand Down
10 changes: 5 additions & 5 deletions MyBot/dependencies/include/dpp-10.1/dpp/cluster.h
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ class DPP_EXPORT cluster {
*/
using slashcommand_handler_t = std::function<void(const slashcommand_t &)>;

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Typedef for coroutines based slashcommand handler type
*/
Expand Down Expand Up @@ -445,7 +445,7 @@ class DPP_EXPORT cluster {
*/
timer start_timer(timer_callback_t on_tick, uint64_t frequency, timer_callback_t on_stop = {});

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Start a coroutine timer. Every `frequency` seconds, the callback is called.
*
Expand Down Expand Up @@ -481,7 +481,7 @@ class DPP_EXPORT cluster {
*/
bool stop_timer(timer t);

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Get an awaitable to wait a certain amount of seconds. Use the co_await keyword on its return value to suspend the coroutine until the timer ends
*
Expand Down Expand Up @@ -576,7 +576,7 @@ class DPP_EXPORT cluster {
*/
size_t active_requests();

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Register a coroutine-based slash command handler.
*
Expand Down Expand Up @@ -4071,7 +4071,7 @@ class DPP_EXPORT cluster {
*/
void channel_set_voice_status(snowflake channel_id, const std::string& status, command_completion_event_t callback = utility::log_error());

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
#include <dpp/cluster_coro_calls.h>
#endif

Expand Down
4 changes: 2 additions & 2 deletions MyBot/dependencies/include/dpp-10.1/dpp/coro/async.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ struct async_dummy : awaitable_dummy {

}

#ifdef DPP_CORO
#ifndef DPP_NO_CORO

#include "coro.h"

Expand Down Expand Up @@ -186,4 +186,4 @@ DPP_CHECK_ABI_COMPAT(async<>, async_dummy);

}

#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */
4 changes: 2 additions & 2 deletions MyBot/dependencies/include/dpp-10.1/dpp/coro/awaitable.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ struct awaitable_dummy {

}

#ifdef DPP_CORO
#ifndef DPP_NO_CORO

#include <dpp/coro/coro.h>

Expand Down Expand Up @@ -732,4 +732,4 @@ void spawn_sync_wait_job(auto* awaitable, std::condition_variable &cv, auto&& re

}

#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */
4 changes: 2 additions & 2 deletions MyBot/dependencies/include/dpp-10.1/dpp/coro/coro.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
************************************************************************************/

#pragma once
#ifdef DPP_CORO
#ifndef DPP_NO_CORO

#if (defined(_LIBCPP_VERSION) and !defined(__cpp_impl_coroutine)) // if libc++ experimental implementation (LLVM < 14)
# define STDCORO_EXPERIMENTAL_HEADER
Expand Down Expand Up @@ -198,5 +198,5 @@ inline int coro_alloc_count = 0;

} // namespace dpp

#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */

4 changes: 2 additions & 2 deletions MyBot/dependencies/include/dpp-10.1/dpp/coro/coroutine.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ struct coroutine_dummy {

}

#ifdef DPP_CORO
#ifndef DPP_NO_CORO

#include <dpp/coro/coro.h>
#include <dpp/coro/awaitable.h>
Expand Down Expand Up @@ -403,4 +403,4 @@ struct dpp::detail::std_coroutine::coroutine_traits<dpp::coroutine<R>, Args...>
using promise_type = dpp::detail::coroutine::promise_t<R>;
};

#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */
4 changes: 2 additions & 2 deletions MyBot/dependencies/include/dpp-10.1/dpp/coro/job.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ struct job_dummy {

}

#ifdef DPP_CORO
#ifndef DPP_NO_CORO

#include "coro.h"

Expand Down Expand Up @@ -142,4 +142,4 @@ struct dpp::detail::std_coroutine::coroutine_traits<dpp::job, Args...> {
using promise_type = dpp::detail::job::promise<Args...>;
};

#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */
4 changes: 2 additions & 2 deletions MyBot/dependencies/include/dpp-10.1/dpp/coro/task.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ struct task_dummy : awaitable_dummy {

}

#ifdef DPP_CORO
#ifndef DPP_NO_CORO

#include <dpp/coro/coro.h>

Expand Down Expand Up @@ -443,4 +443,4 @@ struct dpp::detail::std_coroutine::coroutine_traits<dpp::task<T>, Args...> {
using promise_type = dpp::detail::task::promise_t<T>;
};

#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */
2 changes: 1 addition & 1 deletion MyBot/dependencies/include/dpp-10.1/dpp/coro/when_any.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
*
************************************************************************************/

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
#pragma once

#include "coro.h"
Expand Down
12 changes: 6 additions & 6 deletions MyBot/dependencies/include/dpp-10.1/dpp/dispatcher.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@
#include <algorithm>
#include <string>

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
#include <dpp/coro.h>
#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */

namespace dpp {

Expand Down Expand Up @@ -582,7 +582,7 @@ struct DPP_EXPORT interaction_create_t : public event_dispatch_t {
*/
void delete_original_response(command_completion_event_t callback = utility::log_error()) const;

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Acknowledge interaction without displaying a message to the user,
* for use with button and select menu components.
Expand Down Expand Up @@ -680,7 +680,7 @@ struct DPP_EXPORT interaction_create_t : public event_dispatch_t {
* On success the result will contain a dpp::confirmation object in confirmation_callback_t::value. On failure, the value is undefined and confirmation_callback_t::is_error() method will return true. You can obtain full error details with confirmation_callback_t::get_error().
*/
dpp::async<dpp::confirmation_callback_t> co_delete_original_response() const;
#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */

/**
* @brief command interaction
Expand Down Expand Up @@ -1696,7 +1696,7 @@ struct DPP_EXPORT message_create_t : public event_dispatch_t {
*/
void reply(message&& msg, bool mention_replied_user = false, command_completion_event_t callback = utility::log_error()) const;

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Send a text to the same channel as the channel_id in received event.
*
Expand Down Expand Up @@ -1747,7 +1747,7 @@ struct DPP_EXPORT message_create_t : public event_dispatch_t {
* On success the result will contain a dpp::confirmation object in confirmation_callback_t::value. On failure, the value is undefined and confirmation_callback_t::is_error() method will return true. You can obtain full error details with confirmation_callback_t::get_error().
*/
dpp::async<dpp::confirmation_callback_t> co_reply(message&& msg, bool mention_replied_user = false) const;
#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */
};

/**
Expand Down
28 changes: 14 additions & 14 deletions MyBot/dependencies/include/dpp-10.1/dpp/event_router.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

namespace dpp {

#ifdef DPP_CORO
#ifndef DPP_NO_CORO

template <typename T>
class event_router_t;
Expand Down Expand Up @@ -212,7 +212,7 @@ template<class T> class event_router_t {
*/
using event_handler_abi_t = std::variant<regular_handler_t, std::function<task_dummy(T)>>;

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
friend class detail::event_router::awaitable<T>;

/** @brief dpp::task coro event handler */
Expand Down Expand Up @@ -247,7 +247,7 @@ template<class T> class event_router_t {
*/
std::map<event_handle, event_handler_t> dispatch_container;

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Mutex for messing with coro_awaiters.
*/
Expand Down Expand Up @@ -311,7 +311,7 @@ template<class T> class event_router_t {
};
}

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Handle an event as a coroutine, ensuring the lifetime of the event object.
*/
Expand Down Expand Up @@ -425,7 +425,7 @@ template<class T> class event_router_t {
* This will be caught in this destructor, however, make sure no other exceptions are thrown in the coroutine after that or it will terminate.
*/
~event_router_t() {
#ifdef DPP_CORO
#ifndef DPP_NO_CORO
while (!coro_awaiters.empty()) {
// cancel all awaiters. here we cannot do the usual loop as we'd need to lock coro_mutex, and cancel() locks and modifies coro_awaiters
try {
Expand All @@ -449,7 +449,7 @@ template<class T> class event_router_t {
* @param event Class to pass as parameter to all listeners.
*/
void call(const T& event) const {
#ifdef DPP_CORO
#ifndef DPP_NO_CORO
handle_coro(event);
#else
handle(event);
Expand All @@ -463,14 +463,14 @@ template<class T> class event_router_t {
* @param event Class to pass as parameter to all listeners.
*/
void call(T&& event) const {
#ifdef DPP_CORO
#ifndef DPP_NO_CORO
handle_coro(std::move(event));
#else
handle(std::move(event));
#endif
};

#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Obtain an awaitable object that refers to an event with a certain condition.
* It can be co_await-ed to wait for the next event that satisfies this condition.
Expand Down Expand Up @@ -542,7 +542,7 @@ template<class T> class event_router_t {
* @retval false if there are some listeners
*/
[[nodiscard]] bool empty() const {
#ifdef DPP_CORO
#ifndef DPP_NO_CORO
std::shared_lock lock{mutex};
std::shared_lock coro_lock{coro_mutex};

Expand All @@ -569,7 +569,7 @@ template<class T> class event_router_t {
/**
* @brief Attach a callable to the event, adding a listener.
* The callable should either be of the form `void(const T&)` or
* `dpp::task<void>(const T&)` (the latter requires DPP_CORO to be defined),
* `dpp::task<void>(const T&)`,
* where T is the event type for this event router.
*
* This has the exact same behavior as using \ref attach(F&&) "attach".
Expand All @@ -585,7 +585,7 @@ template<class T> class event_router_t {
/**
* @brief Attach a callable to the event, adding a listener.
* The callable should either be of the form `void(const T&)` or
* `dpp::task<void>(const T&)` (the latter requires DPP_CORO to be defined),
* `dpp::task<void>(const T&)`,
* where T is the event type for this event router.
*
* @param fun Callable to attach to event
Expand All @@ -595,7 +595,7 @@ template<class T> class event_router_t {
template <typename F>
[[maybe_unused]] event_handle attach(F&& fun);
#else /* not _DOXYGEN_ */
# ifdef DPP_CORO
# ifndef DPP_NO_CORO
/**
* @brief Attach a callable to the event, adding a listener.
* The callable should either be of the form `void(const T&)` or
Expand Down Expand Up @@ -681,7 +681,7 @@ template<class T> class event_router_t {
dispatch_container.emplace(h, std::forward<F>(fun));
return h;
}
# endif /* DPP_CORO */
# endif /* DPP_NO_CORO */
#endif /* _DOXYGEN_ */
/**
* @brief Detach a listener from the event using a previously obtained ID.
Expand All @@ -698,7 +698,7 @@ template<class T> class event_router_t {
}
};

#ifdef DPP_CORO
#ifndef DPP_NO_CORO

namespace detail::event_router {

Expand Down
8 changes: 4 additions & 4 deletions MyBot/dependencies/include/dpp-10.1/dpp/exception.h
Original file line number Diff line number Diff line change
Expand Up @@ -579,13 +579,13 @@ class exception : public std::exception
* @note This is a stub for documentation purposes. For full information on supported methods please see dpp::exception.
*/
class invalid_token_exception : public dpp::rest_exception { };
#ifdef DPP_CORO
#ifndef DPP_NO_CORO
/**
* @brief Represents the cancellation of a task. Will be thrown to the awaiter of a cancelled task.
* @note This is a stub for documentation purposes. For full information on supported methods please see dpp::exception.
*/
class task_cancelled_exception : public dpp::exception { };
#endif /* DPP_CORO */
#endif /* DPP_NO_CORO */
#else
derived_exception(logic_exception, exception);
derived_exception(file_exception, exception);
Expand All @@ -598,9 +598,9 @@ class exception : public std::exception
derived_exception(length_exception, exception);
derived_exception(parse_exception, exception);
derived_exception(cache_exception, exception);
# ifdef DPP_CORO
# ifndef DPP_NO_CORO
derived_exception(task_cancelled_exception, exception);
# endif /* DPP_CORO */
# endif /* DPP_NO_CORO */
#endif

}
Expand Down

0 comments on commit 2006bf5

Please sign in to comment.