Hello dear friends. I can import from subdirectories so: import subdir/some_module , or so: import subdir.some_module I can import from parent directory so: import ../some_module I can import from parent directory and it's subdirectory so: import ../subdir_of_parent/some_module But I can't use points there: import ..subdir_of_parent.some_module >> error Is it really one way to do this (while to import from subdir we can with two ways)? (if yes, why not to add ways with points only andor with slashes only?) Thank you.
2017-07-14 09:53:20

I'm not sure if I understand the question correctly. An example project structure:

submodA/submodA.nim
submodB/submodB.nim
parent.nim

Now you can do in submodA.nim for instance:

import ../parent
import ../submodB/submodB

Maybe your file names require to put the paths in quotes?

2017-07-15 07:54:56