mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-17 13:07:54 +02:00
util: Make ToLower and ToUpper take a char
Unfortunately, `std::string` elements are (bare) chars. As these are the most likely type to be passed to these functions, make them use char instead of unsigned char. This avoids some casts.
This commit is contained in:
parent
edb5bb3500
commit
332b3dd7c1
4 changed files with 6 additions and 6 deletions
|
|
@ -33,7 +33,7 @@ void base_blob<BITS>::SetHex(const char* psz)
|
|||
psz++;
|
||||
|
||||
// skip 0x
|
||||
if (psz[0] == '0' && ToLower((unsigned char)psz[1]) == 'x')
|
||||
if (psz[0] == '0' && ToLower(psz[1]) == 'x')
|
||||
psz += 2;
|
||||
|
||||
// hex string to uint
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue