Closed rogerlucena closed 4 years ago
I recon we already had tests for this syntax in the planner, right? If not, do you mind adding them, please?
@rbkloss we have indeed, but I have just added two more there in planner_test.go
to also test the case on which the AFTER
/BEFORE
clauses do not terminate with ;
(not being the last ones of the query, followed by LIMIT
there).
Previously, in
AFTER
andBEFORE
clauses the timestamp that came after these keywords was understood as alexer.ItemPredicate
token in the code.This PR, then, comes to create a new token type: the
lexer.ItemTime
, and use it for theAFTER
andBEFORE
global time bound clauses, making the code cleaner.This PR also comes to add missing tests for
AFTER
andBEFORE
inlexer_test.go
.