• Home
  • Raw
  • Download

Lines Matching refs:end

29 def errmsg(msg, doc, pos, end=None):  argument
31 if end is None:
33 endlineno, endcolno = linecol(doc, end)
35 msg, lineno, colno, endlineno, endcolno, pos, end)
68 def scanstring(s, end, encoding=None, _b=BACKSLASH, _m=STRINGCHUNK.match): argument
73 begin = end - 1
75 chunk = _m(s, end)
79 end = chunk.end()
88 esc = s[end]
97 errmsg("Invalid \\escape: %r" % (esc,), s, end))
98 end += 1
100 esc = s[end + 1:end + 5]
106 raise ValueError(errmsg("Invalid \\uXXXX escape", s, end))
107 end += 5
109 return u''.join(chunks), end
113 return scanstring(match.string, match.end(), encoding)
121 end = _w(s, match.end()).end()
122 nextchar = s[end:end + 1]
125 return pairs, end + 1
127 raise ValueError(errmsg("Expecting property name", s, end))
128 end += 1
132 key, end = scanstring(s, end, encoding)
133 end = _w(s, end).end()
134 if s[end:end + 1] != ':':
135 raise ValueError(errmsg("Expecting : delimiter", s, end))
136 end = _w(s, end + 1).end()
138 value, end = iterscan(s, idx=end, context=context).next()
140 raise ValueError(errmsg("Expecting object", s, end))
142 end = _w(s, end).end()
143 nextchar = s[end:end + 1]
144 end += 1
148 raise ValueError(errmsg("Expecting , delimiter", s, end - 1))
149 end = _w(s, end).end()
150 nextchar = s[end:end + 1]
151 end += 1
153 raise ValueError(errmsg("Expecting property name", s, end - 1))
157 return pairs, end
163 end = _w(s, match.end()).end()
165 nextchar = s[end:end + 1]
167 return values, end + 1
171 value, end = iterscan(s, idx=end, context=context).next()
173 raise ValueError(errmsg("Expecting object", s, end))
175 end = _w(s, end).end()
176 nextchar = s[end:end + 1]
177 end += 1
181 raise ValueError(errmsg("Expecting , delimiter", s, end))
182 end = _w(s, end).end()
183 return values, end
251 obj, end = self.raw_decode(s, idx=_w(s, 0).end())
252 end = _w(s, end).end()
253 if end != len(s):
254 raise ValueError(errmsg("Extra data", s, end, len(s)))
268 obj, end = self._scanner.iterscan(s, **kw).next()
271 return obj, end