Non-Confidential | PDF version | ARM DUI0474M | ||

| ||||

Home > Scatter File Syntax > BNF notation used in scatter-loading description syntax |

Scatter-loading description syntax uses standard BNF notation.

The following table summarizes the Backus-Naur Form (BNF) symbols that are used for describing the syntax of scatter-loading descriptions.

**Table 8-1 BNF notation **

Symbol | Description |
---|---|

`"` |
Quotation marks indicate that a character that is normally part of
the BNF syntax is used as a literal character in the definition. The definition
`B"+"C` , for example, can only be replaced by the pattern
`B+C` . The definition `B+C` can be replaced by, for
example, patterns `BC` , `BBC` , or
`BBBC` . |

`A` ::= `B` |
Defines `A` as `B` . For example,
`A::= B"+" | C` means that `A` is equivalent to
either `B+` or `C` . The `::=` notation
defines a higher level construct in terms of its components. Each component might
also have a `::=` definition that defines it in terms of even simpler
components. For example, `A::= B` and `B::= C | D`
means that the definition `A` is equivalent to the patterns
`C` or `D` . |

[`A` ] |
Optional element `A` . For example, ```
A::=
B[C]D
``` means that the definition can
be expanded into either `BD` or `BCD` . |

`A` + |
Element `A` can have one or more occurrences. For
example, `A::= B+` means that the definition
can be expanded into `B,`
`BB` , or `BBB` . |

`A` * |
Element `A` can have zero or more
occurrences. |

`A` | `B` |
Either element `A` or `B` can
occur, but not both. |

(`A`
`B` ) |
Element `A` and `B` are grouped
together. This is particularly useful when the | operator is used or when a complex
pattern is repeated. For example, `A::=(B C)+ (D | E)` means that the
definition can be expanded into any of
`BCD,`
`BCE` , `BCBCD` , `BCBCE` ,
`BCBCBCD` , or `BCBCBCE` . |