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
25a601e1
Commit
25a601e1
authored
Oct 12, 2019
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Integrate review feedback
parent
9c7b9ab7
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
6 deletions
+5
-6
libcaf_core/caf/config_value.hpp
libcaf_core/caf/config_value.hpp
+1
-1
libcaf_core/caf/config_value_field.hpp
libcaf_core/caf/config_value_field.hpp
+2
-2
libcaf_core/src/make_config_option.cpp
libcaf_core/src/make_config_option.cpp
+1
-1
libcaf_core/test/make_config_value_field.cpp
libcaf_core/test/make_config_value_field.cpp
+1
-2
No files found.
libcaf_core/caf/config_value.hpp
View file @
25a601e1
...
...
@@ -508,7 +508,7 @@ struct select_config_value_access<T, select_config_value_hint::is_list> {
};
};
/// Catches all non-specialized
list
types.
/// Catches all non-specialized
map
types.
template
<
class
T
>
struct
select_config_value_access
<
T
,
select_config_value_hint
::
is_map
>
{
struct
type
{
...
...
libcaf_core/caf/config_value_field.hpp
View file @
25a601e1
...
...
@@ -36,7 +36,7 @@ public:
/// Checks whether `x` matches the type of this field.
virtual
bool
type_check
(
const
config_value
&
x
)
const
noexcept
=
0
;
/// Returns whether this field in `object` .
/// Returns whether this field in `object`
contains valid data
.
virtual
bool
valid
(
const
Object
&
object
)
const
noexcept
=
0
;
/// Returns whether this field has a default value.
...
...
@@ -50,7 +50,7 @@ public:
// -- modifiers --------------------------------------------------------------
/// Sets this field in `object` to `x`.
`
/// Sets this field in `object` to `x`.
/// @pre `can_set(x)`
virtual
void
set
(
Object
&
object
,
const
config_value
&
x
)
const
=
0
;
...
...
libcaf_core/src/make_config_option.cpp
View file @
25a601e1
...
...
@@ -94,7 +94,7 @@ void store_timespan(void* ptr, const config_value& x) {
template
<
uint64_t
Denominator
>
config_value
get_timespan
(
const
void
*
ptr
)
{
auto
ival
=
static_cast
<
int64_t
>
(
*
static_cast
<
const
size_t
*>
(
ptr
));
timespan
val
{
ival
*
1000
};
timespan
val
{
ival
*
Denominator
};
return
config_value
{
val
};
}
...
...
libcaf_core/test/make_config_value_field.cpp
View file @
25a601e1
...
...
@@ -215,8 +215,8 @@ CAF_TEST(oject access from dictionary - foobar) {
auto
fb
=
get
<
foobar
>
(
x
,
"my-value"
);
CAF_CHECK_EQUAL
(
fb
.
foo
,
123
);
CAF_CHECK_EQUAL
(
fb
.
bar
,
"hello"
);
CAF_MESSAGE
(
"with foo member"
);
}
CAF_MESSAGE
(
"with foo member"
);
put
(
x
,
"my-value.foo"
,
42
);
{
CAF_REQUIRE
(
holds_alternative
<
foobar
>
(
x
,
"my-value"
));
...
...
@@ -224,7 +224,6 @@ CAF_TEST(oject access from dictionary - foobar) {
auto
fb
=
get
<
foobar
>
(
x
,
"my-value"
);
CAF_CHECK_EQUAL
(
fb
.
foo
,
42
);
CAF_CHECK_EQUAL
(
fb
.
bar
,
"hello"
);
CAF_MESSAGE
(
"with foo member"
);
}
}
...
...
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