Arene Base
Fundamental Utilities For Safety Critical C++
Loading...
Searching...
No Matches
remove_volatile.hpp
Go to the documentation of this file.
1
// Copyright 2024, Toyota Motor Corporation
2
//
3
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
4
5
#
ifndef
INCLUDE_GUARD_ARENE_BASE_STDLIB_INCLUDE_STDLIB_DETAIL_REMOVE_VOLATILE_HPP_
6
#
define
INCLUDE_GUARD_ARENE_BASE_STDLIB_INCLUDE_STDLIB_DETAIL_REMOVE_VOLATILE_HPP_
7
8
// parasoft-begin-suppress CERT_CPP-DCL58-a-2 "Part of a standard library implementation"
9
// parasoft-begin-suppress AUTOSAR-A17_6_1-a-2 "Part of a standard library implementation"
10
11
// IWYU pragma: private, include <type_traits>
12
// IWYU pragma: friend "stdlib_detail/.*"
13
14
namespace
std
{
15
/// @brief remove @c volatile from the provided type. The @c type member is an alias for the modified type.
16
/// @tparam Type The type to remove @c volatile to
17
template
<
typename
Type>
18
class
remove_volatile
{
19
public
:
20
/// @brief The resulting type
21
using
type = Type;
22
};
23
24
// parasoft-begin-suppress AUTOSAR-A2_11_1-a-2 "volatile used to remove volatile qualifier"
25
/// @brief remove @c volatile from the provided type. The @c type member is an alias for the modified type.
26
/// @tparam Type The type to remove @c volatile to
27
template
<
typename
Type>
28
class
remove_volatile
<Type
volatile
> {
29
public
:
30
/// @brief The resulting type
31
using
type = Type;
32
};
33
// parasoft-end-suppress AUTOSAR-A2_11_1-a-2
34
35
/// @brief remove @c volatile from the provided type. An alias for the modified type.
36
/// @tparam Type The type to remove @c volatile to
37
template
<
typename
Type>
38
using
remove_volatile_t =
typename
remove_volatile
<Type>::type;
39
40
}
// namespace std
41
42
#
endif
// INCLUDE_GUARD_ARENE_BASE_STDLIB_INCLUDE_STDLIB_DETAIL_REMOVE_VOLATILE_HPP_
std::remove_volatile
remove volatile from the provided type. The type member is an alias for the modified type.
Definition
remove_volatile.hpp:18
std::hash<::arene::base::result< void, E > >::operator()
constexpr auto operator()(::arene::base::result< void, E > const &value) const noexcept(noexcept(hash< E >{}(std::declval< E const & >()))) -> std::size_t
Calculate the hash of a result.
Definition
result.hpp:1827
stdlib
include
stdlib_detail
remove_volatile.hpp
Generated by
1.13.2