mirror of
https://github.com/Ed94/gencpp.git
synced 2025-07-12 00:25:43 -07:00
WIP : better AST::debug_str()
Now its more contexually rich to the ast type, however I need to hookup tokens from parsing to the AST. There needs to be a way for the debug string to lookup the token and provide the contexual line. Can either pass it ( TokArray* toks ) from the parser on failure (or `CodeFile`).. Technically there is more than enough room for another Token* ptr. I could add another and specifiers would still have at minimum 14 slots before needing to extended to next specs. **************... yeah
This commit is contained in:
@ -861,8 +861,8 @@ CodeInclude def_include( StrC path, bool foreign )
|
||||
}
|
||||
|
||||
StrC content = foreign ?
|
||||
to_str( str_fmt_buf( "<%.*s>\n", path.Len, path.Ptr ))
|
||||
: to_str( str_fmt_buf( "\"%.*s\"\n", path.Len, path.Ptr ));
|
||||
to_str( str_fmt_buf( "<%.*s>", path.Len, path.Ptr ))
|
||||
: to_str( str_fmt_buf( "\"%.*s\"", path.Len, path.Ptr ));
|
||||
|
||||
Code
|
||||
result = make_code();
|
||||
|
Reference in New Issue
Block a user