A Symbol key on a proxy read, wrote, tested, deleted and described the
proxy's own Symbol table, so the target never saw it and no trap ran.
Every Symbol path now resolves a proxy the way a string key does: the
get, set, has, deleteProperty, defineProperty and getOwnPropertyDescriptor
traps receive the Symbol, and without a trap the operation reaches the
target with its writable and accessor checks. A super write and a write
on a primitive that reach a proxy go through its [[Set]].
- ownKeys traps may return Symbols; a duplicate Symbol (by identity) or
any other value is a TypeError, and the result is checked against the
target's non-configurable and, for a non-extensible target, all keys
of both kinds, in the target's own key order.
- Reflect.ownKeys lists Symbols, in the trap's order for a proxy, and
Reflect's other functions take Symbol keys. Object.freeze, seal,
isFrozen and isSealed include a proxy's Symbols instead of throwing.
- Symbol key lists stay rooted and charged to the heap until released.
- new Proxy and Proxy.revocable reject a revoked target or handler.
- A typed array reached on the prototype chain as the receiver converts
the value for an index it lacks.
- The eval redeclaration test asserts the runtime SyntaxError.
A realm made with Options::es2015 had no Object.setPrototypeOf, so a
call threw "the value is not a function". It now follows ECMA-262 2015
section 19.1.2.18: undefined or null for the object, or a prototype
that is neither an object nor null, is a TypeError; any other primitive
is returned unchanged; an object whose [[SetPrototypeOf]] gives false
is a TypeError.
It calls the same [[SetPrototypeOf]] as Reflect.setPrototypeOf
(Interp::set_prototype_of in crates/js/src/proxy.rs). A non-extensible
object given a different prototype, Object.prototype given any other
prototype than null, and a prototype whose chain leads back to the
object give false. For a proxy it calls the handler's setPrototypeOf
trap, or sets the target's prototype when there is no trap; a false
result, a revoked proxy and a trap that breaks the section 9.5.2
invariant are TypeErrors. Each prototype the cycle check passes takes
fuel, and a sparse array walk that is running sees indices the new
prototype brings. The function has length 2 and the name
setPrototypeOf, and a realm made without the option does not have it.
Reflect.construct of Map, Set, WeakMap and WeakSet with another newTarget fills the collection through the new prototype's adder, new through an empty-handler proxy of a host class constructs the class, Reflect has Symbol.toStringTag, and an ownKeys result is read in full before a duplicate is refused.
A revoked proxy no longer gives its own Symbol properties, the reflect extension reads proxies without running traps, key lists a proxy gives stay counted against the heap while callers use them, has through a proxy of a host collection asks the collection, a proxy's invariant checks keep a namespace's uninitialized-export errors, and a binary constructor checks its arguments before it reads newTarget's prototype. Trap arguments stay rooted while a trap runs.
Reflect.ownKeys and a proxy without an ownKeys trap list integer-index keys in ascending order first. Reflect.construct takes another newTarget for Map, Set and typed arrays, for-in reads each proxy key's descriptor once, deleting a with binding runs only the deleteProperty trap, a write past a typed array's view on the prototype chain is ignored, and a target's descriptor stays reachable while a trap runs. The crate documentation states that traps take string keys only.
A proxy's descriptor and write paths honor a module namespace's uninitialized exports and read-only writes, for-in through proxies counts the keys it keeps against the heap limit, new through an empty-handler proxy of a built-in constructs it, and revoke has its standard name and length. Object.freeze, seal, isFrozen and isSealed throw a TypeError for a proxy whose target chain has Symbol properties.
Function.prototype.bind reads a proxy's prototype through its trap, Object.prototype.toString reads a proxy's Symbol.toStringTag from its target, Reflect.set writes a typed array's elements, a super assignment runs the set trap of a proxy on the home object's chain, and 'in' asks a proxy's has trap once. The name a trap is given is counted against the heap and fuel limits, and Proxy and Reflect stay reachable while their functions are installed.
The Libraries panel accepted a swatch row dragged before File › Revert and added the restored swatch of that name. Membership::grabbed now refuses stale rows, for the hover marker and on release.
A sliver at 0% opacity, or inside a group or layer at 0% opacity, paints
nothing, so Clean Up and Select > Object > Hairline Slivers now skip it.
The params text and docs/mcp.md say so, and docs/mcp.md also names what a
group or compound path used as a clipping path holds among the objects
both commands leave.
#9931 refused an appearance carried across File › Revert. Graphic styles,
brushes, symbols, swatch rows and appearance stack rows had the same fault:
a held drag still resolved a name or id against the restored contents.
- Graphic style, brush, symbol and swatch drags carry the document's revert
count, and the canvas, the panels, the Fill/Stroke wells and the Gradient
slider refuse a drag from before the revert.
- The Brushes panel shows no reorder marker for a stale brush drag.
- docs/mcp.md says which drops File › Revert cancels.
Follows #9931 by @dotCooCoo.
app.redraw() changes nothing, so docs/mcp.md now describes it on its own. The undo step a run
leaves is stated for documents that were open before the run and are still open after it.
main's own indexer tests already check the receiver's and the key's limits.
Proxies join main's construct path in class_ops.rs: new and Reflect.construct both run the construct trap there, with new.target passed through. A Symbol-key lookup passes through a proxy to its target, so spread and for-of read a proxy of an array with the array iterator.
The progress lines for the ES5 language runs, the ECMAScript 2015
collections and binary data runs, and the generator runs gave counts from
before later changes. On main at 0ac2b74614, cargo xtask test262 reports
4,676 of 4,682 ES5 language runs, 1,514 of 1,514 collection and binary
data runs, and 1,285 of 1,289 generator runs (669 tests) passing. The
generator tests that use classes now parse, so the 4 remaining generator
failures are the caller and arguments restrictions.