Warning C4090: different '__unaligned' qualifiers when using std::unique_ptr
This code:
bool CShell::moveItemsToTrash(std::vector<std::wstring> items)
{
auto ILFreeDeallocator = [](ITEMIDLIST * p) { ILFree(p); };
typedef std::unique_ptr<ITEMIDLIST, decltype(ILFreeDeallocator)>
CItemIdLIstPtr;
std::vector<CItemIdLIstPtr> idLists;
for (auto& path: items)
{
idLists.emplace_back(CItemIdLIstPtr(ILCreateFromPath(path.c_str()),
ILFreeDeallocator));
}
return true;
}
results in C4090: different '__unaligned' qualifiers on the line where
pointer is created and added to a vector. Why is that and what does this
mean? Should I be concerned?
No comments:
Post a Comment