Skip to content

Commit

Permalink
Simplify return values (#114)
Browse files Browse the repository at this point in the history
Introduce bk_err and bk_bool rather than using int for both of these.
This means that the function definition now specifies whether 0 means
no error, or whether it means false.
  • Loading branch information
bkthomps authored Aug 17, 2020
1 parent 724c0e5 commit e3bc872
Show file tree
Hide file tree
Showing 53 changed files with 904 additions and 884 deletions.
6 changes: 5 additions & 1 deletion compile_headers.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@
for filename in sorted(glob.glob(os.path.join(folder_path, '*.h'))):
with open(filename, 'r') as file:
text = file.read()
header += text.split("*/", 1)[1]
entire_file = text.split("*/", 1)[1]
split_around_include = entire_file.split('#include "all.h"\n\n', 1)
header += split_around_include[0]
if len(split_around_include) == 2:
header += split_around_include[1]

containers_header_file = open("containers.h", "w+")
containers_header_file.write(header)
Expand Down
Loading

0 comments on commit e3bc872

Please sign in to comment.