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
3ed5bf7c
Commit
3ed5bf7c
authored
May 02, 2015
by
ufownl
Committed by
Dominik Charousset
May 02, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make the operator << of actor_ostream call caf::to_string automatically.
parent
370707c7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
7 deletions
+3
-7
libcaf_core/caf/actor_ostream.hpp
libcaf_core/caf/actor_ostream.hpp
+3
-7
No files found.
libcaf_core/caf/actor_ostream.hpp
View file @
3ed5bf7c
...
@@ -51,10 +51,6 @@ class actor_ostream {
...
@@ -51,10 +51,6 @@ class actor_ostream {
return
write
(
std
::
move
(
arg
));
return
write
(
std
::
move
(
arg
));
}
}
inline
actor_ostream
&
operator
<<
(
const
message
&
arg
)
{
return
write
(
caf
::
to_string
(
arg
));
}
// disambiguate between conversion to string and to message
// disambiguate between conversion to string and to message
inline
actor_ostream
&
operator
<<
(
const
char
*
arg
)
{
inline
actor_ostream
&
operator
<<
(
const
char
*
arg
)
{
return
*
this
<<
std
::
string
{
arg
};
return
*
this
<<
std
::
string
{
arg
};
...
@@ -62,10 +58,10 @@ class actor_ostream {
...
@@ -62,10 +58,10 @@ class actor_ostream {
template
<
class
T
>
template
<
class
T
>
inline
typename
std
::
enable_if
<
inline
typename
std
::
enable_if
<
!
std
::
is_convertible
<
T
,
std
::
string
>::
value
&&
!
std
::
is_convertible
<
T
,
std
::
string
>::
value
,
actor_ostream
&
!
std
::
is_convertible
<
T
,
message
>::
value
,
actor_ostream
&
>::
type
operator
<<
(
T
&&
arg
)
{
>::
type
operator
<<
(
T
&&
arg
)
{
return
write
(
std
::
to_string
(
std
::
forward
<
T
>
(
arg
)));
using
std
::
to_string
;
return
write
(
to_string
(
std
::
forward
<
T
>
(
arg
)));
}
}
inline
actor_ostream
&
operator
<<
(
actor_ostream
::
fun_type
f
)
{
inline
actor_ostream
&
operator
<<
(
actor_ostream
::
fun_type
f
)
{
...
...
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