Extending context-free grammars with permutation phrases

  • Authors:
  • Robert D. Cameron

  • Affiliations:
  • Simon Fraser Univ., Burnaby, B.C., Canada

  • Venue:
  • ACM Letters on Programming Languages and Systems (LOPLAS)
  • Year:
  • 1993

Quantified Score

Hi-index 0.00

Visualization

Abstract

A permutation phrase is a grammatical phrase that specifies a syntactic construct as any permutation of a set of constituent elements. Permutation phrases allow for the concise and natural expression of free-order constructs as found in programming languages and notations such as C, Cobol, BibTEX, and Unix command lines.The conciseness and clarity of expression that permutation phrase grammars offer over context-free grammars are illustrated through a case study of the declarations in C. The parsing problem for permutation phrase grammars is considered, and it is shown how efficient linear-time parsing can be achieved for permutation phrase grammars satisfying an extended notion of the LL(1) property.