Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: abp/filters/parser.py

Issue 30022565: Issue 7325 - Let the parser handle filters than begin and end with '%' (Closed) Base URL: https://hg.adblockplus.org/python-abp
Patch Set: Created March 5, 2019, 1:17 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/test_parser.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: abp/filters/parser.py
===================================================================
--- a/abp/filters/parser.py
+++ b/abp/filters/parser.py
@@ -306,7 +306,7 @@
return Metadata(key, value)
return Comment(stripped[1:].lstrip())
- if stripped.startswith('%') and stripped.endswith('%'):
+ if stripped.startswith('%include') and stripped.endswith('%'):
return _parse_instruction(stripped)
return parse_filter(stripped)
« no previous file with comments | « no previous file | tests/test_parser.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld