History log of /src/include/stdckdint.h (Results 1 – 6 of 6)
Revision Date Author Comments
# 3c052bec 17-Oct-2025 Konstantin Belousov <kib@FreeBSD.org>

include/stdckdint.h: make the header compatible with C++

by removing the cast to _Bool. The _Bool type is not defined for C++,
and the specification from the gcc info doc states that the return
typ

include/stdckdint.h: make the header compatible with C++

by removing the cast to _Bool. The _Bool type is not defined for C++,
and the specification from the gcc info doc states that the return
type of the __builtin_{add,sub,mul}_overflow() is bool already.

This is done instead of including stdbool.h to avoid namespace
pollution, since defining bool from stdckdint.h simingly is not
sanctioned by ISO/IEC 9899:2024.

PR: 290299
Reviewed by: des
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D53149

show more ...


# e6615b10 07-Sep-2023 Dag-Erling Smørgrav <des@FreeBSD.org>

include: Implement N2867.

This adds macros for checked addition, subtraction, and multiplication with semantics similar to the builtins gcc and clang have had for years.

Reviewed by: kib, emaste
Di

include: Implement N2867.

This adds macros for checked addition, subtraction, and multiplication with semantics similar to the builtins gcc and clang have had for years.

Reviewed by: kib, emaste
Differential Revision: https://reviews.freebsd.org/D41734

show more ...


# 3c052bec 17-Oct-2025 Konstantin Belousov <kib@FreeBSD.org>

include/stdckdint.h: make the header compatible with C++

by removing the cast to _Bool. The _Bool type is not defined for C++,
and the specification from the gcc info doc states that the return
typ

include/stdckdint.h: make the header compatible with C++

by removing the cast to _Bool. The _Bool type is not defined for C++,
and the specification from the gcc info doc states that the return
type of the __builtin_{add,sub,mul}_overflow() is bool already.

This is done instead of including stdbool.h to avoid namespace
pollution, since defining bool from stdckdint.h simingly is not
sanctioned by ISO/IEC 9899:2024.

PR: 290299
Reviewed by: des
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D53149

show more ...


# e6615b10 07-Sep-2023 Dag-Erling Smørgrav <des@FreeBSD.org>

include: Implement N2867.

This adds macros for checked addition, subtraction, and multiplication with semantics similar to the builtins gcc and clang have had for years.

Reviewed by: kib, emaste
Di

include: Implement N2867.

This adds macros for checked addition, subtraction, and multiplication with semantics similar to the builtins gcc and clang have had for years.

Reviewed by: kib, emaste
Differential Revision: https://reviews.freebsd.org/D41734

show more ...


# 3c052bec 17-Oct-2025 Konstantin Belousov <kib@FreeBSD.org>

include/stdckdint.h: make the header compatible with C++

by removing the cast to _Bool. The _Bool type is not defined for C++,
and the specification from the gcc info doc states that the return
typ

include/stdckdint.h: make the header compatible with C++

by removing the cast to _Bool. The _Bool type is not defined for C++,
and the specification from the gcc info doc states that the return
type of the __builtin_{add,sub,mul}_overflow() is bool already.

This is done instead of including stdbool.h to avoid namespace
pollution, since defining bool from stdckdint.h simingly is not
sanctioned by ISO/IEC 9899:2024.

PR: 290299
Reviewed by: des
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D53149

show more ...


# e6615b10 07-Sep-2023 Dag-Erling Smørgrav <des@FreeBSD.org>

include: Implement N2867.

This adds macros for checked addition, subtraction, and multiplication with semantics similar to the builtins gcc and clang have had for years.

Reviewed by: kib, emaste
Di

include: Implement N2867.

This adds macros for checked addition, subtraction, and multiplication with semantics similar to the builtins gcc and clang have had for years.

Reviewed by: kib, emaste
Differential Revision: https://reviews.freebsd.org/D41734

show more ...