From a4d9a63d710eff5251bd2a455ccdba30183ed97d Mon Sep 17 00:00:00 2001 From: Ed_ Date: Mon, 28 Aug 2023 23:52:44 -0400 Subject: [PATCH] Updated single-header based on last cs and also docs --- singleheader/Readme.md | 6 ++---- singleheader/singleheader.cpp | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/singleheader/Readme.md b/singleheader/Readme.md index 7cfb66c..aa7f724 100644 --- a/singleheader/Readme.md +++ b/singleheader/Readme.md @@ -1,6 +1,4 @@ # Singleheader -`gen.singleheader.cpp` with its own `meson.build` generates the library as a single header `gen.hpp`. -Following the same convention seen in the gb, stb, and zpl libraries. - -( Currently WIP ) +Creates a single header file version of the library using `gen.singleheader.cpp`. +Follows the same convention seen in the gb, stb, and zpl libraries. diff --git a/singleheader/singleheader.cpp b/singleheader/singleheader.cpp index f79c017..ee7ed73 100644 --- a/singleheader/singleheader.cpp +++ b/singleheader/singleheader.cpp @@ -48,8 +48,6 @@ global bool generate_builder = true; global bool generate_editor = true; global bool generate_scanner = true; -constexpr bool DontSkipInitialDirectives = false; - int gen_main() { #define project_dir "../project/" @@ -57,7 +55,7 @@ int gen_main() Code push_ignores = scan_file( project_dir "helpers/push_ignores.inline.hpp" ); Code pop_ignores = scan_file( project_dir "helpers/pop_ignores.inline.hpp" ); - Code single_header_start = scan_file( "components/header_start.hpp", DontSkipInitialDirectives ); + Code single_header_start = scan_file( "components/header_start.hpp" ); Builder header = Builder::open( "gen/gen.hpp" ); @@ -71,7 +69,7 @@ int gen_main() if ( generate_gen_dep ) { - Code header_start = scan_file( project_dir "dependencies/header_start.hpp", DontSkipInitialDirectives ); + Code header_start = scan_file( project_dir "dependencies/header_start.hpp" ); Code macros = scan_file( project_dir "dependencies/macros.hpp" ); Code basic_types = scan_file( project_dir "dependencies/basic_types.hpp" ); Code debug = scan_file( project_dir "dependencies/debug.hpp" );