// Copyright (c) the JPEG XL Project Authors. All rights reserved. // // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file.
// Reverse to PackSigned, i.e. UnpackSigned(PackSigned(X)) == X. // (((~value) & 1) - 1) is either 0 or 0xFF...FF and it will have an expected // unsigned-integer-overflow.
constexpr intptr_t UnpackSigned(size_t value)
JXL_NO_SANITIZE("unsigned-integer-overflow") { returnstatic_cast<intptr_t>((value >> 1) ^ (((~value) & 1) - 1));
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.