refactor Lexer to be static class function

This commit is contained in:
Michael Go
2025-01-07 14:32:07 -04:00
parent 3c16c27ee1
commit 002e4caea7
4 changed files with 88 additions and 92 deletions
+1 -2
View File
@@ -3,8 +3,7 @@
module Liquid
class Parser
def initialize(input)
l = Lexer.new(input)
@tokens = l.tokenize
@tokens = Lexer.tokenize(input)
@p = 0 # pointer to current location
end