Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
Frama Clang
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pub
Frama Clang
Commits
777cb9fc
Commit
777cb9fc
authored
3 years ago
by
Virgile Prevosto
Browse files
Options
Downloads
Patches
Plain Diff
[stl] add support for is_enum and underlying_type type traits
parent
3b353b7f
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
share/libc++/type_traits
+8
-3
8 additions, 3 deletions
share/libc++/type_traits
with
8 additions
and
3 deletions
share/libc++/type_traits
+
8
−
3
View file @
777cb9fc
...
...
@@ -64,7 +64,7 @@ namespace std {
template <class T> struct is_rvalue_reference;
template <class T> struct is_member_object_pointer;
template <class T> struct is_member_function_pointer;
template <class T> struct is_enum;
template <class T> struct is_enum
: public __boolean<__is_enum(T)>{}
;
template <class T> struct is_union;
// see https://en.cppreference.com/w/cpp/types/is_class
...
...
@@ -282,9 +282,14 @@ namespace std {
// helper types
template< bool B, class T, class F >
using conditional_t = typename conditional<B,T,F>::type;
template <class... T> struct common_type;
template <class T> struct underlying_type;
template <bool, class T> struct __underlying_type_t {};
template <class T> struct __underlying_type_t<true, T> {
typedef __underlying_type(T) type;
};
template <class T>
struct underlying_type: __underlying_type_t<is_enum<T>::value,T> {};
template <class> class result_of;
template <class F, class... ArgTypes> class result_of<F(ArgTypes...)> {
public:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment