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
4455ec62
Commit
4455ec62
authored
Sep 16, 2019
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add type-check to attach_stream_source
parent
a634eda4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
libcaf_core/caf/attach_stream_source.hpp
libcaf_core/caf/attach_stream_source.hpp
+6
-1
No files found.
libcaf_core/caf/attach_stream_source.hpp
View file @
4455ec62
...
@@ -31,6 +31,7 @@
...
@@ -31,6 +31,7 @@
#include "caf/is_actor_handle.hpp"
#include "caf/is_actor_handle.hpp"
#include "caf/make_source_result.hpp"
#include "caf/make_source_result.hpp"
#include "caf/policy/arg.hpp"
#include "caf/policy/arg.hpp"
#include "caf/response_type.hpp"
#include "caf/stream_source.hpp"
#include "caf/stream_source.hpp"
namespace
caf
{
namespace
caf
{
...
@@ -119,7 +120,11 @@ detail::enable_if_t<is_actor_handle<ActorHandle>::value,
...
@@ -119,7 +120,11 @@ detail::enable_if_t<is_actor_handle<ActorHandle>::value,
attach_stream_source
(
scheduled_actor
*
self
,
const
ActorHandle
&
dest
,
attach_stream_source
(
scheduled_actor
*
self
,
const
ActorHandle
&
dest
,
std
::
tuple
<
Ts
...
>
xs
,
Init
init
,
Pull
pull
,
Done
done
,
std
::
tuple
<
Ts
...
>
xs
,
Init
init
,
Pull
pull
,
Done
done
,
Finalize
fin
=
{},
policy
::
arg
<
DownstreamManager
>
=
{})
{
Finalize
fin
=
{},
policy
::
arg
<
DownstreamManager
>
=
{})
{
// TODO: type checking of dest
using
namespace
detail
;
using
token
=
type_list
<
stream
<
typename
DownstreamManager
::
output_type
>
,
strip_and_convert_t
<
Ts
>
...
>
;
static_assert
(
response_type_unbox
<
signatures_of_t
<
ActorHandle
>
,
token
>::
valid
,
"receiver does not accept the stream handshake"
);
using
driver
=
detail
::
stream_source_driver_impl
<
DownstreamManager
,
Pull
,
using
driver
=
detail
::
stream_source_driver_impl
<
DownstreamManager
,
Pull
,
Done
,
Finalize
>
;
Done
,
Finalize
>
;
auto
mgr
=
detail
::
make_stream_source
<
driver
>
(
self
,
std
::
move
(
init
),
auto
mgr
=
detail
::
make_stream_source
<
driver
>
(
self
,
std
::
move
(
init
),
...
...
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