Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

Metalanguage Description

1984 Version of ANSI Standard

2. Static Syntax Metalanguage

The primitives of the metalanguage are the ASCII characters and the metalanguage operators (definition), [ ] (option), ; ; (grouping), ... (optional indefinite repetition), L (list), and V (value).

In general, defined syntactic objects will have designations which are underlined names spelled with lower case letters, e.g., name, expr, etc. Concatenation of syntactic objects is expressed by horizontal juxtaposition, choice is expressed by vertical juxtaposition. The symbol denotes a syntactic definition. An optional element is enclosed in square brackets [1, and three dots ... denote that the previous element is optionally repeated any number of times. The definition of name, for example, is written:

    name::=

%
alpha




digit
alpha


...

The vertical bars are used only to group elements for repetition or to make a group of elements more readable. When there is any danger of confusing the square brackets in the metalanguage with the ASCII graphics [ and ], special care is taken to avoid this. Normally, the square brackets will stand for the metalanguage symbols.

The unary metalanguage operator L denotes a list of one or more occurrences of the syntactic object immediately to its right, with one comma between each pair of occurrences. Thus,

L name

is equivalent to

name [ , name ] ...

The binary metalanguage operator V, used in the specification of indirection, places the constraint on the expratom to its left that it must have a value which satisfies the syntax of the syntactic object to its right. For example, one might define the syntax of a hypothetical EXAMPLE command with its argument list by

    examplecommand::= EXAMPLE Space L exampleargument

where

    exampleargument::=

expr
@ expratom V L exampleargument


This says that, after evaluation of indirection, the command argument list consists of any number of exprs separated by commas. In the static syxtax (i.e., prior to evaluation of indirection), occurrences of @ expratom may stand in place of nonoverlapping sublists of command arguments. Usually, the text accompanying a syntax description incorporating indirection will describe the syntax after all occurrences of indirection have been evaluated.

Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

Copyright © Standard Documents; 1977-2024 MUMPS Development Committee;
Copyright © Examples: 1995-2024 Ed de Moel;
Copyright © Annotations: 2003-2008 Jacquard Systems Research
Copyright © Annotations: 2008-2024 Ed de Moel.

This page most recently updated on 16-Nov-2023, 17:52:46.

For comments, contact Ed de Moel (demoel@jacquardsystems.com)