std::experimental:: erased_type
From cppreference.net
<
cpp
|
experimental
C++
Experimental
| Technical Specification | ||||
| Filesystem library (filesystem TS) | ||||
| Library fundamentals (library fundamentals TS) | ||||
| Library fundamentals 2 (library fundamentals TS v2) | ||||
| Library fundamentals 3 (library fundamentals TS v3) | ||||
| Extensions for parallelism (parallelism TS) | ||||
| Extensions for parallelism 2 (parallelism TS v2) | ||||
| Extensions for concurrency (concurrency TS) | ||||
| Extensions for concurrency 2 (concurrency TS v2) | ||||
| Concepts (concepts TS) | ||||
| Ranges (ranges TS) | ||||
| Reflection (reflection TS) | ||||
| Mathematical special functions (special functions TR) | ||||
| Experimental Non-TS | ||||
| Pattern Matching | ||||
| Linear Algebra | ||||
| std::execution | ||||
| Contracts | ||||
| 2D Graphics |
|
ヘッダーで定義
<experimental/utility>
|
||
|
struct
erased_type
{
}
;
|
(ライブラリ基盤 TS)
(ライブラリ基盤 TS v3 で削除) |
|
erased_type
クラスは、実際の型が実行時に決定される状況で型のプレースホルダーとして機能する空の構造体です。例えば、
type-erased allocator
を使用するクラスでは、ネストされたtypedef
allocator_type
は
erased_type
のエイリアスとして定義されます。
注記
erased_type
はLFTS v3で削除されました。なぜなら
std::
pmr
::
polymorphic_allocator
<>
が型消去により適しているためです。