Commit 75765e8b authored by Denis Steckelmacher's avatar Denis Steckelmacher

Don't stop importing neighbor files when the current file is encountered

If a directory contains A, B and C, B must import A and C, not just A.
parent f2f80023
......@@ -79,7 +79,11 @@ void DeclarationBuilder::startVisiting(QmlJS::AST::Node* node)
QDirIterator dir(file.absolutePath(), QStringList() << "*.qml" << "*.js", QDir::Files);
DUChainWriteLocker lock;
while (dir.hasNext() && != file.absoluteFilePath()) {
while (dir.hasNext()) {
if ( == file.absoluteFilePath()) {
ReferencedTopDUContext context = m_session->contextOfFile(dir.filePath());
if (!context) {
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment