Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Praetorius, Simon
dune-amdis
Commits
227d7857
Commit
227d7857
authored
Mar 01, 2019
by
Praetorius, Simon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added missing includes
parent
49e6913c
Pipeline
#1767
passed with stage
in 29 minutes and 50 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
5 deletions
+7
-5
src/amdis/common/FieldMatVec.hpp
src/amdis/common/FieldMatVec.hpp
+2
-0
src/amdis/common/TypeTraits.hpp
src/amdis/common/TypeTraits.hpp
+5
-5
No files found.
src/amdis/common/FieldMatVec.hpp
View file @
227d7857
...
...
@@ -7,6 +7,8 @@
#include <dune/common/fvector.hh>
#include <dune/common/typetraits.hh>
#include <amdis/common/TypeTraits.hpp>
namespace
std
{
template
<
class
T
,
int
N
>
...
...
src/amdis/common/TypeTraits.hpp
View file @
227d7857
...
...
@@ -35,13 +35,13 @@ namespace AMDiS
template
<
class
T
>
struct
UnderlyingType
{
using
type
=
T
;
using
type
=
remove_cvref_t
<
T
>
;
};
template
<
class
T
>
struct
UnderlyingType
<
std
::
reference_wrapper
<
T
>>
{
using
type
=
T
;
using
type
=
remove_cvref_t
<
T
>
;
};
}
...
...
@@ -53,7 +53,7 @@ namespace AMDiS
#define FWD(obj) std::forward<decltype(obj)>(obj)
/// A decay version of decltype, similar to GCCs __typeof__
#define TYPEOF(...) remove_cvref_t<decltype(__VA_ARGS__)>
#define TYPEOF(...)
AMDiS::
remove_cvref_t<decltype(__VA_ARGS__)>
/// Extract the static value of an integral_constant variable
#define VALUE(...) TYPEOF(__VA_ARGS__)::value
...
...
@@ -65,7 +65,7 @@ namespace AMDiS
struct
Types
{};
template
<
class
...
Ts
>
using
Types_t
=
Types
<
std
::
decay
_t
<
Ts
>
...
>
;
using
Types_t
=
Types
<
remove_cvref
_t
<
Ts
>
...
>
;
/// Alias that indicates ownership of resources
...
...
@@ -77,7 +77,7 @@ namespace AMDiS
template
<
class
Obj
>
auto
makeUniquePtr
(
Obj
&&
obj
)
{
return
std
::
make_unique
<
remove_cvref_t
<
O
bj
>
>
(
FWD
(
obj
));
return
std
::
make_unique
<
TYPEOF
(
o
bj
)
>
(
FWD
(
obj
));
}
}
// end namespace AMDiS
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