Skip to content

Commit 416d32d

Browse files
committed
Module page fix
1 parent 4b40b73 commit 416d32d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

docs/modules.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,12 @@ sub-scope which starts with a colon and is demarcated using indentation (or brac
4444
import tx.c.puts
4545

4646
module my.file.mod.submod:
47-
import another.mod.*
47+
import another.mod.get_string
4848

49-
SUB_FIELD := c"42"
49+
SUB_FIELD := get_string()
5050

51-
main(): ## this is outside the submodule, in my.file.mod
52-
puts( submod.SUB_FIELD ) ## relative qualified identifier
51+
main(): ## declared outside the submodule, gets the full name my.file.mod.main
52+
puts( submod.SUB_FIELD ) ## submod.SUB_FIELD is looked up relative to my.file.mod
5353

5454
Submodules may contain submodules of their own, and so on. However it is usually inadvisable to nest them within
5555
the same file.

0 commit comments

Comments
 (0)