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
951b12cf
Commit
951b12cf
authored
Aug 15, 2012
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed forwarding during tuple creation
parent
edd57563
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
23 deletions
+11
-23
cppa/cow_tuple.hpp
cppa/cow_tuple.hpp
+2
-15
cppa/detail/tdata.hpp
cppa/detail/tdata.hpp
+5
-3
cppa/detail/tuple_vals.hpp
cppa/detail/tuple_vals.hpp
+4
-5
No files found.
cppa/cow_tuple.hpp
View file @
951b12cf
...
...
@@ -89,25 +89,12 @@ class cow_tuple {
static
constexpr
size_t
num_elements
=
sizeof
...(
ElementTypes
);
/**
* @brief Initializes each element with its default constructor.
*/
cow_tuple
()
:
m_vals
(
new
data_type
)
{
}
/**
* @brief Initializes the cow_tuple with @p args.
* @param args Initialization values.
*/
cow_tuple
(
const
ElementTypes
&
...
args
)
:
m_vals
(
new
data_type
(
args
...))
{
}
/**
* @brief Initializes the cow_tuple with @p args.
* @param args Initialization values.
*/
cow_tuple
(
ElementTypes
&&
...
args
)
:
m_vals
(
new
data_type
(
std
::
move
(
args
)...))
{
}
template
<
typename
...
Args
>
cow_tuple
(
Args
&&
...
args
)
:
m_vals
(
new
data_type
(
std
::
forward
<
Args
>
(
args
)...))
{
}
cow_tuple
(
cow_tuple
&&
)
=
default
;
cow_tuple
(
const
cow_tuple
&
)
=
default
;
...
...
cppa/detail/tdata.hpp
View file @
951b12cf
...
...
@@ -200,8 +200,7 @@ struct td_filter_<true, false, Head, T> {
};
template
<
typename
Head
,
typename
T
>
struct
td_filter_
<
true
,
true
,
Head
,
T
>
:
td_filter_
<
true
,
false
,
Head
,
T
>
{
};
struct
td_filter_
<
true
,
true
,
Head
,
T
>
:
td_filter_
<
true
,
false
,
Head
,
T
>
{
};
template
<
typename
Head
,
typename
T
>
auto
td_filter
(
T
&&
arg
)
...
...
@@ -248,7 +247,10 @@ struct tdata<Head, Tail...> : tdata<Tail...> {
inline
tdata
()
:
super
(),
head
()
{
}
tdata
(
Head
arg
)
:
super
(),
head
(
std
::
move
(
arg
))
{
}
//tdata(Head arg) : super(), head(std::move(arg)) { }
tdata
(
const
Head
&
arg
)
:
super
(),
head
(
arg
)
{
}
tdata
(
Head
&&
arg
)
:
super
(),
head
(
std
::
move
(
arg
))
{
}
template
<
typename
Arg0
,
typename
Arg1
,
typename
...
Args
>
tdata
(
Arg0
&&
arg0
,
Arg1
&&
arg1
,
Args
&&
...
args
)
...
...
cppa/detail/tuple_vals.hpp
View file @
951b12cf
...
...
@@ -56,13 +56,12 @@ class tuple_vals : public abstract_tuple {
typedef
types_array
<
ElementTypes
...
>
element_types
;
tuple_vals
()
:
super
(
tuple_impl_info
::
statically_typed
),
m_data
()
{
}
tuple_vals
(
const
tuple_vals
&
)
=
default
;
tuple_vals
(
const
ElementTypes
&
...
args
)
:
super
(
tuple_impl_info
::
statically_typed
),
m_data
(
args
...)
{
}
template
<
typename
...
Args
>
tuple_vals
(
Args
&&
...
args
)
:
super
(
tuple_impl_info
::
statically_typed
)
,
m_data
(
std
::
forward
<
Args
>
(
args
)...)
{
}
const
void
*
native_data
()
const
{
return
&
m_data
;
...
...
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