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
69727629
Commit
69727629
authored
Sep 16, 2019
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adhere to naming conventions
parent
c7dee447
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
libcaf_core/test/inspector.cpp
libcaf_core/test/inspector.cpp
+6
-6
No files found.
libcaf_core/test/inspector.cpp
View file @
69727629
...
@@ -241,8 +241,8 @@ struct binary_serialization_policy {
...
@@ -241,8 +241,8 @@ struct binary_serialization_policy {
template
<
class
T
>
template
<
class
T
>
std
::
vector
<
char
>
to_buf
(
const
T
&
x
)
{
std
::
vector
<
char
>
to_buf
(
const
T
&
x
)
{
std
::
vector
<
char
>
result
;
std
::
vector
<
char
>
result
;
binary_serializer
f
{
&
context
,
result
};
binary_serializer
sink
{
&
context
,
result
};
if
(
auto
err
=
f
(
x
))
if
(
auto
err
=
sink
(
x
))
CAF_FAIL
(
"failed to serialize "
<<
x
<<
": "
<<
err
);
CAF_FAIL
(
"failed to serialize "
<<
x
<<
": "
<<
err
);
return
result
;
return
result
;
}
}
...
@@ -250,9 +250,9 @@ struct binary_serialization_policy {
...
@@ -250,9 +250,9 @@ struct binary_serialization_policy {
template
<
class
T
>
template
<
class
T
>
detail
::
enable_if_t
<
is_integral_or_enum
<
T
>::
value
,
bool
>
operator
()(
T
&
x
)
{
detail
::
enable_if_t
<
is_integral_or_enum
<
T
>::
value
,
bool
>
operator
()(
T
&
x
)
{
auto
buf
=
to_buf
(
x
);
auto
buf
=
to_buf
(
x
);
binary_deserializer
f
{
&
context
,
buf
};
binary_deserializer
source
{
&
context
,
buf
};
auto
y
=
static_cast
<
T
>
(
0
);
auto
y
=
static_cast
<
T
>
(
0
);
if
(
auto
err
=
f
(
y
))
if
(
auto
err
=
source
(
y
))
CAF_FAIL
(
"failed to deserialize from buffer: "
<<
err
);
CAF_FAIL
(
"failed to deserialize from buffer: "
<<
err
);
CAF_CHECK_EQUAL
(
x
,
y
);
CAF_CHECK_EQUAL
(
x
,
y
);
return
detail
::
safe_equal
(
x
,
y
);
return
detail
::
safe_equal
(
x
,
y
);
...
@@ -261,9 +261,9 @@ struct binary_serialization_policy {
...
@@ -261,9 +261,9 @@ struct binary_serialization_policy {
template
<
class
T
>
template
<
class
T
>
detail
::
enable_if_t
<!
is_integral_or_enum
<
T
>::
value
,
bool
>
operator
()(
T
&
x
)
{
detail
::
enable_if_t
<!
is_integral_or_enum
<
T
>::
value
,
bool
>
operator
()(
T
&
x
)
{
auto
buf
=
to_buf
(
x
);
auto
buf
=
to_buf
(
x
);
binary_deserializer
f
{
&
context
,
buf
};
binary_deserializer
source
{
&
context
,
buf
};
T
y
;
T
y
;
if
(
auto
err
=
f
(
y
))
if
(
auto
err
=
source
(
y
))
CAF_FAIL
(
"failed to deserialize from buffer: "
<<
err
);
CAF_FAIL
(
"failed to deserialize from buffer: "
<<
err
);
CAF_CHECK_EQUAL
(
x
,
y
);
CAF_CHECK_EQUAL
(
x
,
y
);
return
detail
::
safe_equal
(
x
,
y
);
return
detail
::
safe_equal
(
x
,
y
);
...
...
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