Open rockerBOO opened 2 years ago
I've been working on a html parser to work well with .html.eex files and found these errors when using this grammar.
I looked at it some but I didn't make much progress as I do not understand some parts of the grammar.
So here's my test case and the resulting errors when testing.
<%= Enum.map(errors, fn error -> error end) |> Enum.join("") %> <%= Enum.each(errors, fn error -> if error do %>error<%= end) %> <%= Enum.each(errors, fn error -> if Map.has_key?(error, :email) do %><%= error.email %><%= end) %> <%= Enum.map(errors, fn error -> if Map.has_key?(error, :email) do "hello" end) |> Enum.join("") %>
(fragment (directive (partial_expression) (ERROR (UNEXPECTED 'r') (UNEXPECTED '|'))) (directive (partial_expression) (ERROR (UNEXPECTED 'i'))) (text) (directive (partial_expression)) (directive (partial_expression) (ERROR (UNEXPECTED 'i'))) (directive (expression)) (directive (partial_expression)) (directive (ERROR (partial_expression) (UNEXPECTED 'i') (UNEXPECTED '"')) (partial_expression)) (text))
Willing to try and fix this. But I'm lacking on context for how it's expected to work or why it may be erroring.
I've been working on a html parser to work well with .html.eex files and found these errors when using this grammar.
I looked at it some but I didn't make much progress as I do not understand some parts of the grammar.
So here's my test case and the resulting errors when testing.
Willing to try and fix this. But I'm lacking on context for how it's expected to work or why it may be erroring.