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
af46f59c
Commit
af46f59c
authored
Sep 28, 2018
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add missing type to type name builder
parent
3702fd4d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
35 deletions
+21
-35
libcaf_core/caf/detail/type_name.hpp
libcaf_core/caf/detail/type_name.hpp
+21
-35
No files found.
libcaf_core/caf/detail/type_name.hpp
View file @
af46f59c
...
...
@@ -34,28 +34,28 @@ struct type_name_builder_int_size;
template
<
>
struct
type_name_builder_int_size
<
1
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"8"
;
}
};
template
<
>
struct
type_name_builder_int_size
<
2
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"16"
;
}
};
template
<
>
struct
type_name_builder_int_size
<
4
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"32"
;
}
};
template
<
>
struct
type_name_builder_int_size
<
8
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"64"
;
}
};
...
...
@@ -65,45 +65,32 @@ struct type_name_builder;
template
<
>
struct
type_name_builder
<
bool
,
true
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"boolean"
;
}
};
template
<
>
struct
type_name_builder
<
float
,
false
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"32-bit real"
;
#define CAF_TYPE_NAME_BUILDER_NOINT(class_name, pretty_name) \
template <> \
struct type_name_builder<class_name, false> { \
void operator()(std::string& result) const { \
result += pretty_name; \
} \
}
};
template
<
>
struct
type_name_builder
<
double
,
false
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"64-bit real"
;
}
};
CAF_TYPE_NAME_BUILDER_NOINT
(
float
,
"32-bit real"
);
template
<
>
struct
type_name_builder
<
timespan
,
false
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"timespan"
;
}
};
CAF_TYPE_NAME_BUILDER_NOINT
(
double
,
"64-bit real"
);
template
<
>
struct
type_name_builder
<
std
::
string
,
false
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"string"
;
}
};
CAF_TYPE_NAME_BUILDER_NOINT
(
timespan
,
"timespan"
);
template
<
>
struct
type_name_builder
<
atom_value
,
false
>
{
inline
void
operator
()(
std
::
string
&
result
)
const
{
result
+=
"atom"
;
}
};
CAF_TYPE_NAME_BUILDER_NOINT
(
std
::
string
,
"string"
);
CAF_TYPE_NAME_BUILDER_NOINT
(
atom_value
,
"atom"
);
CAF_TYPE_NAME_BUILDER_NOINT
(
uri
,
"uri"
);
#undef CAF_TYPE_NAME_BUILDER
template
<
class
T
>
struct
type_name_builder
<
T
,
true
>
{
...
...
@@ -145,4 +132,3 @@ std::string type_name() {
}
// namespace detail
}
// namespace caf
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