mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-04-28 21:07:59 +03:00
Fixed issue with getSummonedCreature( that returned a reference to a non const static value
Fix compile, and apply review comment Fixed greater vs more typo. getCellname is back to a string view. Because in most cases was used as a strong not a refId. and there was a fundamental issue with region names used as a cellname
This commit is contained in:
parent
1ef1de974d
commit
dc21df97c8
17 changed files with 57 additions and 43 deletions
|
@ -20,14 +20,14 @@ namespace Misc::StringUtils
|
|||
return std::lexicographical_compare(x.begin(), x.end(), y.begin(), y.end(), CiCharLess());
|
||||
}
|
||||
|
||||
struct CiCharMore
|
||||
struct CiCharGreater
|
||||
{
|
||||
bool operator()(char x, char y) const { return toLower(x) > toLower(y); }
|
||||
};
|
||||
|
||||
inline bool ciMore(std::string_view x, std::string_view y)
|
||||
inline bool ciGreater(std::string_view x, std::string_view y)
|
||||
{
|
||||
return std::lexicographical_compare(x.begin(), x.end(), y.begin(), y.end(), CiCharMore());
|
||||
return std::lexicographical_compare(x.begin(), x.end(), y.begin(), y.end(), CiCharGreater());
|
||||
}
|
||||
|
||||
inline bool ciEqual(std::string_view x, std::string_view y)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue