From c1e489048f7b860c1342b04fa7b3a6baced6ee39 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Wed, 16 Sep 2020 00:01:13 -0700 Subject: Fixed grammar --- grammars/html.bpeg | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/grammars/html.bpeg b/grammars/html.bpeg index 9d74f5e..f3d76fd 100644 --- a/grammars/html.bpeg +++ b/grammars/html.bpeg @@ -1,7 +1,7 @@ # HTML grammar HTML = __ ?(doctype __) *html-element%__ __; -doctype = "; +doctype = "; html-element = ( >(`<("area"/"base"/"br"/"col"/"embed"/"hr"/"img"/"input"/"link"/"meta"/"param"/"source"/"track"/"wbr")) void-element @@ -17,11 +17,11 @@ raw-element = `< @[tag](id==match-tag) __attributes__ `> >match-body @[body].. ( normal-element = `< @[tag](id==match-tag) __attributes__ `> >match-body @[body]*(!`<$. / comment / html-element / !(")$.) "; -comment = ""; +comment = ""; attributes = *(!(attribute==match-attribute))%__ __(attribute==match-attribute)__ *attribute%__; -attribute = (+id%`:)__`=__ (id / `" &`" / `' &`'); -attribute = (+id%`:)__`=__ (id / `" .. `" / `' .. `'); +attribute = (+id%`:)__`=__ (id / `" ..`" / `' ..`'); +attribute = (+id%`:)__`=__ (id / `" ..`" / `' ..`'); match-attribute = attribute; match-tag = id; match-body = (/); -- cgit v1.2.3