def theory_element: Parser[Element_Command] =
category(Keyword.theory_goal) ~ proof ^^ { case a ~ b => element(a, b) } def proof_element: Parser[Element_Command] =
category(Keyword.proof_goal) ~ proof ^^ { case a ~ b => element(a, b) } |
category(Keyword.proof_body, other = true) ^^ { case a => atom(a) } def proof: Parser[Proof[Command]] =
rep(proof_element) ~ category(Keyword.qed) ^^ { case a ~ b => (a, b) }
val default_element: Parser[Element_Command] = command(_ => true) ^^ { case a => atom(a) }
def apply: List[Element_Command] =
rep(theory_element | default_element)(Reader(commands)) match { case Success(result, rest) if rest.atEnd => result case bad => error(bad.toString)
}
}
Parsers.apply
}
}
¤ Dauer der Verarbeitung: 0.13 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.