Skip to content

Commit

Permalink
Include stdbool.h in API headers
Browse files Browse the repository at this point in the history
* `zer_api.h` makes use of `bool`. `zer_api.h` is a C header and in C
  the `bool` type is defined in `stdbool.h`, hence we should include
  `zer_api.h` in the API header.
  • Loading branch information
FranklandJack committed Nov 22, 2022
1 parent 624a379 commit 9c103cf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions include/zer_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
// standard headers
#include <stdint.h>
#include <stddef.h>
#include <stdbool.h>

#if defined(__cplusplus)
extern "C" {
Expand Down
1 change: 1 addition & 0 deletions scripts/templates/api.h.mako
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ from templates import helper as th
// standard headers
#include <stdint.h>
#include <stddef.h>
#include <stdbool.h>
%endif

#if defined(__cplusplus)
Expand Down

0 comments on commit 9c103cf

Please sign in to comment.