mirror of
https://github.com/kemko/liquid.git
synced 2026-01-05 01:35:41 +03:00
Add range support
This commit is contained in:
@@ -50,7 +50,7 @@ module Liquid
|
||||
|
||||
def expression
|
||||
token = @tokens[@p]
|
||||
if token[0] == :id
|
||||
str = if token[0] == :id
|
||||
variable_signature
|
||||
elsif [:string, :number].include? token[0]
|
||||
consume
|
||||
@@ -58,6 +58,13 @@ module Liquid
|
||||
else
|
||||
raise SyntaxError, "#{token} is not a valid expression."
|
||||
end
|
||||
|
||||
if look(:dot) && look(:dot, 1)
|
||||
@p += 2
|
||||
str + expression
|
||||
else
|
||||
str
|
||||
end
|
||||
end
|
||||
|
||||
def argument
|
||||
|
||||
Reference in New Issue
Block a user