Figure 1 provides a specification of Cool syntax. The specification is not in pure Backus-Naur Form (BNF); for convenience, we also use some regular expression notation. Specifically, means zero or more 's in succession; means one or more 's. Items in square brackets are optional. Double brackets are not part of Cool; they are used in the grammar as a meta-symbol to show association of grammar symbols (e.g. means followed by one or more pairs).