First finished implementation of the condes feature

git-svn-id: svn://svn.cc65.org/cc65/trunk@456 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2000-11-20 21:56:48 +00:00
parent 7646787a6e
commit 518220f9cf
16 changed files with 433 additions and 122 deletions

View File

@@ -31,7 +31,7 @@
/* */
/*****************************************************************************/
/* common */
#include "xmalloc.h"
@@ -59,9 +59,10 @@ Fragment* NewFragment (unsigned char Type, unsigned long Size, Section* S)
F->Obj = 0;
F->Size = Size;
F->Expr = 0;
InitFilePos (&F->Pos);
F->Type = Type;
/* Insert the code fragment into the segment */
/* Insert the code fragment into the section */
if (S->FragRoot == 0) {
/* First fragment */
S->FragRoot = F;
@@ -69,8 +70,13 @@ Fragment* NewFragment (unsigned char Type, unsigned long Size, Section* S)
S->FragLast->Next = F;
}
S->FragLast = F;
/* Increment the size of the section by the size of the fragment */
S->Size += Size;
/* Increment the size of the segment that contains the section */
S->Seg->Size += Size;
/* Return the new fragment */
return F;
}