Skip to main content
Version: Next

phrase/3

Description

phrase/3 is a predicate that parses a list using a grammar rule (DCG).

Signature

phrase(+GrammarRule, ?Input, ?Rest)

Where:

  • GrammarRule is the grammar rule to apply.
  • Input is the input list to parse.
  • Rest is the remaining unparsed part of the input.