Prev Up Next
Go backward to 2 Our Proposal in a Nut Shell
Go up to Top
Go forward to 4 Some examples

3 Related changes to the language

Though the proposed treatment of generic specifications is orthogonal to the other parts of the language, adopting our proposal (we believe) makes possible to restrict the form of extension as follows.
EXTENSION      ::=  extension OF-SPEC+ BASIC-ITEM+
OF-SPEC        ::=  SPEC | conservative SPEC
Having restricted the extending part to a list of basic items would An anlysis of motivating examples should lead to understand if what we gain in simplicity is worth the restriction, especially from a methodological point of view.

A minor point is that we noticed an inconsistency between extension, that can protect its parameters, and union, that cannot. Hence, here we are also proposing to generalize the construct for union accordingly, because this would decrease the loss of generality in simplifying the extension.

UNION          ::=  union OF-SPEC+
Having interpreted SPEC as self-contained specifications, the construct for local stuff has to be modified accordingly. Indeed, the construct for local specification should be moved to the second part on structured specifications, where it belongs, and a construct for local basic-items should be added, as suggested also by Andrzej (Michel supporting, we believe).

Analogously, the construct for freeness, should have two arguments

FREE ::=  free OF-SPEC+ SPEC
where, notice, the SPEC part is, now, a closed specification, whose signature includes those of each OF-SPEC . Since the FREE construct is often used with as SPEC part an extension of the OF-SPEC , we suggest to have, either at the concrete or at the abstract syntax level, also a derived construct
FREE-EXTENSION ::=  free-extension OF-SPEC+ BASIC-ITEM+
where free-extension OF-SPEC+ BASIC-ITEM+ expands to
free OF-SPEC+ (extension OF-SPEC+ BASIC-ITEM+).
CoFI Note: L-3 --DRAFT, Version 0.2-- 21 May 1997.
Comments to cerioli@disi.unige.it

Prev Up Next