diff options
author | thenewone <thenewone@yandex-team.com> | 2024-11-12 12:02:01 +0300 |
---|---|---|
committer | thenewone <thenewone@yandex-team.com> | 2024-11-12 12:15:18 +0300 |
commit | b218405128bf0cd7ef71718461548565db698398 (patch) | |
tree | 46f74d986b39a4db0ac93b64ac9e74b541600302 /build/platform/yfm | |
parent | 2c567f233fc0c2c2d051051acd04bd0c558e382b (diff) | |
download | ydb-b218405128bf0cd7ef71718461548565db698398.tar.gz |
YT-23346: Introduce YT_ASSUME and YT_UNREACHABLE macros.
Y_ASSUME and Y_UNREACHABLE macros are platform-independent ways to
give a hint for a compiler about some value or state. Compilier may
use that hint for optimization. On the other hand if the hint is
wrong it may lead to undefined behavior.
YT_ASSUME and YT_UNREACHABLE are wrappers around Y_ASSUME and
Y_UNREACHABLE that actually check that the hint is correct in
debug build. That introduces some code safety and at the same time
allows certain optimization in optimized build.
commit_hash:2d0969361910a10a870bae226d838d494e656edb
Diffstat (limited to 'build/platform/yfm')
0 files changed, 0 insertions, 0 deletions