[PATCH] D69230: RFC: specialized Optional<T> for T that can represent its own invalid state
Lawrence D'Anna via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 21 13:26:55 PDT 2019
lawrence_danna updated this revision to Diff 225946.
lawrence_danna added a comment.
moved MakeInvalid and IsValid into the trait struct.
I think this is a lot more type correct, as someone would really
have to go out of their way to misuse the trait struct and make an
invalid T instead of using Optional.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D69230/new/
https://reviews.llvm.org/D69230
Files:
llvm/include/llvm/ADT/Optional.h
llvm/unittests/ADT/OptionalTest.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D69230.225946.patch
Type: text/x-patch
Size: 3995 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191021/33079ea5/attachment.bin>
More information about the llvm-commits
mailing list