[libcxx-commits] [PATCH] D133661: [libc++] Improve binary size when using __transaction
Louis Dionne via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Thu Nov 24 06:54:09 PST 2022
ldionne requested changes to this revision.
ldionne added inline comments.
This revision now requires changes to proceed.
================
Comment at: libcxx/include/__utility/exception_guard.h:106
+ _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20 _LIBCPP_NODEBUG ~__exception_guard() {
+ _LIBCPP_ASSERT(__completed_, "__exception_guard not completed with exceptions disabled")
+ }
----------------
================
Comment at: libcxx/test/libcxx/utilities/exception_guard.pass.cpp:26
}
+#ifdef TEST_HAS_NO_EXCEPTIONS
+ assert(!rolled_back);
----------------
This doesn't make sense to me. I think this whole test case doesn't make sense when exceptions are disabled. For example, this would fail when exceptions are disabled and assertions are enabled.
================
Comment at: libcxx/test/libcxx/utilities/exception_guard.pass.cpp:56
}
+#ifdef TEST_HAS_NO_EXCEPTIONS
+ assert(rollbacks == 0);
----------------
Same here, this test case doesn't make sense when exceptions are disabled.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D133661/new/
https://reviews.llvm.org/D133661
More information about the libcxx-commits
mailing list