a6bdadac0c
Co-authored-by: Copilot <copilot@github.com>
539 B
539 B
Imports
The import statement allows one module access to the public declarations of another module.
Syntax
The import statement uses the following syntax:
import module_name;
They can optionally be prefixed by the public keyword, in which case the module will
export everything in the import transitively.
For instance,
--- a.c2
module a;
import b;
--- b.c2
module b;
public import c;
--- c.c2
module c;
// Some declarations
In this example, both module a and b can access the declarations in module c.