You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In windows using Visual Studio clang compiler I get errors for stl code (within the namespace std). The cl compiler that is default in visual studio works but not clang.
Clang can compile in in linux. I think that there is some issue where a header do some specific conditional compilation for windows and maybe have set how to do it based on compiler. It could be that this isn't tested because most use cl compiler in windows?
Sample code from crow, errors are in comments on each line and this is the file ci_map.h.
#pragma once
#include<boost/algorithm/string/predicate.hpp>
#include<boost/functional/hash.hpp>
#include<unordered_map>namespacecrow
{
/// Hashing function for ci_map (unordered_multimap).structci_hash
{
size_toperator()(const std::string& key) const// error = error : no type named 'string' in namespace 'crow::std'; did you mean '::std::string'?
{
std::size_t seed = 0; // error = no type named 'size_t' in namespace 'crow::std'; did you mean simply 'size_t'?
std::locale locale; // error = no type named 'locale' in namespace 'crow::std'; did you mean '::std::locale'?for (auto c : key)
{
boost::hash_combine(seed, std::toupper(c, locale)); // error = no member named 'toupper' in namespace 'crow::std'
}
return seed;
}
};
/// Equals function for ci_map (unordered_multimap).structci_key_eq
{
booloperator()(const std::string& l, const std::string& r) const// error = no type named 'string' in namespace 'crow::std'; did you mean '::std::string'?
{
returnboost::iequals(l, r);
}
};
using ci_map = std::unordered_multimap<std::string, std::string, ci_hash, ci_key_eq>; // error = no template named 'unordered_multimap' in namespace 'crow::std'; did you mean '::std::unordered_multimap'?
} // namespace crow
The text was updated successfully, but these errors were encountered:
In windows using Visual Studio clang compiler I get errors for stl code (within the namespace
std
). Thecl
compiler that is default in visual studio works but notclang
.Clang can compile in in linux. I think that there is some issue where a header do some specific conditional compilation for windows and maybe have set how to do it based on compiler. It could be that this isn't tested because most use cl compiler in windows?
Sample code from crow, errors are in comments on each line and this is the file
ci_map.h
.The text was updated successfully, but these errors were encountered: