diff --git a/lang/cpp20/constinit.md b/lang/cpp20/constinit.md index 8d9a370fab..343186f49a 100644 --- a/lang/cpp20/constinit.md +++ b/lang/cpp20/constinit.md @@ -196,6 +196,9 @@ int main() {} ## 関連項目 - [C++11 `constexpr`](/lang/cpp11/constexpr.md) +- [`mutex`のコンストラクタ](/reference/mutex/mutex/op_constructor.md) +- [`unique_ptr`のコンストラクタ](/reference/memory/unique_ptr/op_constructor.md) + ## 参照 diff --git a/reference/memory/unique_ptr/op_constructor.md b/reference/memory/unique_ptr/op_constructor.md index 6a6820ebf0..58e858b2a9 100644 --- a/reference/memory/unique_ptr/op_constructor.md +++ b/reference/memory/unique_ptr/op_constructor.md @@ -167,6 +167,10 @@ int main() - 2012までは、delete宣言に対応していないため、代わりにprivateで宣言のみ行う手法で代用されている。 +## 関連項目 +- [C++20 コンパイル時初期化を強制する`constinit`キーワードを追加](/lang/cpp20/constinit.md) + + ## 参照 - [N2435 Explicit bool for Smart Pointers](http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2435.htm) - (6)の経緯となる提案文書 diff --git a/reference/mutex/mutex/op_constructor.md b/reference/mutex/mutex/op_constructor.md index 5067466c2b..a725c6695e 100644 --- a/reference/mutex/mutex/op_constructor.md +++ b/reference/mutex/mutex/op_constructor.md @@ -10,7 +10,7 @@ constexpr mutex() noexcept; // (1) mutex(const mutex&) = delete; // (2) ``` -## mutexオブジェクトの構築 +## 概要 - (1) : デフォルトコンストラクタ。`mutex`オブジェクトの初期化を行う。 - (2) : コピーコンストラクタ。コピー不可。 @@ -106,6 +106,10 @@ A - 2012はコピーコンストラクタのdeleteに対応していないため、代わりにprivateで宣言のみ行う手法で代用されている。 +## 関連項目 +- [C++20 コンパイル時初期化を強制する`constinit`キーワードを追加](/lang/cpp20/constinit.md) + + ## 参照 - [Constant Initialization - 雑貨's tumblr](https://zakkas783-blog-blog.tumblr.com/post/25490513807/constant-initialization) - [mutexのconstexprコンストラクタ - yohhoyの日記](http://d.hatena.ne.jp/yohhoy/20120621/p1)