mirror of
https://github.com/HigherOrderCO/Kind.git
synced 2024-10-03 18:27:13 +03:00
fix ascii syntax for lambda and forall
previously, it collided with names starting with lambda/forall.
This commit is contained in:
parent
b516d3b7ea
commit
906bc6474b
@ -83,7 +83,9 @@ impl<'i> KindParser<'i> {
|
||||
|
||||
// ALL ::= ∀(<name>: <term>) <term>
|
||||
// "forall" can be used as an ascii alternative to "∀"
|
||||
if self.starts_with("∀") || self.starts_with("forall") {
|
||||
if self.starts_with("∀") ||
|
||||
self.starts_with("forall ") ||
|
||||
self.starts_with("forall(") {
|
||||
let ini = *self.index() as u64;
|
||||
if self.starts_with("∀") {
|
||||
self.consume("∀")?;
|
||||
@ -104,7 +106,9 @@ impl<'i> KindParser<'i> {
|
||||
|
||||
// LAM ::= λ<name> <term>
|
||||
// "lambda" can be used as an ascii alternative to "λ"
|
||||
if self.starts_with("λ") || self.starts_with("lambda") {
|
||||
if self.starts_with("λ") ||
|
||||
self.starts_with("lambda ") ||
|
||||
self.starts_with("lambda(") {
|
||||
let ini = *self.index() as u64;
|
||||
if self.starts_with("λ") {
|
||||
self.consume("λ")?;
|
||||
|
Loading…
Reference in New Issue
Block a user