_Parser_parse

This commit is contained in:
shenjack 2024-04-04 13:32:46 +08:00
parent 2c601a0130
commit 052fd43f3a
Signed by: shenjack
GPG Key ID: 7B1134A979775551

View File

@ -2757,28 +2757,28 @@ var A = {
d.push(q) d.push(q)
return a return a
}, },
_Parser_handleIdentifier(a, b, c, d, e) { _Parser_handleIdentifier(parser, start, source, stack, has_period) {
var s, r, q, p, o, n, m = b + 1 var s, r, q, p, o, n, m = start + 1
for (s = c.length; m < s; ++m) { for (s = source.length; m < s; ++m) {
r = c.charCodeAt(m) r = source.charCodeAt(m)
if (r === 46) { if (r === 46) {
if (e) break if (has_period) break
e = true has_period = true
} else { } else {
if (!((((r | 32) >>> 0) - 97 & 65535) < 26 || r === 95 || r === 36)) q = r >= 48 && r <= 57 if (!((((r | 32) >>> 0) - 97 & 65535) < 26 || r === 95 || r === 36)) q = r >= 48 && r <= 57
else q = true else q = true
if (!q) break if (!q) break
} }
} }
p = c.substring(b, m) p = source.substring(start, m)
if (e) { if (has_period) {
s = a.u s = parser.u
o = a.e o = parser.e
if (o.y === 10) o = o.z if (o.y === 10) o = o.z
n = H.ua(s, o.z)[p] n = H.ua(s, o.z)[p]
if (n == null) H.throw_expression('No "' + p + '" in "' + H.tq(o) + '"') if (n == null) H.throw_expression('No "' + p + '" in "' + H.tq(o) + '"')
d.push(H._Universe_evalInEnvironment(s, o, n)) stack.push(H._Universe_evalInEnvironment(s, o, n))
} else d.push(p) } else stack.push(p)
return m return m
}, },
_Parser_handleExtendedOperations(a, stack) { _Parser_handleExtendedOperations(a, stack) {
@ -3052,33 +3052,35 @@ var A = {
} }
}, },
getNativeInterceptor(a) { getNativeInterceptor(a) {
var s, r, q, p, o, n = a[init.dispatchPropertyName] var proto, r, q, interceptor, o, n = a[init.dispatchPropertyName]
if (n == null) if (n == null)
if ($.mA == null) { if ($.mA == null) {
H.uY() H.uY()
n = a[init.dispatchPropertyName] n = a[init.dispatchPropertyName]
} if (n != null) { } if (n != null) {
s = n.p proto = n.p
if (false === s) return n.i if (false === proto) return n.i
if (true === s) return a if (true === proto) return a
r = Object.getPrototypeOf(a) r = Object.getPrototypeOf(a)
if (s === r) return n.i if (proto === r) return n.i
if (n.e === r) throw H.wrap_expression(P.hT("Return interceptor for " + H.as_string(s(a, n)))) if (n.e === r) throw H.wrap_expression(P.hT("Return interceptor for " + H.as_string(proto(a, n))))
} }
q = a.constructor q = a.constructor
if (q == null) p = null if (q == null) interceptor = null
else { else {
o = $.kU o = $.kU
if (o == null) o = $.kU = init.getIsolateTag("_$dart_js") if (o == null) o = $.kU = init.getIsolateTag("_$dart_js")
p = q[o] interceptor = q[o]
} }
if (p != null) return p if (interceptor != null) return interceptor
p = H.lookupAndCacheInterceptor(a)
if (p != null) return p // interceptor = H.lookupAndCacheInterceptor(a)
// if (interceptor != null) return interceptor
if (typeof a == "function") return C.JavaScriptFunction if (typeof a == "function") return C.JavaScriptFunction
s = Object.getPrototypeOf(a) proto = Object.getPrototypeOf(a)
if (s == null) return C.PlainJavaScriptObject if (proto == null) return C.PlainJavaScriptObject
if (s === Object.prototype) return C.PlainJavaScriptObject if (proto === Object.prototype) return C.PlainJavaScriptObject
if (typeof q == "function") { if (typeof q == "function") {
o = $.kU o = $.kU
if (o == null) o = $.kU = init.getIsolateTag("_$dart_js") if (o == null) o = $.kU = init.getIsolateTag("_$dart_js")