We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f66c886 commit d859af2Copy full SHA for d859af2
src/Development/IDE/Import/FindImports.hs
@@ -68,6 +68,12 @@ locateModule
68
-> m (Either [FileDiagnostic] Import)
69
locateModule dflags exts doesExist modName mbPkgName isSource = do
70
case mbPkgName of
71
+ -- "this" means that we should only look in the current package
72
+ Just "this" -> do
73
+ mbFile <- locateModuleFile dflags exts doesExist isSource $ unLoc modName
74
+ case mbFile of
75
+ Nothing -> return $ Left $ notFoundErr dflags modName $ LookupNotFound []
76
+ Just file -> return $ Right $ FileImport file
77
-- if a package name is given we only go look for a package
78
Just _pkgName -> lookupInPackageDB dflags
79
Nothing -> do
0 commit comments