mirror of
https://github.com/irmen/prog8.git
synced 2024-09-10 09:54:32 +00:00
fix import paths
This commit is contained in:
parent
d906fcea0e
commit
d5214e2505
@ -158,8 +158,8 @@ class ModuleImporter(val program: Program, val encoder: IStringEncoding, val com
|
|||||||
val fileName = "$name.p8"
|
val fileName = "$name.p8"
|
||||||
val libpaths = libdirs.map {Path.of(it)}
|
val libpaths = libdirs.map {Path.of(it)}
|
||||||
val locations =
|
val locations =
|
||||||
(if(source.toString().isEmpty()) libpaths else libpaths.drop(1) + (source.parent ?: Path.of("."))) +
|
(if(source.toString().isEmpty()) libpaths else libpaths.drop(1) + listOf(source.parent ?: Path.of("."))) +
|
||||||
Paths.get(Paths.get("").toAbsolutePath().toString(), "prog8lib")
|
listOf(Paths.get(Paths.get("").toAbsolutePath().toString(), "prog8lib"))
|
||||||
|
|
||||||
locations.forEach {
|
locations.forEach {
|
||||||
val file = pathFrom(it.toString(), fileName)
|
val file = pathFrom(it.toString(), fileName)
|
||||||
|
Loading…
Reference in New Issue
Block a user