Skip to content

Commit

Permalink
refs #3127 qore user modules: syntax error reporting is very confusin…
Browse files Browse the repository at this point in the history
…g after the module split (#3176)
  • Loading branch information
pvanek authored and sejvlond committed Dec 14, 2018
1 parent 43697b3 commit cfaaba8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/ModuleManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -951,7 +951,7 @@ QoreAbstractModule* QoreModuleManager::loadSeparatedModule(ExceptionSink& xsink,
QoreUserModuleDefContextHelper qmd(feature, mpgm, xsink);

std::string moduleCode = QoreDir::get_file_content(modulePath.c_str());
userModule->getProgram()->parsePending(moduleCode.c_str(), feature, &xsink, &xsink, QP_WARN_MODULES);
userModule->getProgram()->parsePending(moduleCode.c_str(), path.c_str(), &xsink, &xsink, QP_WARN_MODULES);
if (xsink) {
return nullptr;
}
Expand All @@ -968,7 +968,7 @@ QoreAbstractModule* QoreModuleManager::loadSeparatedModule(ExceptionSink& xsink,
filePath += fileList->retrieveEntry(i).get<const QoreStringNode>()->c_str();

std::string fileCode = QoreDir::get_file_content(filePath);
userModule->getProgram()->parsePending(fileCode.c_str(), feature, &xsink, &xsink);
userModule->getProgram()->parsePending(fileCode.c_str(), filePath.c_str(), &xsink, &xsink);
if (xsink) {
return nullptr;
}
Expand Down

0 comments on commit cfaaba8

Please sign in to comment.