sd-json: don't use C99 bool in public headers
authorLennart Poettering <lennart@poettering.net>
Wed, 30 Oct 2024 20:55:13 +0000 (21:55 +0100)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 30 Oct 2024 22:59:41 +0000 (07:59 +0900)
commit2ff3adeb2992ba59080d153db29ab48aa5bf7e58
treefc20731e4354fbbf45874779a4abeb14b1d929f8
parentcb15aa7b37f0daa4ad8d6f31f1ffa933343821c6
sd-json: don't use C99 bool in public headers

All our public headers strive to C90 compatibility with a few
extensions, and thus avoided stdbool.h and bool.

The sd_json_format_enabled() helper seems like a poor place to start
requiring stdbool.h now.

Also drop __extension__ since we are not using it anywhere else in very
similar inline functions.

(And we probably should drop any _sd_const declarations on inline
functions. Given that the compiler has the function implementation
around always, because it's in the header there's really no reason to
specify this manually, the compiler can trivially figure this out on its
own. But that's for another time.)
src/systemd/sd-json.h
src/systemd/sd-varlink-idl.h