Up Next
Go up to 8.1 Unit Declarations and Definitions
Go forward to 8.1.2 Unit Definitions

8.1.1 Unit Declarations

  UNIT-DECL        ::= unit-decl UNIT-NAME UNIT-SPEC UNIT-IMPORTS
  UNIT-IMPORTS     ::= unit-imports UNIT-TERM*
  UNIT-NAME        ::= SIMPLE-ID

A unit declaration UNIT-DECL is written:

UN : US given UT1,...,UTn
When the list UNIT-TERM* of unit terms is empty, it is simply written:
UN : US

It provides not only a unit specification US but also a unit name UN, which is used for referring to the unit in subsequent unit expressions, so that the same unit may be used more than once in a composition. In addition, the UNIT-IMPORTS lists any units UT1, ...,UTn that are imported for the implementation of the declared unit (corresponding to implementing a generic unit function and applying it only once, to the imported units).


CoFI Document: CASL/Summary --Version 0.99-- 21 April 1998.
Comments to cofi-language@brics.dk

Up Next