Save filename as well as line number for each symbol.

svn path=/trunk/yasm/; revision=224
0.3
Peter Johnson 24 years ago
parent 197f8857e4
commit 902d974288
  1. 1
      libyasm/symrec.c
  2. 3
      libyasm/symrec.h
  3. 1
      src/symrec.c
  4. 3
      src/symrec.h

@ -67,6 +67,7 @@ symrec_get_or_new(char *name, SymType type)
Fatal(FATAL_NOMEM);
rec->type = type;
rec->value = 0;
rec->filename = strdup(filename);
rec->line = line_number;
rec->status = SYM_NOSTATUS;

@ -38,7 +38,8 @@ typedef struct symrec_s {
char *name;
SymType type;
SymStatus status;
int line; /* line symbol was first declared or used on */
char *filename; /* file and line */
int line; /* symbol was first declared or used on */
double value;
} symrec;

@ -67,6 +67,7 @@ symrec_get_or_new(char *name, SymType type)
Fatal(FATAL_NOMEM);
rec->type = type;
rec->value = 0;
rec->filename = strdup(filename);
rec->line = line_number;
rec->status = SYM_NOSTATUS;

@ -38,7 +38,8 @@ typedef struct symrec_s {
char *name;
SymType type;
SymStatus status;
int line; /* line symbol was first declared or used on */
char *filename; /* file and line */
int line; /* symbol was first declared or used on */
double value;
} symrec;

Loading…
Cancel
Save