Commit Graph

22 Commits

Author SHA1 Message Date
ec13264050 feat(reflect-cpp): Switched from glaze -> reflect cpp
A bug was discovered in glaze which prevented valid toml output. We have
switched to toml++ and reflect-cpp. The interface has remained the same
so this should not break any code
2025-12-06 10:55:46 -05:00
05b7b94c83 feat(TOML & Glaze): YAML -> TOML
YAML is a horrid format with far too many edge cases. We have switched
to TOML. Further, we have completly reworked the framework so that

1. There is no longer any global config state. Config objects now must
be passed between scopes by the caller. This will introduce some more
friction but whill also make order of initialization clear
2. Config objects are now strongly typed and there is a single sourth of
truth for any given config object baked in using the some struct.
2025-12-05 14:26:22 -05:00
07f1e8d7d7 fix(headers): moved all headers to fourdst/ 2025-06-22 04:52:04 -04:00
fa6209e8f3 feat(headers): moved 2025-06-21 16:17:34 -04:00
9a7dd54099 feat(headers): update header install paths 2025-06-21 16:12:21 -04:00
698e8d2e07 build(libconfig): got build system and tests working 2025-06-21 08:41:39 -04:00
af5df1d452 refactor(serif): fixed typos and updated names to reflect 4DSSE->SERiF 2025-06-12 09:04:03 -04:00
e5b3936024 Merge remote-tracking branch 'upstream/main' into feature/mixedPolytrope
# Conflicts:
#	.gitignore
#	build-config/meson.build
#	meson.build
#	meson_options.txt
#	src/composition/public/composition.h
#	src/config/public/config.h
#	src/constants/public/const.h
#	src/meson.build
#	tests/composition_sandbox/comp.cpp
2025-06-11 15:05:11 -04:00
fcf1d169a6 refactor(serif): refactored entire codebase into serif and sub namespaces 2025-06-11 14:49:11 -04:00
b95f2e13ae refactor(config): header guard -> pragma once 2025-05-05 14:36:16 -04:00
453d7a8044 build(config): added compile time option to disable config file load error
In general we may want to enforce that a config file is explicitly loaded before any access is requested. However, there are times when this is non ideal behavior. We introduce a compile time flag (CONFIG_HARSH, and CONFIG_WARN). If config hars is defined then a runtime error will be thrown if a config value is requested before the config file has been loaded. If Config warn is defined (and config harsh is not) then a warning will be printed, otherwise nothing will happen. If either warn or nothing is defined this means that the default values defined in the get methods will be used.

Note that the meson build system has had an option added -Dconfig_error_handling=["none", "warn", "harsh"] (default="none") which can be used to manage these compile time options. In general release builds should have this disabled while debug builts should have it set to harsh.
2025-04-30 11:48:38 -04:00
4fcbcb1d17 build(meson): switched almost all intermediate targets to shared libraries 2025-04-30 11:44:53 -04:00
477b73610b docs(src): updated file headers 2025-04-21 08:56:45 -04:00
0c55a63496 Merge branch 'main' into feature/pointwisePolytrope 2025-03-26 11:38:07 -04:00
666db0760b feat(config): added ability to get all keys and check if a key exists in the given config file
also added the ability to get a config value without specifying a default (this is only avalible to freind classes)
2025-03-20 14:27:57 -04:00
6cef9895c7 refactor(header): brought auto header changes from main into polytrope branch 2025-03-18 07:21:47 -04:00
0c3a204b7d docs(src): added file headers to all files 2025-03-17 12:42:33 -04:00
bc6f86f752 fix(config): loaded flag and checks added
added check to make sure that config file has been loaded before any config variables are accessed
2025-03-03 09:53:42 -05:00
c735fe8b51 fix(config): restored deleted code
I accidently deleted some cacheing mechanisms, these have been restored
2025-02-21 10:39:43 -05:00
c5513f9404 docs(config): rebuild docs and removed redundant documentation 2025-02-20 09:45:47 -05:00
31184647b7 perf(config): added cache
In order to prevent traversing the YAML tree I have added a hash map (O(1) lookup) to cache already accessed config variables. I have also added a vector to store keys requested but not found so we do not need to check for those every time
2025-02-20 09:30:43 -05:00
4dc7d6cd7f feat(config): config class added
At many points in the code we may want configurable options, the Config class usses a yaml file to make this easy. It also allows for namespace references "opac:lowtemp:file" etc...
2025-02-19 16:11:55 -05:00