Abstract syntax

[1] This is particularly used in the representation of text in computer languages,[2] which are generally stored in a tree structure as an abstract syntax tree.

For example, concrete syntax includes features like parentheses (for grouping) or commas (for lists), which are not included in the abstract syntax, as they are implicit in the structure.

[3] To be implemented either for computation or communications, a mapping from the abstract syntax to specific machine representations and encodings must be defined; these may be called the "concrete syntax" (in language implementation)[4] or the "transfer syntax" (in communications).

A compiler's internal representation of a program will typically be specified by an abstract syntax in terms of categories such as "statement", "expression" and "identifier".

Algebraic data types are particularly well-suited to the implementation of abstract syntax.