Added filename check

This commit is contained in:
ceriel 1992-05-11 11:52:22 +00:00
parent 2da0d6f886
commit 763c607bd8

View file

@ -235,9 +235,15 @@ definition
ProgramModule
{
register t_def *df;
int len;
} :
MODULE
IDENT { if (state == IMPLEMENTATION) {
IDENT { len = strlen(dot.TOK_IDF->id_text);
if (len > 10) len = 10;
if (strncmp(FileName, dot.TOK_IDF->id_text, 10)) {
warning(W_ORDINARY, "modulename %s does not match filename %s", dot.TOK_IDF->id_text, FileName);
}
if (state == IMPLEMENTATION) {
df = GetDefinitionModule(dot.TOK_IDF, 0);
CurrVis = df->mod_vis;
}