Lines Matching refs:end
34 def errmsg(msg, doc, pos, end=None): argument
37 if end is None:
42 endlineno, endcolno = linecol(doc, end)
44 return fmt.format(msg, lineno, colno, endlineno, endcolno, pos, end)
73 def py_scanstring(s, end, encoding=None, strict=True, argument
87 begin = end - 1
89 chunk = _m(s, end)
93 end = chunk.end()
108 raise ValueError(errmsg(msg, s, end))
113 esc = s[end]
123 raise ValueError(errmsg(msg, s, end))
124 end += 1
127 uni = _decode_uXXXX(s, end)
128 end += 5
131 0xd800 <= uni <= 0xdbff and s[end:end + 2] == '\\u':
132 uni2 = _decode_uXXXX(s, end + 1)
135 end += 6
139 return u''.join(chunks), end
150 s, end = s_and_end
155 nextchar = s[end:end + 1]
159 end = _w(s, end).end()
160 nextchar = s[end:end + 1]
165 return result, end + 1
169 return pairs, end + 1
172 "Expecting property name enclosed in double quotes", s, end))
173 end += 1
175 key, end = scanstring(s, end, encoding, strict)
179 if s[end:end + 1] != ':':
180 end = _w(s, end).end()
181 if s[end:end + 1] != ':':
182 raise ValueError(errmsg("Expecting ':' delimiter", s, end))
183 end += 1
186 if s[end] in _ws:
187 end += 1
188 if s[end] in _ws:
189 end = _w(s, end + 1).end()
194 value, end = scan_once(s, end)
196 raise ValueError(errmsg("Expecting object", s, end))
200 nextchar = s[end]
202 end = _w(s, end + 1).end()
203 nextchar = s[end]
206 end += 1
211 raise ValueError(errmsg("Expecting ',' delimiter", s, end - 1))
214 nextchar = s[end]
216 end += 1
217 nextchar = s[end]
219 end = _w(s, end + 1).end()
220 nextchar = s[end]
224 end += 1
227 "Expecting property name enclosed in double quotes", s, end - 1))
230 return result, end
234 return pairs, end
237 s, end = s_and_end
239 nextchar = s[end:end + 1]
241 end = _w(s, end + 1).end()
242 nextchar = s[end:end + 1]
245 return values, end + 1
249 value, end = scan_once(s, end)
251 raise ValueError(errmsg("Expecting object", s, end))
253 nextchar = s[end:end + 1]
255 end = _w(s, end + 1).end()
256 nextchar = s[end:end + 1]
257 end += 1
261 raise ValueError(errmsg("Expecting ',' delimiter", s, end))
263 if s[end] in _ws:
264 end += 1
265 if s[end] in _ws:
266 end = _w(s, end + 1).end()
270 return values, end
364 obj, end = self.raw_decode(s, idx=_w(s, 0).end())
365 end = _w(s, end).end()
366 if end != len(s):
367 raise ValueError(errmsg("Extra data", s, end, len(s)))
380 obj, end = self.scan_once(s, idx)
383 return obj, end