Skip to content

Commit e975dcd

Browse files
try a different fix for test on Windows
Created using spr 1.3.6
2 parents a7399fd + cbfc22c commit e975dcd

File tree

4 files changed

+12
-22
lines changed

4 files changed

+12
-22
lines changed

clang/lib/Headers/hlsl/hlsl_alias_intrinsics.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2190,10 +2190,10 @@ float4 sqrt(float4);
21902190
// step builtins
21912191
//===----------------------------------------------------------------------===//
21922192

2193-
/// \fn T step(T x, T y)
2193+
/// \fn T step(T y, T x)
21942194
/// \brief Returns 1 if the x parameter is greater than or equal to the y
2195-
/// parameter; otherwise, 0. vector. \param x [in] The first floating-point
2196-
/// value to compare. \param y [in] The first floating-point value to compare.
2195+
/// parameter; otherwise, 0. vector. \param y [in] The first floating-point
2196+
/// value to compare. \param x [in] The second floating-point value to compare.
21972197
///
21982198
/// Step is based on the following formula: (x >= y) ? 1 : 0
21992199

lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -98,17 +98,7 @@ struct InitializePythonRAII {
9898
#ifdef LLDB_USE_LIBEDIT_READLINE_COMPAT_MODULE
9999
// Python's readline is incompatible with libedit being linked into lldb.
100100
// Provide a patched version local to the embedded interpreter.
101-
bool ReadlinePatched = false;
102-
for (auto *p = PyImport_Inittab; p->name != nullptr; p++) {
103-
if (strcmp(p->name, "readline") == 0) {
104-
p->initfunc = initlldb_readline;
105-
break;
106-
}
107-
}
108-
if (!ReadlinePatched) {
109-
PyImport_AppendInittab("readline", initlldb_readline);
110-
ReadlinePatched = true;
111-
}
101+
PyImport_AppendInittab("readline", initlldb_readline);
112102
#endif
113103

114104
// Register _lldb as a built-in module.

llvm/lib/Transforms/Scalar/JumpTableToSwitch.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,9 +149,8 @@ expandToSwitch(CallBase *CB, const JumpTableTy &JT, DomTreeUpdater &DTU,
149149
std::numeric_limits<uint32_t>::max(), TotalCount);
150150

151151
for (const auto &[G, C] : Targets) {
152-
auto It = GuidToCounter.insert({G, C});
152+
[[maybe_unused]] auto It = GuidToCounter.insert({G, C});
153153
assert(It.second);
154-
(void)It;
155154
}
156155
}
157156
for (auto [Index, Func] : llvm::enumerate(JT.Funcs)) {

llvm/unittests/Support/Path.cpp

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1473,7 +1473,9 @@ TEST_F(FileSystemTest, FileMapping) {
14731473

14741474
TEST_F(FileSystemTest, FileMappingSync) {
14751475
// Create a temp file.
1476-
auto TempFileOrError = fs::TempFile::create(TestDirectory + "/test-%%%%");
1476+
SmallString<0> TempPath(TestDirectory);
1477+
sys::path::append(TempPath, "test-%%%%");
1478+
auto TempFileOrError = fs::TempFile::create(TempPath);
14771479
ASSERT_TRUE((bool)TempFileOrError);
14781480
fs::TempFile File = std::move(*TempFileOrError);
14791481
StringRef Content("hello there");
@@ -1488,13 +1490,12 @@ TEST_F(FileSystemTest, FileMappingSync) {
14881490
ASSERT_NO_ERROR(EC);
14891491
std::copy(Content.begin(), Content.end(), MFR.data());
14901492

1491-
// Synchronize.
1493+
// Synchronize and check the contents before unmapping.
14921494
MFR.sync();
1495+
auto Buffer = MemoryBuffer::getFile(File.TmpName);
1496+
ASSERT_TRUE((bool)Buffer);
1497+
ASSERT_EQ(Content, Buffer->get()->getBuffer());
14931498
}
1494-
1495-
auto Buffer = MemoryBuffer::getFile(File.TmpName);
1496-
ASSERT_TRUE((bool)Buffer);
1497-
ASSERT_EQ(Content, Buffer->get()->getBuffer());
14981499
ASSERT_FALSE((bool)File.discard());
14991500
}
15001501

0 commit comments

Comments
 (0)