Changeset View
Changeset View
Standalone View
Standalone View
docs/ReleaseNotes.rst
Show First 20 Lines • Show All 75 Lines • ▼ Show 20 Lines | |||||
- ``-Wtautological-compare`` now warns about comparing a signed integer and 0 | - ``-Wtautological-compare`` now warns about comparing a signed integer and 0 | ||||
when the signed integer is coerced to an unsigned type for the comparison. | when the signed integer is coerced to an unsigned type for the comparison. | ||||
``-Wsign-compare`` was adjusted not to warn in this case. | ``-Wsign-compare`` was adjusted not to warn in this case. | ||||
- ``-Wtautological-constant-compare`` is a new warning that warns on | - ``-Wtautological-constant-compare`` is a new warning that warns on | ||||
tautological comparisons between integer variable of the type ``T`` and the | tautological comparisons between integer variable of the type ``T`` and the | ||||
largest/smallest possible integer constant of that same type. | largest/smallest possible integer constant of that same type. | ||||
If the tautologicalness of the comparison is data model dependent, then the | |||||
``-Wmaybe-tautological-constant-compare`` (disabled by default) is used. | |||||
- For C code, ``-Wsign-compare``, ``-Wsign-conversion``, | - For C code, ``-Wsign-compare``, ``-Wsign-conversion``, | ||||
``-Wtautological-constant-compare`` and | ``-Wtautological-constant-compare`` and | ||||
``-Wtautological-constant-out-of-range-compare`` were adjusted to use the | ``-Wtautological-constant-out-of-range-compare`` were adjusted to use the | ||||
underlying datatype of ``enum``. | underlying datatype of ``enum``. | ||||
- ``-Wnull-pointer-arithmetic`` now warns about performing pointer arithmetic | - ``-Wnull-pointer-arithmetic`` now warns about performing pointer arithmetic | ||||
on a null pointer. Such pointer arithmetic has an undefined behavior if the | on a null pointer. Such pointer arithmetic has an undefined behavior if the | ||||
▲ Show 20 Lines • Show All 211 Lines • Show Last 20 Lines |