Repository navigation
Conversation
…nstanceof Symbol values are heap cells (one per Symbol, so identity is equality), the 13 well-known ones made with the VM; a Symbol is a property key through clazel-js-heap's symbol contract (Y4), which the interner never collides with. typeof, ToPropertyKey, ToString/ToNumber (TypeError), ToObject, IsLooselyEqual, SetFunctionName of a computed method key and ToPrimitive's @@toPrimitive now see them; own_properties stays String-keyed and own_symbol_properties lists the rest. The ops GetIterator, IterNext, IterClose (§7.4), ForInIterator (§14.7.5.9), CallSpread, NewSpread, InstanceOf (§13.10.2 with @@hasInstance and OrdinaryHasInstance), ToObject and ThrowIfNotObject run. An Iterator Record is a heap cell only registers hold. The iterators themselves are built-ins, so a bare VM has nothing iterable. The built-ins runner classes a missing eval reported inside a test's own Test262Error, and lists 10.1.1-11-s.js (reached now that instanceof runs). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Symbol (§20.4) with Symbol.for/keyFor, the well-known symbols and Symbol.prototype; %Iterator.prototype%, the Array and String iterators (§23.1.5, §22.1.5); Function.prototype[@@hasInstance]; @@toStringTag in Object.prototype.toString and on Math, JSON and the iterator prototypes; Object.prototype.toLocaleString. Array: from, at, copyWithin, entries, keys, values (= @@iterator), findLast, findLastIndex, flat, flatMap, toLocaleString, toReversed, toSorted, toSpliced, with, @@unscopables; concat reads @@isConcatSpreadable and ArraySpeciesCreate reads @@species (the constructor itself while get Array[@@species], an accessor, is missing). Spread, for-of and destructuring over arrays and strings now run end to end (tests/iteration.rs). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
String: fromCodePoint, raw, and at, codePointAt, concat, endsWith, includes, isWellFormed, lastIndexOf, localeCompare, match, matchAll, padEnd, padStart, repeat, replace, replaceAll (GetSubstitution), search, split, startsWith, toLowerCase/toUpperCase (and the locale forms), toWellFormed, trim, trimEnd, trimStart, @@iterator, and Annex B substr, trimLeft, trimRight. The RegExp-taking methods delegate to a pattern's @@match/@@replace/... and are NotYet otherwise (no RegExp yet). Number: toExponential, toPrecision (clazel-js-number) and toLocaleString. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Installing the built-ins grew with Symbol, the iterators and String (about 25 s a case under Miri), so builtins.rs takes the stride the other built-in tests use, which keeps each test well under xtask's 300 s limit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…the NewRegExp handler ObjKind::Host objects hold the internal slots of a built-in (Promise, RegExp); natives can carry captured values (the closures of the standard); the job queue (HostEnqueuePromiseJob) runs at the embedder's microtask checkpoint; NewRegExp calls %RegExp% (RegExpCreate). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rror Promise (constructor, all, allSettled, any, race, reject, resolve, try, withResolvers, then, catch, finally) over the VM's host objects and job queue; AggregateError; SpeciesConstructor and Invoke helpers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ods that use it RegExp (constructor, escape, exec, test, toString, compile, @@match, @@matchall, @@replace, @@search, @@split, RegExp String Iterator) over clazel-js-regexp, with the backtrack stack bounded (RangeError) and the termination flag as the matcher's interrupt; String.prototype.match, matchAll and search make a RegExp; GetSubstitution takes named captures; Object.prototype.toString knows RegExp. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CreateUnmappedArguments, CreateMappedArguments (without the parameter map) and CreateRestArray: a call of a function that reads its arguments keeps its argument list, since the frame has slots for the parameters only. try/catch/ finally and throw already compiled and ran; tests cover them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…s per directory The vendored WPT testharness.js loads in its shell environment and runs sync and promise tests through Promise, RegExp and the job queue. The Test262 runner prints pass, expected failure and failure per directory. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
atiernan
had a problem deploying
to
full-verification
November 23, 2026 18:53 — with
GitHub Actions
Error
Member
Author
|
Contained in #302 (engine: Object, classes, Map/Set, Reflect), which merges this branch; one verification. Branch kept. |
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Phase 7, items 7.9 (
Promiseand the job queue) and 7.10 (RegExp's object half and the String methods that use it), built on #292 (claude/js-builtins-3).What is in it
clazel-js-vmhostmodule: host objects with internal slots (ObjKind::Host), native functions with captured slots (the closures of the standard), and the job queue (enqueue_job,run_jobs,take_job_errors). The VM never runs the queue by itself: the embedder runs it at its microtask checkpoint.NewRegExphandler: a regular expression literal calls%RegExp%(RegExpCreate), so the 57 Test262 literal tests that waited on it now run.argumentsobject and rest parameters (CreateUnmappedArguments,CreateMappedArguments,CreateRestArray): a call of a function that reads them keeps its argument list, since the frame has slots for the parameters only. Deviation: the sloppy object has no parameter map (no aliasing), and a strictarguments.calleeis absent (it is an accessor; the VM has none).clazel-js-builtinsPromise: constructor,all,allSettled,any,race,reject,resolve,try,withResolvers,then,catch,finally,@@toStringTag;AggregateError;SpeciesConstructor/Invokehelpers.RegExp: constructor,RegExp.escape,exec,test,toString,compile(Annex B),@@match,@@matchAll,@@replace,@@search,@@split, the RegExp String Iterator; overclazel-js-regexp.String.prototype.match,matchAll,searchmake a RegExp (RegExpCreate) and invoke it;replace,replaceAllandsplitdelegate to the@@methods, as before;IsRegExpsees[[RegExpMatcher]];GetSubstitutiontakes named captures;Object.prototype.toStringknows RegExp and Arguments.promise.rsandregexp.rs.try/catch/finallyandthrowwere already compiled and run (the report that "the engine lacks try/catch" does not hold on this base);tests/arguments.rsnow covers them.testharness.js(the vendored WPT one) loads and runs:tests/testharness.rsrunstest, a failing assert, a throwing test and apromise_testin the harness's shell environment, throughPromise,RegExp, the job queue,argumentsand rest parameters.The matcher's limits and #296
The backtrack stack is bounded and the excess is a
RangeError(tests/regexp.rsmakes a 1.4M-character match overflow it); the VM's termination flag is the matcher's interrupt hook (a catastrophic pattern ends asTerminated). #296 is not in this base, so the integration point is one function,regexp::backtrack_limit(vm): it returns the matcher's default (a million entries) today, and becomesusize::try_from(vm.regexp_backtrack_limit()).unwrap_or(usize::MAX)onceVm::regexp_backtrack_limit(#296) is merged.Test262
built-ins/is not vendored (SOURCE.md: it joins with the items that record it), so the recorded suite is still the table through the interpreter (tests/conformance_builtins.rs): 552 -> 614 pass, 0 fail of 5,212 (the difference is the regular expression literal tests and the three that readarguments;language/literals/regexp: 28 pass, the other 210 are the parser's negative tests). The runner now also prints pass, expected failure and failure per directory.A spot check of the unvendored directories, from a checkout of
tc39/test262atebf6ae6(HEAD today, not the vendored commit; scratch runner, not committed), real harness files, sloppy and strict, 2-5 s per test:built-ins/Promisebuilt-ins/RegExp(withoutproperty-escapesand onematch-indicesfile: not run, too slow in debug)Almost every failure is outside this change:
propertyHelper.jsneedsObject.getOwnPropertyDescriptorand the rest ofObject(about 207 of the failures); accessor property descriptors (104, one isPromise.allKeyed, a proposal newer than the edition: 74),class(37),Proxy,Reflect,eval,Map; 29 negative RegExp literal tests the parser does not reject (early errors of a literal's pattern are not checked byclazel-js-syntax). In this change: about ten tests that redefineglobal/unicodeon an instance and expectflagsto follow (the accessor deviation below).Deviations (all listed in the module headers)
RegExp.prototype.flags/source/global/...are own non-writable data properties of each instance;get Promise[@@species]andget RegExp[@@species]are data properties holding the constructor.HostPromiseRejectionTrackeris not called; the legacyRegExp.$1static properties are absent.Vec<u16>, so a globalreplaceover a long string is quadratic.Not done
property-escapesTest262 run; vendoringtest/built-ins/PromiseandRegExpinto the table (it changesxtaskand every crate that reads the table).class extends Promise): the VM has no class constructors yet.argumentsparameter mapping.Verification
cargo xtask verify --changed origin/claude/phase7-integration(rustfmt, clippy, tests, Miri, Kani and Verus forclazel-js-vm, mutations 237/237 killed, conformance) passed every step except the last, which is the known base-branch issue:The missing rows are crates this change does not touch (docs/STATUS.md is not edited). CI's full verification has not run on this pull request (the proof jobs wait for approval), so nothing here is "done" yet in the sense of CLAUDE.md.
🤖 Generated with Claude Code