We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent afee388 commit 94e04bfCopy full SHA for 94e04bf
lang/cpp26/erroneous_behavior_for_uninitialized_reads.md
@@ -128,11 +128,13 @@ int main() {
128
- 以下のようなケースでは、erroneous behaviorではなく未定義動作を引き起こす可能性がある:
129
```cpp
130
T* p; // 未初期化のポインタ。erroneous value (例としてヌルポインタ) をもつ
131
- bool b; // 未初期化の真理値。erroneous valueとして、
132
- // 妥当ではないbool値 (trueでもfalseでもない値) をもつ可能性がある
+ bool b; // 未初期化の真理値。
+ // bool値として妥当な値表現をもたない可能性がある
133
+ // (例: 値表現が8bitで{0x00(false), 0x01(true)}の
134
+ // 2通りのみとする処理系で0xCCをもつなど)
135
136
f(*p); // 間接参照は未定義動作を引き起こす
- g(b); // bが妥当な値である場合にerroneous behavior、そうでなければ未定義動作
137
+ g(b); // bが妥当な値表現をもつ場合にerroneous behavior、そうでなければ未定義動作
138
```
139
140
0 commit comments