Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
1cb15aef
Commit
1cb15aef
authored
Aug 05, 2023
by
Samir Halilcevic
Committed by
Dominik Charousset
Aug 10, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix compiler warnings on Linux
parent
6dc89b27
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
5 deletions
+18
-5
.ci/debug-flags.cmake
.ci/debug-flags.cmake
+1
-3
libcaf_core/caf/chrono.cpp
libcaf_core/caf/chrono.cpp
+0
-1
libcaf_core/caf/config.hpp
libcaf_core/caf/config.hpp
+6
-0
libcaf_core/caf/detail/type_traits.hpp
libcaf_core/caf/detail/type_traits.hpp
+10
-0
libcaf_core/caf/scheduled_actor.cpp
libcaf_core/caf/scheduled_actor.cpp
+1
-1
No files found.
.ci/debug-flags.cmake
View file @
1cb15aef
...
@@ -5,6 +5,4 @@ set(CAF_LOG_LEVEL TRACE CACHE STRING "")
...
@@ -5,6 +5,4 @@ set(CAF_LOG_LEVEL TRACE CACHE STRING "")
if
(
NOT MSVC AND NOT CMAKE_SYSTEM MATCHES BSD
)
if
(
NOT MSVC AND NOT CMAKE_SYSTEM MATCHES BSD
)
set
(
CMAKE_BUILD_TYPE Debug CACHE STRING
""
)
set
(
CMAKE_BUILD_TYPE Debug CACHE STRING
""
)
endif
()
endif
()
if
(
CMAKE_SYSTEM MATCHES BSD
)
set
(
CMAKE_CXX_FLAGS
"-Werror"
)
set
(
CMAKE_CXX_FLAGS
"-Werror"
)
endif
()
libcaf_core/caf/chrono.cpp
View file @
1cb15aef
...
@@ -41,7 +41,6 @@ time_t tm_to_time_t(tm& time_buf) noexcept {
...
@@ -41,7 +41,6 @@ time_t tm_to_time_t(tm& time_buf) noexcept {
}
// namespace
}
// namespace
#else
#else
# define _GNU_SOURCE
# include <ctime>
# include <ctime>
# include <ratio>
# include <ratio>
...
...
libcaf_core/caf/config.hpp
View file @
1cb15aef
...
@@ -89,6 +89,9 @@
...
@@ -89,6 +89,9 @@
# define CAF_PUSH_DEPRECATED_WARNING \
# define CAF_PUSH_DEPRECATED_WARNING \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Wdeprecated-declarations\"")
_Pragma("clang diagnostic ignored \"-Wdeprecated-declarations\"")
# define CAF_PUSH_UNUSED_RESULT_WARNING \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Wunused-result\"")
# define CAF_POP_WARNINGS \
# define CAF_POP_WARNINGS \
_Pragma("clang diagnostic pop")
_Pragma("clang diagnostic pop")
# define CAF_ANNOTATE_FALLTHROUGH [[clang::fallthrough]]
# define CAF_ANNOTATE_FALLTHROUGH [[clang::fallthrough]]
...
@@ -118,6 +121,9 @@
...
@@ -118,6 +121,9 @@
# define CAF_PUSH_DEPRECATED_WARNING \
# define CAF_PUSH_DEPRECATED_WARNING \
_Pragma("GCC diagnostic push") \
_Pragma("GCC diagnostic push") \
_Pragma("GCC diagnostic ignored \"-Wdeprecated-declarations\"")
_Pragma("GCC diagnostic ignored \"-Wdeprecated-declarations\"")
# define CAF_PUSH_UNUSED_RESULT_WARNING \
_Pragma("GCC diagnostic push") \
_Pragma("GCC diagnostic ignored \"-Wunused-result\"")
# define CAF_POP_WARNINGS \
# define CAF_POP_WARNINGS \
_Pragma("GCC diagnostic pop")
_Pragma("GCC diagnostic pop")
# if __GNUC__ >= 7
# if __GNUC__ >= 7
...
...
libcaf_core/caf/detail/type_traits.hpp
View file @
1cb15aef
...
@@ -4,6 +4,7 @@
...
@@ -4,6 +4,7 @@
#pragma once
#pragma once
#include "caf/config.hpp"
#include "caf/detail/is_complete.hpp"
#include "caf/detail/is_complete.hpp"
#include "caf/detail/is_one_of.hpp"
#include "caf/detail/is_one_of.hpp"
#include "caf/detail/type_list.hpp"
#include "caf/detail/type_list.hpp"
...
@@ -1034,8 +1035,17 @@ constexpr bool is_64bit_integer_v = std::is_same_v<T, int64_t>
...
@@ -1034,8 +1035,17 @@ constexpr bool is_64bit_integer_v = std::is_same_v<T, int64_t>
/// Checks whether `T` has a static member function called `init_host_system`.
/// Checks whether `T` has a static member function called `init_host_system`.
template
<
class
T
>
template
<
class
T
>
struct
has_init_host_system
{
struct
has_init_host_system
{
// GNU g++ 8.5.0 (almalinux-8) has a known bug where [[nodiscard] values are
// reported as warnings, even in unevaluated context.
// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89070
#if !defined(__clang__) && defined(__GNUC__)
CAF_PUSH_UNUSED_RESULT_WARNING
#endif
template
<
class
U
>
template
<
class
U
>
static
auto
sfinae
(
U
*
)
->
decltype
(
U
::
init_host_system
(),
std
::
true_type
());
static
auto
sfinae
(
U
*
)
->
decltype
(
U
::
init_host_system
(),
std
::
true_type
());
#if !defined(__clang__) && defined(__GNUC__)
CAF_POP_WARNINGS
#endif
template
<
class
U
>
template
<
class
U
>
static
auto
sfinae
(...)
->
std
::
false_type
;
static
auto
sfinae
(...)
->
std
::
false_type
;
...
...
libcaf_core/caf/scheduled_actor.cpp
View file @
1cb15aef
...
@@ -834,8 +834,8 @@ auto scheduled_actor::reactivate(mailbox_element& x) -> activation_result {
...
@@ -834,8 +834,8 @@ auto scheduled_actor::reactivate(mailbox_element& x) -> activation_result {
handle_exception
(
std
::
current_exception
());
handle_exception
(
std
::
current_exception
());
}
}
finalize
();
finalize
();
return
activation_result
::
terminated
;
#endif // CAF_ENABLE_EXCEPTIONS
#endif // CAF_ENABLE_EXCEPTIONS
return
activation_result
::
terminated
;
}
}
// -- behavior management ----------------------------------------------------
// -- behavior management ----------------------------------------------------
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment