0001-fix_cpp20_build.patch 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. From 3197a520eb4c1e4754860441918a5930160373eb Mon Sep 17 00:00:00 2001
  2. From: Peter Thorson <git@zaphoyd.com>
  3. Date: Tue, 29 Jun 2021 09:13:12 -0500
  4. Subject: [PATCH] [core] Remove the use of simple template ids as they have
  5. been removed in c++20.
  6. https://timsong-cpp.github.io/cppwp/n4861/diff.cpp17.class#2 references #991
  7. Signed-off-by: Michael Nosthoff <buildroot@heine.tech>
  8. Upstream: https://github.com/zaphoyd/websocketpp/commit/3197a520eb4c1e4754860441918a5930160373eb
  9. ---
  10. websocketpp/endpoint.hpp | 2 +-
  11. websocketpp/logger/basic.hpp | 14 +++++++-------
  12. websocketpp/roles/server_endpoint.hpp | 6 +++---
  13. 3 files changed, 11 insertions(+), 11 deletions(-)
  14. diff --git a/websocketpp/endpoint.hpp b/websocketpp/endpoint.hpp
  15. index 825eaa46d..10f525689 100644
  16. --- a/websocketpp/endpoint.hpp
  17. +++ b/websocketpp/endpoint.hpp
  18. @@ -111,7 +111,7 @@ class endpoint : public config::transport_type, public config::endpoint_base {
  19. /// Destructor
  20. - ~endpoint<connection,config>() {}
  21. + ~endpoint() {}
  22. #ifdef _WEBSOCKETPP_DEFAULT_DELETE_FUNCTIONS_
  23. // no copy constructor because endpoints are not copyable
  24. diff --git a/websocketpp/logger/basic.hpp b/websocketpp/logger/basic.hpp
  25. index 84514130e..4c9d83649 100644
  26. --- a/websocketpp/logger/basic.hpp
  27. +++ b/websocketpp/logger/basic.hpp
  28. @@ -58,33 +58,33 @@ namespace log {
  29. template <typename concurrency, typename names>
  30. class basic {
  31. public:
  32. - basic<concurrency,names>(channel_type_hint::value h =
  33. + basic(channel_type_hint::value h =
  34. channel_type_hint::access)
  35. : m_static_channels(0xffffffff)
  36. , m_dynamic_channels(0)
  37. , m_out(h == channel_type_hint::error ? &std::cerr : &std::cout) {}
  38. - basic<concurrency,names>(std::ostream * out)
  39. + basic(std::ostream * out)
  40. : m_static_channels(0xffffffff)
  41. , m_dynamic_channels(0)
  42. , m_out(out) {}
  43. - basic<concurrency,names>(level c, channel_type_hint::value h =
  44. + basic(level c, channel_type_hint::value h =
  45. channel_type_hint::access)
  46. : m_static_channels(c)
  47. , m_dynamic_channels(0)
  48. , m_out(h == channel_type_hint::error ? &std::cerr : &std::cout) {}
  49. - basic<concurrency,names>(level c, std::ostream * out)
  50. + basic(level c, std::ostream * out)
  51. : m_static_channels(c)
  52. , m_dynamic_channels(0)
  53. , m_out(out) {}
  54. /// Destructor
  55. - ~basic<concurrency,names>() {}
  56. + ~basic() {}
  57. /// Copy constructor
  58. - basic<concurrency,names>(basic<concurrency,names> const & other)
  59. + basic(basic<concurrency,names> const & other)
  60. : m_static_channels(other.m_static_channels)
  61. , m_dynamic_channels(other.m_dynamic_channels)
  62. , m_out(other.m_out)
  63. @@ -97,7 +97,7 @@ class basic {
  64. #ifdef _WEBSOCKETPP_MOVE_SEMANTICS_
  65. /// Move constructor
  66. - basic<concurrency,names>(basic<concurrency,names> && other)
  67. + basic(basic<concurrency,names> && other)
  68. : m_static_channels(other.m_static_channels)
  69. , m_dynamic_channels(other.m_dynamic_channels)
  70. , m_out(other.m_out)
  71. diff --git a/websocketpp/roles/server_endpoint.hpp b/websocketpp/roles/server_endpoint.hpp
  72. index 4a5865eff..04fee18f9 100644
  73. --- a/websocketpp/roles/server_endpoint.hpp
  74. +++ b/websocketpp/roles/server_endpoint.hpp
  75. @@ -75,11 +75,11 @@ class server : public endpoint<connection<config>,config> {
  76. }
  77. /// Destructor
  78. - ~server<config>() {}
  79. + ~server() {}
  80. #ifdef _WEBSOCKETPP_DEFAULT_DELETE_FUNCTIONS_
  81. // no copy constructor because endpoints are not copyable
  82. - server<config>(server<config> &) = delete;
  83. + server(server<config> &) = delete;
  84. // no copy assignment operator because endpoints are not copyable
  85. server<config> & operator=(server<config> const &) = delete;
  86. @@ -87,7 +87,7 @@ class server : public endpoint<connection<config>,config> {
  87. #ifdef _WEBSOCKETPP_MOVE_SEMANTICS_
  88. /// Move constructor
  89. - server<config>(server<config> && o) : endpoint<connection<config>,config>(std::move(o)) {}
  90. + server(server<config> && o) : endpoint<connection<config>,config>(std::move(o)) {}
  91. #ifdef _WEBSOCKETPP_DEFAULT_DELETE_FUNCTIONS_
  92. // no move assignment operator because of const member variables