mirror of
https://github.com/Ed94/Odin.git
synced 2026-06-13 01:21:38 -07:00
Minor fixes to gencpp formatting
This commit is contained in:
@@ -460,6 +460,7 @@ int gen_main()
|
||||
}));
|
||||
body.append(swapped_table);
|
||||
body.append(fmt_newline);
|
||||
|
||||
// Right after is where the struct definitions were defined, we'll insert them here
|
||||
body.append(def_pragma(txt("region TYPE_KINDS")));
|
||||
body.append(fmt_newline);
|
||||
|
||||
@@ -1522,12 +1522,6 @@ void CodeBody::to_string( String& result )
|
||||
while ( left-- )
|
||||
{
|
||||
result.append_fmt( "%S", curr.to_string() );
|
||||
|
||||
if (left > 1) switch (ast->Type)
|
||||
{
|
||||
case ECode::Enum_Body:
|
||||
result.append("\n");
|
||||
}
|
||||
++curr;
|
||||
}
|
||||
}
|
||||
@@ -10706,8 +10700,13 @@ namespace parser
|
||||
// <Name> = <Expression> <Macro>,
|
||||
}
|
||||
|
||||
entry.Length = ( (sptr)prevtok.Text + prevtok.Length ) - (sptr)entry.Text;
|
||||
// Consume inline comments
|
||||
if ( currtok.Type == TokType::Comment && prevtok.Line == currtok.Line )
|
||||
{
|
||||
eat( TokType::Comment );
|
||||
}
|
||||
|
||||
entry.Length = ( (sptr)prevtok.Text + prevtok.Length ) - (sptr)entry.Text;
|
||||
member = untyped_str( entry );
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user