Basics
| main.v
| beta.v
|
|__ parent
| mod1.v
|
|__ child
| mod2.v
Codes:
main.v
import parent
import parent.child as pc
fn main(){
parent.name_parent()
pc.name_child()
}
mod1.v
module parent
pub fn name_parent(){
println('Parent!!!')
}
mod2.v
module child
pub fn name_child(){
println('child!!!')
}
beta.v
pub fn beta_test(){
println('Beta!!!')
}
Need some insight on the module structure:
Error when I run main.v to access child directory.
*error: unknown function: parent.child.name_child*
How to access beta.v function from main.v ?