some fixes, and changed priority of unary minus

This commit is contained in:
ceriel
1987-06-18 15:46:08 +00:00
parent 9046645590
commit ca742a5d0c
13 changed files with 94 additions and 35 deletions

View File

@@ -92,6 +92,8 @@ GetDefinitionModule(id, incr)
register struct def *df;
static int level;
struct scopelist *vis;
char *fn = FileName;
int ln = LineNumber;
level += incr;
df = lookup(id, GlobalScope, 1);
@@ -109,6 +111,7 @@ GetDefinitionModule(id, incr)
ForeignFlag = 0;
open_scope(CLOSEDSCOPE);
if (!is_anon_idf(id) && GetFile(id->id_text)) {
DefModule();
df = lookup(id, GlobalScope, 1);
if (level == 1 &&
@@ -152,6 +155,8 @@ GetDefinitionModule(id, incr)
error("cannot import from currently defined module");
df->df_kind = D_ERROR;
}
FileName = fn;
LineNumber = ln;
assert(df);
level -= incr;
return df;