jenkins-bot has submitted this change and it was merged.
Change subject: Also eat ';' and comments in attributes
......................................................................
Also eat ';' and comments in attributes
Change-Id: Ib5a6ad22271e33216a20f235f71f6e1c52ca9739
---
M js/lib/pegTokenizer.pegjs.txt
1 file changed, 6 insertions(+), 4 deletions(-)
Approvals:
GWicke: Looks good to me, approved
jenkins-bot: Verified
diff --git a/js/lib/pegTokenizer.pegjs.txt b/js/lib/pegTokenizer.pegjs.txt
index 881feff..c13c9ef 100644
--- a/js/lib/pegTokenizer.pegjs.txt
+++ b/js/lib/pegTokenizer.pegjs.txt
@@ -1751,12 +1751,14 @@
generic_attribute_name
= & { return stops.push( 'equal', true ); }
// quick sanity check before expensive attribute_preprocessor_text_line
- // production. Try to parse on |!+ for now, seems to happen in caption
- // tokenization (TODO: try to get rid of those too)
- &([a-zA-Z|!+] /
+ // production. Also try to parse on [|!+;] for now which seem to be common
+ // syntax errors in production that hidden by the PHP parser (by stripping
+ // the 'attributes').
+ &([a-zA-Z|!+;] /
// Possibly a templated attribute
'{{' [^}]+ '}' /
- '<' ('noinclude' / 'onlyinclude' / 'includeonly'))
+ // comment or noincludes
+ '<' ('!--' / 'noinclude' / 'onlyinclude' / 'includeonly'))
name:attribute_preprocessor_text_line
{
stops.pop( 'equal' );
--
To view, visit https://gerrit.wikimedia.org/r/74585
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib5a6ad22271e33216a20f235f71f6e1c52ca9739
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Parsoid
Gerrit-Branch: master
Gerrit-Owner: GWicke <[email protected]>
Gerrit-Reviewer: GWicke <[email protected]>
Gerrit-Reviewer: Subramanya Sastry <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits