Add cc65_idlist.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5175 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -980,6 +980,26 @@ static void DBGPRINT(const char* format, ...) {}
|
||||
|
||||
|
||||
|
||||
/*****************************************************************************/
|
||||
/* Id lists */
|
||||
/*****************************************************************************/
|
||||
|
||||
|
||||
|
||||
static cc65_idlist* new_cc65_idlist (unsigned Count)
|
||||
/* Allocate and return a new idlist with the given count. The count field in
|
||||
* the list will already be set on return.
|
||||
*/
|
||||
{
|
||||
/* Allocate memory */
|
||||
cc65_idlist* L = xmalloc (sizeof (*L) - sizeof (L->ids[0]) +
|
||||
Count * sizeof (L->ids[0]));
|
||||
L->count = Count;
|
||||
return L;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*****************************************************************************/
|
||||
/* File info */
|
||||
/*****************************************************************************/
|
||||
@@ -1023,7 +1043,7 @@ static cc65_sourceinfo* new_cc65_sourceinfo (unsigned Count)
|
||||
{
|
||||
cc65_sourceinfo* S = xmalloc (sizeof (*S) - sizeof (S->data[0]) +
|
||||
Count * sizeof (S->data[0]));
|
||||
S->count = Count;
|
||||
S->count = Count;
|
||||
return S;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user