From 1ef526c695df4b37aa184867fb5b62c93118aa02 Mon Sep 17 00:00:00 2001 From: Joel Kronqvist Date: Sun, 24 Mar 2024 10:00:19 +0200 Subject: Refactored configuration parsing to a separate file and added unit tests to it --- config-parser.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 config-parser.h (limited to 'config-parser.h') diff --git a/config-parser.h b/config-parser.h new file mode 100644 index 0000000..1026a98 --- /dev/null +++ b/config-parser.h @@ -0,0 +1,12 @@ + +struct Config { + int precision; + bool human_readable; +}; +typedef struct Config Config; +struct Result { + bool success; + void* result; +}; +typedef struct Result Result; +Result/*Config*/ parse_config(int argc, char* argv[]); -- cgit v1.2.3