Skip to content

Commit 8917739

Browse files
[lldb][test] Disable MD5 test for old versions of Visual Studio (#94325)
In older versions there is this problem: https://developercommunity.visualstudio.com/t/c-shared-state-futuresstate-default-constructs-the/60897 Which prevents us making a future out of a result type. There's no good workaround so just don't compile this for older versions.
1 parent 31850fa commit 8917739

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -593,6 +593,10 @@ TEST_F(GDBRemoteCommunicationClientTest, WriteMemoryTags) {
593593
"E03", false);
594594
}
595595

596+
// Prior to this verison, constructing a std::future for a type without a
597+
// default constructor is not possible.
598+
// https://developercommunity.visualstudio.com/t/c-shared-state-futuresstate-default-constructs-the/60897
599+
#if !defined(_MSC_VER) || _MSC_VER >= 1932
596600
TEST_F(GDBRemoteCommunicationClientTest, CalculateMD5) {
597601
FileSpec file_spec("/foo/bar", FileSpec::Style::posix);
598602
std::future<ErrorOr<MD5::MD5Result>> async_result = std::async(
@@ -614,3 +618,4 @@ TEST_F(GDBRemoteCommunicationClientTest, CalculateMD5) {
614618
EXPECT_EQ(expected_low, result->low());
615619
EXPECT_EQ(expected_high, result->high());
616620
}
621+
#endif

0 commit comments

Comments
 (0)