Compare commits

..

No commits in common. "7f990b161b2e38d436f5ebc66c3e63f36af2d5ac" and "105ed79f8f0a89fbc4791e8ef7136c36a9b101a8" have entirely different histories.

2 changed files with 3 additions and 6 deletions

View File

@ -81,8 +81,7 @@ extern "C"
a++;
b++;
}
static_assert(sizeof(wchar_t) == sizeof(u32));
return *(const u32*)a - *(const u32*)b;
return *(const u8*)a - *(const u8*)b;
}
int strncmp(const char* a, const char* b, usize max)

View File

@ -50,14 +50,12 @@ const char& StringView::operator[](usize index) const
bool StringView::operator==(const char* other) const
{
if (m_length != strlen(other)) return false;
return !strncmp(m_string, other, m_length);
return !strcmp(m_string, other);
}
bool StringView::operator==(StringView other) const
{
if (m_length != other.m_length) return false;
return !strncmp(m_string, other.m_string, m_length);
return !strcmp(m_string, other.m_string);
}
Result<Vector<String>> StringView::split(StringView delim) const