Use a collections for the line info and sort them by file/line.

git-svn-id: svn://svn.cc65.org/cc65/trunk@751 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2001-05-23 22:02:19 +00:00
parent f3f42c43e5
commit d96baa7c42
2 changed files with 59 additions and 42 deletions

View File

@@ -49,6 +49,7 @@
/* common */
#include "coll.h"
#include "filepos.h"
/* ca65 */
@@ -67,16 +68,13 @@
*/
typedef struct LineInfo LineInfo;
struct LineInfo {
LineInfo* Next; /* Pointer to next info in list */
unsigned Usage; /* Usage counter */
unsigned Index; /* Index */
FilePos Pos; /* File position */
};
/* Linked list of all line infos */
extern LineInfo* LineInfoRoot;
extern LineInfo* LineInfoLast;
extern unsigned LineInfoCount;
/* Collection containing all line infos */
extern Collection LineInfoColl;
extern unsigned LineInfoValid; /* Valid, that is, used entries */
/* Global pointer to last line info or NULL if not active */