Restructured some of the code. Attribute handling is still a mess and needs

another cleanup.
Added unnamed labels.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3700 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2006-01-29 19:00:22 +00:00
parent 7086da868b
commit d31f72d057
15 changed files with 825 additions and 411 deletions

View File

@@ -176,6 +176,46 @@ void DefLabel (const char* Name)
void DefForward (const char* Name, const char* Comment, unsigned Offs)
/* Define a label as "* + x", where x is the offset relative to the
* current PC.
*/
{
if (Pass == PassCount) {
Output ("%s", Name);
Indent (AIndent);
if (UseHexOffs) {
Output (":= * + $%04X", Offs);
} else {
Output (":= * + %u", Offs);
}
if (Comment) {
Indent (CIndent);
Output ("; %s", Comment);
}
LineFeed ();
}
}
void DefineConst (const char* Name, const char* Comment, unsigned Addr)
/* Define an address constant */
{
if (Pass == PassCount) {
Output ("%s", Name);
Indent (AIndent);
Output (":= $%04X", Addr);
if (Comment) {
Indent (CIndent);
Output ("; %s", Comment);
}
LineFeed ();
}
}
void DataByteLine (unsigned ByteCount)
/* Output a line with bytes */
{
@@ -322,20 +362,3 @@ void OutputSettings (void)
void DefineConst (const char* Name, const char* Comment, unsigned Addr)
/* Define an address constant */
{
if (Pass == PassCount) {
Output ("%s", Name);
Indent (AIndent);
Output (":= $%04X", Addr);
if (Comment) {
Indent (CIndent);
Output ("; %s", Comment);
}
LineFeed ();
}
}