Repository navigation
Releases: mark1russell7/coeval
Release list
v0.22.0
MINOR: before 1.0.0, a breaking change increases MINOR. A deep recursion through closures gives #DEPTH! at a lower depth than before. No export goes.
Changes of behavior
- A clock for
callgives one#DEPTH!in each tier (D125). Each application of a closure offncounts one level. An application bycalland an application by an operation of the host both count. The clock permitsceil(maxDepth / 4)levels, thus 250 for the defaultmaxDepthof 1000.- In 0.21.0, an endless recursion stopped at the stack of the host. It gave
#DEPTH!with aRangeErroras its cause, at a place that changed with the tier. - In 0.22.0, it gives
#DEPTH!with the reason "The applications of functions nest deeper than 250 levels." The document that applies the closure gets the place, in each tier. - The break: a finite recursion of 251 to approximately 1600 nested applications gave its value in 0.21.0. In 0.22.0, it gives
#DEPTH!. A host that needs a deeper recursion sets a largermaxDepth. - The limit comes from one measure. On Node.js 24.21.0 on Windows, the reference tier overflowed the stack of the host after 937 applications, and the plan after 1595.
- The test FORMULA.CALL-DEPTH runs the reference at twice the default limit with no
RangeError. Thus a Node.js version with a smaller stack fails that test in CI first.
- In 0.21.0, an endless recursion stopped at the stack of the host. It gave
New features
- Attributes with parameters (D124). The new table
tree.atof a tree contract gives an attribute with parameters an entry{ params, equation }. The new standard steptree.atwith the fieldsattrandargsreads an instance of the node. For example, a parent asks for the height of a child at a given width.- The equation sees each parameter as a name, for example
names.width. A missing or an extra argument gives#VALUE!. - Two arguments share one memo entry only when they are equal by DOC.EQUALS. A host with cells gets one cell for each instance.
checkexamines each entry and each step with literal arguments. The graph of attribute instances gives an exact vertex for such a step, with the new fieldargs.- An entry cannot be
circularorcollect. The text syntax has no form forargs, thus a step with arguments is a document. - The new exports are
AtArgs,AtEquation,AtRule,argsKey,atArgsOfandatRuleOf.
- The equation sees each parameter as a name, for example
v0.21.0
MINOR: before 1.0.0, a breaking change increases MINOR. typeFromSchema gives a narrower type for a schema with more than one of type, anyOf and oneOf. check finds more type issues. No export goes.
Changes of behavior
typeFromSchemagives the meet of the keywords of a schema (D123). In 0.20.1, a schema with more than one oftype,anyOfandoneOfgave the type of the first keyword, with an issue. This rule came from D28. In 0.21.0, the type is the meet of all the keywords. For example,{type:"number", anyOf:[{type:"string"}]}wasnumber, and in 0.21.0 it isnever. Each reading only narrows, and each reading stays sound.- A step that reaches nothing in each run is a type issue (D120). In 0.20.1, some steps gave the type
unknownwith no issue. They are a field step on a kernel base type, a step on a function, and an unknown step on a list. In 0.21.0,checkgives the issue of a missing field, as for a closed record (TYPE.NO-STEP). - The reason of a missing field names a step document by its kind (D121). In 0.20.1, the reason showed
[object Object]for a step document. In 0.21.0, it shows the kind in parentheses.
New features
typeFromSchemareads local references andallOf(D123). A$refto#/$defs/<name>or#/definitions/<name>reads that definition of the root schema. A reference to another file, a missing definition and a cycle of references read asunknown. The parts ofallOfadd their keywords to the schema.- Collection attributes and a registry of names (D122). A declaration
collect: { unit, combine }combines the contributions of a subtree. A kind contributes through its equation intree.contributes. The formcollect: "names"gives a registry from the header name of each node to its node. The new standard steptree.namedreads the registry. Two nodes with one name give#VALUE!at the read of the registry. The new exports areCollectDeclaration,CollectRuleandcollectOf. - A walker holds the type rule of its step (D121). A walker can hold an optional rule in its field
type. The check then knows the type of what the walker reaches. A plain function stays a walker. The new export isWalkTypeInput. - A kind declares the parts that its runner drives (D119).
KindFactsgets the optional fielddrives. In a check of a run, a part thatdrivesnames gets no wait. - The hook
factsgives the effects of a code (D118).KindFactsgets the optional fieldeffects. For the verbeval, the answer of the hook for the code wins over the contract.effectsOf,checkandfactsOfuse that one declaration.
Tests and CI
These changes are not in the package. The margin and the noise cap of each case family of the bench come from the A/A records of CI (D117).
v0.20.1
PATCH: before 1.0.0, a new feature increases PATCH. The new exports change nothing that exists.
New features
- A ladder of steps for each language (D116). A language declares its steps, from the lowest to the highest, and the step of each construct as data with
stepLadder.stepOfgives the lowest step that a document needs, with the first node that needs it.checkSteprefuses a document above the highest step that the host accepts, and the refusal names the needed step. The new exports areStepKey,StepLadder,StepNeed,StepReason,StepRefusal,StepWalk,checkStep,isStep,stepLadder,stepOfandstepRank.
v0.20.0
MINOR: before 1.0.0, a breaking change increases MINOR. A node with the cells of a host gets a new key, and the place of such a node is a new array. Circular attributes are a new feature. No export goes.
Changes of behavior
- The cells of a host are kept for each node in its scope (D115). In 0.19.0, the nodes that an equation plan makes had the same place in each document. A host that keeps cells by place thus gave the cell of one document to another, and two cards of one document shared one cell. In 0.20.0, the kit gives each node one key in its scope. The type of
AttributeCelldoes not change. A host that keys cells by the identity ofplace, as D108 tells, needs no change. - A nested evaluation gets its own cycle marks (D115). In 0.19.0, a cell compute that evaluated a second document of the same plan could get a false
#CYCLE!. In 0.20.0, the marks and the tree of a root use the key of the node. - The place of a node with host cells is its key (D115).
placeOfand the place of an error give an array with the same items as before, but a new array.
New features
- Circular attributes (D113). An attribute that declares
circular: { start, limit }evaluates its cycle again until no value changes, by the demand algorithm of Magnusson and Hedin. A cycle that is not stable at the limit gives#CYCLE!. The default limit is 100 rounds. A cycle with a plain attribute gives#CYCLE!as before. checkandattributeGraphknow circular cycles (D113). They accept a certain cycle only when each of its attributes is circular. The new exports areCircularDeclaration,CircularRule,CIRCULAR_LIMITandcircularOf. Documents withoutcircularevaluate as before.
Tests and CI
These changes are not in the package. The bench uses @mark1russell7/rigor-bench for its runner, its orders, its medians, the A/A noise, the bound and the pooled verdict (D114). Its verdicts are same, faster, slower and cannot decide.
v0.19.0
MINOR: before 1.0.0, a breaking change increases MINOR. check finds more issues in trees, encodeValue can give a different document, and factsOf gives other facts for a verb other than eval. The type of WorldIssue.code gets a second value. No export goes.
Changes of behavior
checkfinds attribute faults of a tree (D106). In 0.18.0,checkaccepted a read of an attribute that no rung answers, and the run gave#N/A. In 0.19.0,checkgives that#N/Aat the same place before a run. It also gives#NAME?for an attribute namedparentortype, and#CALC!for a tree kind of the run side.checkfinds the cycles of attributes (D107). In 0.18.0, a cycle of tree attributes gave#CYCLE!only in a run. In 0.19.0,checkgives that#CYCLE!before a run for each certain cycle, with the same place and reason. A cycle through a lazy branch or an unknown read is not an issue.encodeValueuses the codec of the most specific domain (D109). In 0.18.0, it tried the domains with a codec in the order of their names. Thus a parent with an early name encoded the members of its subdomains. In 0.19.0, it tries the deepest domain first. Names decide only between domains of the same depth. A table where no codec domain has a parent gives the same documents as before.factsOfgives the facts of a verb from its own contract (D111). In 0.18.0,factsOfwith a verb other thanevalgave the side and the effects of theevalcontract. In 0.19.0, it gives the effects that the entry of the verb inverbEffectsdeclares. A kind is on the run side for that verb only when its entry declares an effect. A kind without an entry adds nothing, as incheck.WorldIssue.codecan be#TYPE!(D110). In 0.18.0, its type was only"#NOEVAL". In 0.19.0, it is"#NOEVAL" | "#TYPE!". Code that givesissue.codeto the literal type"#NOEVAL"does not compile. Calls without the new option give the same issues as before.
New features
attributeGraphgives the graph of the attribute instances of a tree (D107). It gives one vertex for each node and attribute, one edge for each read, the edges with an unknown source, and the certain cycles.attributeVertexIdgives the id of a vertex.treeNodeEvaluator({ cell })takes the memo cells of a host (D108). A host can keep the cell of each attribute between evaluations of one plan. A change of its store then computes only the attributes whose cells it drops. Withoutcell, the standard code does not change.checkWorld(machine, verbs, { types: true })checks each value type of a machine (D110). In 0.18.0,checkfound a bad value type of a contract, a domain or a signature only at the first document that used it. In 0.19.0, this option finds each bad value type before a document exists. Each bad term gives one#TYPE!issue, with its owner and its keys inat. A type rule lists what it reads with the new optional fielddeclared.printReadsfinds a host value that changed in place (D112). In 0.18.0,verifyReadscompared host values by identity, so a value changed in place kept a stale result. In 0.19.0,printReadsand theverifyReadsoptionprintsfind such a change, and give the changed read withinPlace: true.durableandscheduletake the optioninPlace. Without the new options, nothing changes.
Tests and CI
These changes are not in the package. Each bench record names its mode (K199). The ladder of STATIC.LINEAR also measures the memory of each walk (D105).
v0.18.0
MINOR: before 1.0.0, a breaking change increases MINOR. conforms tests more members of a domain. Thus a profile that conformed under 0.17.0 can fail. No export goes.
Changes of behavior
conformstests the covers of a machine (D94). In 0.17.0,conformsdid not test a cover. In 0.18.0, the new checkcovertests each covered domain with samples. A sample that no domain of the cover holds is a finding.- A domain gives samples of its members (D99). In 0.17.0, the checks
truthandcovertestednumberonly with1and2. In 0.18.0, they also test0and-1. Thus a truth or a cover that passed in 0.17.0 can fail. - A cause that is a list or a record keeps its items (D100). In 0.17.0, the cause
{ send: () => 1, code: 7 }of an exception was the namecauseindropped. In 0.18.0,causePartsholds the recordcode, anddroppedholds onlycause.send. This rule applies also to an error value without an exception. - A shared list or record decodes as one object (D101). In 0.17.0, the record
{ code: 7 }in the fieldsaandbgave two term documents.decodeLogthen gave two copies. In 0.18.0,ais the partrecord, andbis{ share: 0 }.decodeLoggives one object. A log of 0.17.0 decodes as two copies, as before. fitstries each valid cover of a field (D102). In 0.17.0,{a: number}did not fit{a: lo} | {a: hi}whenloandhiare the second cover ofnumber. In 0.18.0, it fits. Thus a check accepts some programs that it refused before.- A run gives the host no effect that its parent cannot wait for (D91, RUN.HELD). In 0.17.0, a host that waits did such an effect, and the run then dropped its result. In 0.18.0, the effect does not reach the host, and it keeps
#CALC!.
New features
Obligationhas the new valuecover(D94). A switch over the obligations sees a new case.Domain.samplesis a new optional field (D99). A merge of two domains that differ only insamplesis a conflict.FormulaProfile.extTypesgives the value type of each own extension (D103). In 0.17.0, a check with types gaveunknownto an own extension. In 0.18.0, an entry inextTypesgives the declared type. A use that does not fit it gets#TYPE!. A profile withoutextTypesgets the same types and issues as before.
Tests and CI
These changes are not in the package. Each numeric limit of a unit test comes from CI runs (D95, D104). The bench starts each case in its own processes (D98). A ladder measures the slope of STATIC.LINEAR (D97).
v0.17.0
- Version 0.17.0 of
@mark1russell7/coevalon npm.
v0.16.0
- Version 0.16.0 of
@mark1russell7/coevalon npm.
v0.15.0
- Version 0.15.0 of
@mark1russell7/coevalon npm.
v0.14.0
- Version 0.14.0 of
@mark1russell7/coevalon npm.