From 9c1b1810590181c0ac5b98fb702961da247a23e2 Mon Sep 17 00:00:00 2001 From: Em Chu Date: Mon, 17 Mar 2025 10:24:24 -0700 Subject: [PATCH] Allow for proposed new parsing of array[end] --- src/PEG.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PEG.jl b/src/PEG.jl index 1b8794f..e297783 100644 --- a/src/PEG.jl +++ b/src/PEG.jl @@ -192,7 +192,7 @@ function to_rule(::Val{:ref}, fn, range::Expr) local m local n m, n = range.args[2:3] - n == :end && (n = Inf) + (n == :end || n == Expr(:end)) && (n = Inf) local sym = gensym("[$m:$n]") :((input, cache)->cache_rule($(Meta.quot(sym)), (input, cache)->begin local results = []