diff --git a/include/llvm/ADT/Optional.h b/include/llvm/ADT/Optional.h index ae8344da76a..cb45c78e2c1 100644 --- a/include/llvm/ADT/Optional.h +++ b/include/llvm/ADT/Optional.h @@ -29,6 +29,8 @@ class Optional { AlignedCharArrayUnion storage; bool hasVal; public: + typedef T value_type; + Optional(NoneType) : hasVal(false) {} explicit Optional() : hasVal(false) {} Optional(const T &y) : hasVal(true) {