This document outlines the breaking changes and improvements in version 3.
Issue: The expression parser does not support inline nested array literals like [[\"a\", 1], [\"b\", 2]].
Workaround: Pass nested arrays via the input object:
// Instead of (doesn't work):
ruleFactory('UNZIPDICT([["a", 1], ["b", 2]])')()
// Use this (works):
ruleFactory('UNZIPDICT(pairs)', { return: 'result' })({
pairs: [['a', 1], ['b', 2]]
})Affected Functions:
DICT(keys, values)- Works when keys/values come from inputUNZIPDICT(pairs)- Works when pairs come from input
Future: In v4, we may vendor the expression parser to add full nested literal support.
Test coverage improved from 68.86% to 87.58%:
- language.ts: 54.42% β 78.58% (+24.16%)
- executor.ts: 90.48% (branch coverage 82.56% β 83.78%)
- utils.ts: 45.28% β 100% (+54.72%)
- engine.ts: 83.33% β 100% (+16.67%)
- language-utils.ts: 58.85% β 98.85% (+40%)
- 267 total tests (up from 51)
- Comprehensive math function tests
- Array function tests
- Object function tests
- Executor edge case tests
- Error handling tests
No migration needed for existing code. The nested array limitation only affects new code patterns that weren't previously documented or tested.