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
83714ced
Commit
83714ced
authored
Aug 09, 2012
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added rvalue overload for receive_loop
parent
fbad4957
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
0 deletions
+13
-0
cppa/receive.hpp
cppa/receive.hpp
+2
-0
src/receive.cpp
src/receive.cpp
+11
-0
No files found.
cppa/receive.hpp
View file @
83714ced
...
...
@@ -129,8 +129,10 @@ void receive(Arg0&& arg0, Args&&... args) {
}
void
receive_loop
(
behavior
&
rules
);
void
receive_loop
(
behavior
&&
rules
);
void
receive_loop
(
partial_function
&
rules
);
void
receive_loop
(
partial_function
&&
rules
);
template
<
typename
Arg0
,
typename
...
Args
>
void
receive_loop
(
Arg0
&&
arg0
,
Args
&&
...
args
)
{
...
...
src/receive.cpp
View file @
83714ced
...
...
@@ -39,6 +39,11 @@ void receive_loop(behavior& rules) {
}
}
void
receive_loop
(
behavior
&&
rules
)
{
behavior
tmp
(
std
::
move
(
rules
));
receive_loop
(
tmp
);
}
void
receive_loop
(
partial_function
&
rules
)
{
local_actor
*
sptr
=
self
;
for
(;;)
{
...
...
@@ -46,4 +51,10 @@ void receive_loop(partial_function& rules) {
}
}
void
receive_loop
(
partial_function
&&
rules
)
{
partial_function
tmp
(
std
::
move
(
rules
));
receive_loop
(
tmp
);
}
}
// namespace cppa
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