mirror of
https://github.com/bsnes-emu/bsnes.git
synced 2025-08-19 11:31:56 +02:00
Update to v106r59 release.
byuu says: Changelog: - fixed bug in Emulator::Game::Memory::operator bool() - nall: renamed view<string> back to `string_view` - nall:: implemented `array_view` - Game Boy: split cartridge-specific input mappings (rumble, accelerometer) to their own separate ports - Game Boy: fixed MBC7 accelerometer x-axis - icarus: Game Boy, Super Famicom, Mega Drive cores output internal header game titles to heuristics manifests - higan, icarus, hiro/gtk: improve viewport geometry configuration; fixed higan crashing bug with XShm driver - higan: connect Video::poll(),update() functionality - hiro, ruby: several compilation / bugfixes, should get the macOS port compiling again, hopefully [Sintendo] - ruby/video/xshm: fix crashing bug on window resize - a bit hacky; it's throwing BadAccess Xlib warnings, but they're not fatal, so I am catching and ignoring them - bsnes: removed Application::Windows::onModalChange hook that's no longer needed [Screwtape]
This commit is contained in:
@@ -9,48 +9,48 @@ auto string::_compare(const char* target, uint capacity, const char* source, uin
|
||||
}
|
||||
|
||||
//size() + 1 includes null-terminator; required to properly compare strings of differing lengths
|
||||
auto string::compare(view<string> x, view<string> y) -> int {
|
||||
auto string::compare(string_view x, string_view y) -> int {
|
||||
return memory::compare(x.data(), x.size() + 1, y.data(), y.size() + 1);
|
||||
}
|
||||
|
||||
auto string::icompare(view<string> x, view<string> y) -> int {
|
||||
auto string::icompare(string_view x, string_view y) -> int {
|
||||
return memory::icompare(x.data(), x.size() + 1, y.data(), y.size() + 1);
|
||||
}
|
||||
|
||||
auto string::compare(view<string> source) const -> int {
|
||||
auto string::compare(string_view source) const -> int {
|
||||
return memory::compare(data(), size() + 1, source.data(), source.size() + 1);
|
||||
}
|
||||
|
||||
auto string::icompare(view<string> source) const -> int {
|
||||
auto string::icompare(string_view source) const -> int {
|
||||
return memory::icompare(data(), size() + 1, source.data(), source.size() + 1);
|
||||
}
|
||||
|
||||
auto string::equals(view<string> source) const -> bool {
|
||||
auto string::equals(string_view source) const -> bool {
|
||||
if(size() != source.size()) return false;
|
||||
return memory::compare(data(), source.data(), source.size()) == 0;
|
||||
}
|
||||
|
||||
auto string::iequals(view<string> source) const -> bool {
|
||||
auto string::iequals(string_view source) const -> bool {
|
||||
if(size() != source.size()) return false;
|
||||
return memory::icompare(data(), source.data(), source.size()) == 0;
|
||||
}
|
||||
|
||||
auto string::beginsWith(view<string> source) const -> bool {
|
||||
auto string::beginsWith(string_view source) const -> bool {
|
||||
if(source.size() > size()) return false;
|
||||
return memory::compare(data(), source.data(), source.size()) == 0;
|
||||
}
|
||||
|
||||
auto string::ibeginsWith(view<string> source) const -> bool {
|
||||
auto string::ibeginsWith(string_view source) const -> bool {
|
||||
if(source.size() > size()) return false;
|
||||
return memory::icompare(data(), source.data(), source.size()) == 0;
|
||||
}
|
||||
|
||||
auto string::endsWith(view<string> source) const -> bool {
|
||||
auto string::endsWith(string_view source) const -> bool {
|
||||
if(source.size() > size()) return false;
|
||||
return memory::compare(data() + size() - source.size(), source.data(), source.size()) == 0;
|
||||
}
|
||||
|
||||
auto string::iendsWith(view<string> source) const -> bool {
|
||||
auto string::iendsWith(string_view source) const -> bool {
|
||||
if(source.size() > size()) return false;
|
||||
return memory::icompare(data() + size() - source.size(), source.data(), source.size()) == 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user