You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
typedefchar Char_t; //Signed Character 1 byte (char)
is incorrect--a bare char is not guaranteed to be signed or unsigned.
char — type for character representation which can be most efficiently processed on the target system (has the same representation and alignment as either signed char or unsigned char, but is always a distinct type). Multibyte characters strings use this type to represent code units. For every value of type unsigned char in range [0, 255], converting the value to char and then back to unsigned char produces the original value.(since C++11) The signedness of char depends on the compiler and the target platform: the defaults for ARM and PowerPC are typically unsigned, the defaults for x86 and x64 are typically signed.
To actually guarantee to be a signed type, Char_t would have to be declared as signed char.
From another issue, it appears ROOT is moving away from Rtypes.h since the C++ standard has a evolved a more complete type system, so this may be a "who cares" issue...
Reproducer
n/a
ROOT version
latest
Installation method
n/a
Operating system
n/a
Additional context
No response
The text was updated successfully, but these errors were encountered:
Check duplicate issues.
Description
The Char_t typedef here:
root/core/foundation/inc/RtypesCore.h
Line 37 in 4cf09dc
is incorrect--a bare
char
is not guaranteed to be signed or unsigned.To actually guarantee to be a signed type,
Char_t
would have to be declared assigned char
.From another issue, it appears ROOT is moving away from Rtypes.h since the C++ standard has a evolved a more complete type system, so this may be a "who cares" issue...
Reproducer
n/a
ROOT version
latest
Installation method
n/a
Operating system
n/a
Additional context
No response
The text was updated successfully, but these errors were encountered: