Removed unneeded 'using uchar = unsigned char'

This commit is contained in:
Daniel Griscom 2020-01-20 21:41:08 -05:00 committed by Martin Hořeňovský
parent 32617f42d0
commit ab520f4e97
No known key found for this signature in database
GPG Key ID: DE48307B8B0D381A

View File

@ -12,8 +12,6 @@
#include <iomanip> #include <iomanip>
#include <type_traits> #include <type_traits>
using uchar = unsigned char;
namespace Catch { namespace Catch {
namespace { namespace {
@ -87,7 +85,7 @@ namespace {
// (see: http://www.w3.org/TR/xml/#syntax) // (see: http://www.w3.org/TR/xml/#syntax)
for( std::size_t idx = 0; idx < m_str.size(); ++ idx ) { for( std::size_t idx = 0; idx < m_str.size(); ++ idx ) {
uchar c = m_str[idx]; unsigned char c = m_str[idx];
switch (c) { switch (c) {
case '<': os << "&lt;"; break; case '<': os << "&lt;"; break;
case '&': os << "&amp;"; break; case '&': os << "&amp;"; break;
@ -147,7 +145,7 @@ namespace {
bool valid = true; bool valid = true;
uint32_t value = headerValue(c); uint32_t value = headerValue(c);
for (std::size_t n = 1; n < encBytes; ++n) { for (std::size_t n = 1; n < encBytes; ++n) {
uchar nc = m_str[idx + n]; unsigned char nc = m_str[idx + n];
valid &= ((nc & 0xC0) == 0x80); valid &= ((nc & 0xC0) == 0x80);
value = (value << 6) | (nc & 0x3F); value = (value << 6) | (nc & 0x3F);
} }