[NEXT] [PREV]    HANDBOOK / GENTLE PRIMER / Organizing Larger Projects /

The Use Clause

Gentle
Applications
Concepts
Examples
Handbook
Support
Download

The use clause follows the name clause. It may be empty or of the form


   'use' M1 , ... , Mn
where M1 , ... , Mn is a list of module names (optionally separated by commas). The items provided by modules that appear in this list can be used in the module containing the use clause.

For example. if module IR provides a definition of a type Expr and module CodeGen contains a use clause


   'use'
      IR, TargetFile
then the type Expr can be used inside CodeGen.

A module with an empty use clause cannot use items declared in other modules.





[NEXT] [PREV]