[except.nested]

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@104850 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/src/exception.cpp b/src/exception.cpp
index e48e9c4..9bed6f4 100644
--- a/src/exception.cpp
+++ b/src/exception.cpp
@@ -142,6 +142,23 @@
 #endif
 }
 
+nested_exception::nested_exception()
+    : __ptr_(current_exception())
+{
+}
+
+nested_exception::~nested_exception()
+{
+}
+
+void
+nested_exception::rethrow_nested /*[[noreturn]]*/ () const
+{
+    if (__ptr_ == nullptr)
+        terminate();
+    rethrow_exception(__ptr_);
+}
+
 } // std