Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(93)

Unified Diff: docs/optional.md

Issue 2080003002: base::Optional: Use anonymous union instead of base::AlignedMemory (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: docs/optional.md
diff --git a/docs/optional.md b/docs/optional.md
index a2220316ab36ee2976312ebfbc9bbf4339de0e96..7ee15d7b9064e796086342202d1b59513ecb1cf1 100644
--- a/docs/optional.md
+++ b/docs/optional.md
@@ -76,7 +76,7 @@ Finally, `base::Optional<T>` is integrated with `std::hash`, using
## How is it implemented?
-`base::Optional<T>` is implemented using `base::AlignedMemory`. The object
+`base::Optional<T>` is implemented with a union with a `T` member. The object
doesn't behave like a pointer and doesn't do dynamic memory allocation. In
other words, it is guaranteed to have an object allocated when it is not empty.
« base/optional.h ('K') | « base/optional.h ('k') | styleguide/c++/c++11.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698