[ADT] Split optional to only include copy mechanics and dtor for non-trivial types.
authorBenjamin Kramer <benny.kra@googlemail.com>
Tue, 31 Oct 2017 18:35:54 +0000 (18:35 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Tue, 31 Oct 2017 18:35:54 +0000 (18:35 +0000)
commit5168f257d5b93e39eb983481ef8e190f49384968
tree0027485c06408f21aa2412f76996d740a2876483
parent2d2798b3a7de613740124efe3925d4e464a986a6
[ADT] Split optional to only include copy mechanics and dtor for non-trivial types.

This makes uses of Optional more transparent to the compiler (and
clang-tidy) and generates slightly smaller code.

llvm-svn: 317019
llvm/include/llvm/ADT/Optional.h
llvm/unittests/ADT/OptionalTest.cpp