Update LLVM libraries to 14.0.6 (#4350)

The main noticeable change is the SmallString conversion operator to std::string is now explicit instead of implicit.
This commit is contained in:
Tyler Veness
2022-08-15 05:38:15 -07:00
committed by GitHub
parent c5db23f296
commit 0e0786331a
70 changed files with 1211 additions and 823 deletions

View File

@@ -58,13 +58,13 @@ static std::string GetUsbNameFromFile(int vendor, int product) {
// next vendor, but didn't match product?
if (line[0] != '\t') {
buf += "Unknown";
return buf;
return std::string{buf};
}
// look for product
if (wpi::starts_with(wpi::substr(line, 1), productStr)) {
buf += wpi::trim(wpi::substr(line, 6));
return buf;
return std::string{buf};
}
}
}

View File

@@ -1098,13 +1098,13 @@ std::vector<UsbCameraInfo> EnumerateUsbCameras(CS_Status* status) {
sizeof(buf) / sizeof(WCHAR), &characters);
storage.clear();
wpi::sys::windows::UTF16ToUTF8(buf, characters, storage);
info.name = storage.string();
info.name = std::string{storage};
ppDevices[i]->GetString(
MF_DEVSOURCE_ATTRIBUTE_SOURCE_TYPE_VIDCAP_SYMBOLIC_LINK, buf,
sizeof(buf) / sizeof(WCHAR), &characters);
storage.clear();
wpi::sys::windows::UTF16ToUTF8(buf, characters, storage);
info.path = storage.string();
info.path = std::string{storage};
// Try to parse path from symbolic link
ParseVidAndPid(info.path, &info.productId, &info.vendorId);