diff options
| author | Amlal El Mahrouss <amlal@nekernel.org> | 2025-12-04 16:22:22 +0100 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@nekernel.org> | 2025-12-04 16:25:57 +0100 |
| commit | 654c31b94d547e8d83be378eb5d5ab16a820dcdd (patch) | |
| tree | 96b33b2722401bf556de941617b085905b371789 /src/CompilerKit/Utilities/Compiler.h | |
| parent | cd3092186eb698a9ed175dacb6884f0404e7c062 (diff) | |
chore:: breaking structural changes of CompilerKit.
The Kit has been redesigned to be expandable to new language frontends.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'src/CompilerKit/Utilities/Compiler.h')
| -rw-r--r-- | src/CompilerKit/Utilities/Compiler.h | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/CompilerKit/Utilities/Compiler.h b/src/CompilerKit/Utilities/Compiler.h index 165ab53..bbca020 100644 --- a/src/CompilerKit/Utilities/Compiler.h +++ b/src/CompilerKit/Utilities/Compiler.h @@ -37,14 +37,18 @@ inline static UInt32 kAcceptableErrors = 0; inline static bool kVerbose = false; inline static bool kOutputAsBinary = false; -namespace Detail { -/// @brief Linker specific blob metadata structure -struct DynamicLinkerBlob final { +namespace CompilerKit::Detail { +/// @brief Blob structure +struct Blob final { std::vector<Char> mBlob{}; // PEF code/bss/data blob. UIntPtr mOffset{0UL}; // the offset of the PEF container header... + + explicit operator bool() { + return mBlob.empty() && mOffset > 0UL; + } }; -inline void print_error(std::string reason, std::string file) noexcept { +inline void print_error(STLString reason, STLString file) noexcept { if (reason[0] == '\n') reason.erase(0, 1); kStdErr << reason << kBlank << std::endl; @@ -54,7 +58,7 @@ inline void print_error(std::string reason, std::string file) noexcept { ++kAcceptableErrors; } -inline void print_warning(std::string reason, std::string file) noexcept { +inline void print_warning(STLString reason, STLString file) noexcept { if (reason[0] == '\n') reason.erase(0, 1); kStdOut << kYellow << reason << kBlank << std::endl; |
