Schedule ordinary import contributions by dependency
This commit is contained in:
@@ -23,9 +23,16 @@ func contextsForAcquiredSources(source Source, context *FilesystemContext, baseS
|
||||
filesystem = context.FS.namespace.filesystem
|
||||
rootPath, basePath = context.Root, context.BaseDir
|
||||
} else if source.kind == sourceFile {
|
||||
filePath := sources[0].Path
|
||||
filePath := source.path
|
||||
if baseSource != nil {
|
||||
filePath = baseSource.Path
|
||||
} else {
|
||||
canonical, err := canonicalExistingPath(filePath)
|
||||
if err != nil {
|
||||
value := importDiagnostic(CodeImportInvalid, "selected source could not be canonicalized", nil)
|
||||
return nil, &value
|
||||
}
|
||||
filePath = canonical
|
||||
}
|
||||
basePath = filepath.Dir(filePath)
|
||||
rootPath = basePath
|
||||
|
||||
Reference in New Issue
Block a user