Skip to content

Releases: raleksandar/numenor

v0.0.7 - Parselet context

24 Feb 03:14
v0.0.7
a67b637
Compare
Choose a tag to compare
Pre-release

Parser.parseletContext API is introduced.
Parslet context is an opaque value which is passed down to every parslet as the last argument.

V0.0.6 - Custom object/array prototypes

24 Feb 03:11
v0.0.6
8494174
Compare
Choose a tag to compare
Pre-release
  • The monolithic lexer is now split into a multiple reusable scanners
  • StackPush was erroneously being marked as the constant expression if its value was constant
  • ObjectPrototype and ArrayPrototype compiler options introduced
    • ObjectPrototype is used for the objects created via object literals (i.e. Object.create(ObjectPrototype))
    • ArrayPrototype is used when traversing the prototype of an array value (with NoProtoAccess: false)
    • default ArrayPrototype with the following methods is provided: concat, every, filter, find, findIndex, forEach, includes, indexOf, join, lastIndexOf, map, reduce, reduceRight, slice, some, toString (i.e. all the standard non-mutating methods from Array.prototype, with polyfills for less-supported ones)
  • EnforceMarshalling compiler options is introduced which, when set, forces the array values which exit the evaluator (either as an argument to a function or as the expression return value) to have ArrayPrototype set as their prototype (this is avoided during expression evaluation as Object.setPrototypeOf can be expensive)

v0.0.5 - CTFE + NoProtoAccess

20 Feb 15:47
v0.0.5
22e1eb1
Compare
Choose a tag to compare
Pre-release

This release brings following features and improvements:

  • support for compile-time constants
  • support for compile-time function evaluation (CTFE) - if a function itself is a "constant" (it is provided in CompilerOptions.Constants) and all of the arguments passed to it are constant expressions it will be evaluated at compile-time
  • support for CompilerOptions.NoProtoAccess which disallows traversing of prototype chain when using member access, computed member access, or in expressions (NoProtoAccess defaults to true)
  • access to __proto__ in any context is disallowed and will throw TypeError (regardless of compiler options)
  • constant folding is improved, compiler will create fewer wrapper functions
  • functions are now invoked using correct thisArg (i.e. a.b.f(x) is evaluated as a.b.f.call(a.b, f) which was always the expected behavior but wasn't working until now)

v0.0.4 - Mutating accessor (inc/dec) operators

19 Feb 12:49
v0.0.4
9ae73eb
Compare
Choose a tag to compare

This release introduces post- and pre-increment/decrement operators

v0.0.3 - Null-conditional/-coalesce operators

19 Feb 01:23
v0.0.3
6d051d6
Compare
Choose a tag to compare

This release includes bugfixes which make null-conditional (?.) and null-coalesce (??) operators work again.

v0.0.2 - First public release

19 Feb 00:11
v0.0.2
88feae1
Compare
Choose a tag to compare
Pre-release

Still not tested enough and API may change, so don't use this yet! :)