diff options
Diffstat (limited to 'src/lexer.l')
-rw-r--r-- | src/lexer.l | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lexer.l b/src/lexer.l index 189a92b..0084d93 100644 --- a/src/lexer.l +++ b/src/lexer.l @@ -204,6 +204,8 @@ void includefile() PRINTB("lex includefile openfilename: %s",of); } + rootmodule->registerInclude(filename); + fs::path fullpath = find_valid_path( sourcepath(), filename, openfilenames ); if ( fullpath.empty() ) { PRINTB("WARNING: Can't open 'include' file '%s'.", filename); @@ -227,8 +229,6 @@ void includefile() return; } - rootmodule->registerInclude(fullname); - openfiles.push_back(yyin); openfilenames.push_back(fullname); filename.clear(); |