mirror of
https://github.com/Ed94/gencpp.git
synced 2025-06-15 03:01:47 -07:00
Converted log_failure and fatal to macros (fixes GEN_PANIC not determining correct line or file)
This commit is contained in:
@ -4413,13 +4413,6 @@ CodeTypedef parse_typedef()
|
||||
|
||||
if ( tok.Type == TokType::BraceCurly_Close )
|
||||
{
|
||||
typedef struct
|
||||
{
|
||||
int a;
|
||||
int b;
|
||||
}* Something;
|
||||
|
||||
|
||||
// Its an inplace definition
|
||||
// typdef <which> <type_identifier> { ... } <identifier>;
|
||||
ok_to_parse = true;
|
||||
|
@ -3,9 +3,9 @@ using LogFailType = sw(*)(char const*, ...);
|
||||
// By default this library will either crash or exit if an error is detected while generating codes.
|
||||
// Even if set to not use fatal, fatal will still be used for memory failures as the library is unusable when they occur.
|
||||
#ifdef GEN_DONT_USE_FATAL
|
||||
constexpr LogFailType log_failure = log_fmt;
|
||||
#define log_failure log_fmt
|
||||
#else
|
||||
constexpr LogFailType log_failure = fatal;
|
||||
#define log_failure fatal
|
||||
#endif
|
||||
|
||||
enum class AccessSpec : u32
|
||||
|
Reference in New Issue
Block a user