Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5a6489b commit 252f963Copy full SHA for 252f963
1 file changed
lib/matplotlib/type1font.py
@@ -135,9 +135,8 @@ def _split(self, data):
135
136
return data[:len1], binary, data[idx+1:]
137
138
- _whitespace_re = re.compile(br'[\0\t\r\014\n ]+')
+ _whitespace_or_comment_re = re.compile(br'[\0\t\r\014\n ]+|%[^\r\n\v]*')
139
_token_re = re.compile(br'/{0,2}[^]\0\t\r\v\n ()<>{}/%[]+')
140
- _comment_re = re.compile(br'%[^\r\n\v]*')
141
_instring_re = re.compile(br'[()\\]')
142
143
@classmethod
@@ -148,8 +147,7 @@ def _tokens(cls, text):
148
147
"""
149
pos = 0
150
while pos < len(text):
151
- match = (cls._comment_re.match(text, pos) or
152
- cls._whitespace_re.match(text, pos))
+ match = cls._whitespace_or_comment_re.match(text, pos)
153
if match:
154
yield (_TokenType.whitespace, match.group())
155
pos = match.end()
0 commit comments