solve-engine 1.2.0 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -17
- package/dist/{BytecodeBuilder-Bp9xeTmX.d.cts → BytecodeBuilder-DGGeByAP.d.cts} +18 -0
- package/dist/{BytecodeBuilder-Bp9xeTmX.d.ts → BytecodeBuilder-DGGeByAP.d.ts} +18 -0
- package/dist/{Configuration-C9W8tJv_.d.cts → Configuration-B6W0-T67.d.cts} +17 -4
- package/dist/{Configuration-C9W8tJv_.d.ts → Configuration-B6W0-T67.d.ts} +17 -4
- package/dist/{EngineError-CNA_rHY-.d.cts → EngineError-Ce1lPkjZ.d.cts} +2 -0
- package/dist/{EngineError-CNA_rHY-.d.ts → EngineError-Ce1lPkjZ.d.ts} +2 -0
- package/dist/{PackageCompatibility-B6NX9IaN.d.cts → PackageCompatibility-Bn5jnBtA.d.cts} +2 -2
- package/dist/{PackageCompatibility-Ceg5XdAp.d.ts → PackageCompatibility-CIvq2MP5.d.ts} +2 -2
- package/dist/{PackageRegistry-DrCPQNyy.d.ts → PackageRegistry-DzeiWcv4.d.ts} +93 -172
- package/dist/{PackageRegistry-DnJYVw9G.d.cts → PackageRegistry-dpdurBVO.d.cts} +93 -172
- package/dist/{Parselet-Bhf7d0_W.d.ts → Parselet-B-zoPrTa.d.ts} +8 -5
- package/dist/{Parselet-Cv7S7KRt.d.cts → Parselet-C4Wu055_.d.cts} +8 -5
- package/dist/{ScopeManager-Bzq87GfA.d.ts → ScopeManager-C2LDOrDx.d.ts} +7 -16
- package/dist/{ScopeManager-DRDBVfan.d.cts → ScopeManager-D7uMXbhS.d.cts} +7 -16
- package/dist/{VMCheckpoints-C6c17Hbo.d.ts → VMCheckpoints-CGyFhivM.d.ts} +3 -3
- package/dist/{VMCheckpoints-dZxSMGHG.d.cts → VMCheckpoints-I9jg3jWR.d.cts} +3 -3
- package/dist/{Value-DZNQ_PU7.d.cts → Value-CCi_Eecs.d.cts} +40 -0
- package/dist/{Value-DZNQ_PU7.d.ts → Value-CCi_Eecs.d.ts} +40 -0
- package/dist/{WorkerError-Djd7GGGa.d.cts → WorkerError-B4p6PNfx.d.cts} +1 -1
- package/dist/{WorkerError-B7t7R2-m.d.ts → WorkerError-Dhj9BQ_A.d.ts} +1 -1
- package/dist/chunk-2JMFUQZH.js +2 -0
- package/dist/chunk-2JMFUQZH.js.map +1 -0
- package/dist/chunk-2RWAXT6O.js +0 -1
- package/dist/chunk-4BZIYU7S.cjs +3 -0
- package/dist/chunk-4BZIYU7S.cjs.map +1 -0
- package/dist/chunk-4J7XZSZJ.cjs +5 -0
- package/dist/chunk-4J7XZSZJ.cjs.map +1 -0
- package/dist/chunk-4QVBSG6B.cjs +2 -0
- package/dist/chunk-4QVBSG6B.cjs.map +1 -0
- package/dist/chunk-5IJD5L3O.cjs +2 -0
- package/dist/chunk-5IJD5L3O.cjs.map +1 -0
- package/dist/chunk-62LMTO4F.js +2 -0
- package/dist/chunk-62LMTO4F.js.map +1 -0
- package/dist/chunk-6CY44ZPG.js +2 -0
- package/dist/chunk-6CY44ZPG.js.map +1 -0
- package/dist/chunk-6G3PMEPA.js +2 -0
- package/dist/chunk-6G3PMEPA.js.map +1 -0
- package/dist/chunk-6INX773F.cjs +2 -0
- package/dist/chunk-6INX773F.cjs.map +1 -0
- package/dist/chunk-6KFVG6UY.cjs +2 -0
- package/dist/{chunk-YJHY7CMN.cjs.map → chunk-6KFVG6UY.cjs.map} +1 -1
- package/dist/chunk-76F3LCIL.js +4 -0
- package/dist/chunk-76F3LCIL.js.map +1 -0
- package/dist/chunk-7GK3XEZF.js +2 -0
- package/dist/chunk-7GK3XEZF.js.map +1 -0
- package/dist/chunk-APN442VD.cjs +2 -0
- package/dist/chunk-APN442VD.cjs.map +1 -0
- package/dist/chunk-AXMQG5TS.cjs +2 -0
- package/dist/chunk-AXMQG5TS.cjs.map +1 -0
- package/dist/chunk-CIQOK7Q4.cjs +2 -0
- package/dist/chunk-CIQOK7Q4.cjs.map +1 -0
- package/dist/chunk-E6Z4NQAS.js +2 -0
- package/dist/chunk-E6Z4NQAS.js.map +1 -0
- package/dist/chunk-EFJCC6FJ.cjs +2 -0
- package/dist/chunk-EFJCC6FJ.cjs.map +1 -0
- package/dist/chunk-ESUN2THE.cjs +2 -0
- package/dist/chunk-ESUN2THE.cjs.map +1 -0
- package/dist/chunk-EVAOPEO4.js +2 -0
- package/dist/chunk-EVAOPEO4.js.map +1 -0
- package/dist/chunk-EYRBENHC.js +3 -0
- package/dist/chunk-EYRBENHC.js.map +1 -0
- package/dist/chunk-FDE5HWDI.cjs +2 -0
- package/dist/chunk-FDE5HWDI.cjs.map +1 -0
- package/dist/chunk-FWW3M36J.cjs +2 -0
- package/dist/chunk-FWW3M36J.cjs.map +1 -0
- package/dist/chunk-GOIQYUWV.js +2 -0
- package/dist/chunk-GOIQYUWV.js.map +1 -0
- package/dist/chunk-HFKDWQUL.js +2 -0
- package/dist/chunk-HFKDWQUL.js.map +1 -0
- package/dist/chunk-HLBYHXQD.cjs +3 -0
- package/dist/chunk-HLBYHXQD.cjs.map +1 -0
- package/dist/chunk-IANAMBJQ.cjs +2 -0
- package/dist/chunk-IANAMBJQ.cjs.map +1 -0
- package/dist/chunk-IJMNVBIS.js +2 -0
- package/dist/chunk-IJMNVBIS.js.map +1 -0
- package/dist/chunk-J4LZD4ZY.js +3 -0
- package/dist/chunk-J4LZD4ZY.js.map +1 -0
- package/dist/chunk-JAK3RAFA.cjs +2 -0
- package/dist/chunk-JAK3RAFA.cjs.map +1 -0
- package/dist/chunk-JFAJN3C2.cjs +2 -0
- package/dist/chunk-JFAJN3C2.cjs.map +1 -0
- package/dist/chunk-JPFCXLJV.js +2 -0
- package/dist/chunk-JPFCXLJV.js.map +1 -0
- package/dist/chunk-JSPKKNPQ.js +3 -0
- package/dist/chunk-JSPKKNPQ.js.map +1 -0
- package/dist/chunk-L3FPQSGN.js +2 -0
- package/dist/chunk-L3FPQSGN.js.map +1 -0
- package/dist/chunk-LR4E4A4W.cjs +2 -0
- package/dist/chunk-LR4E4A4W.cjs.map +1 -0
- package/dist/chunk-MIQBJGGR.js +2 -0
- package/dist/chunk-MIQBJGGR.js.map +1 -0
- package/dist/chunk-MPB7KUN5.js +3 -0
- package/dist/chunk-MPB7KUN5.js.map +1 -0
- package/dist/chunk-MSYX32PF.cjs +2 -0
- package/dist/chunk-MSYX32PF.cjs.map +1 -0
- package/dist/chunk-MVZUTETT.js +2 -0
- package/dist/chunk-MVZUTETT.js.map +1 -0
- package/dist/chunk-N7N7MPMK.cjs +2 -0
- package/dist/chunk-N7N7MPMK.cjs.map +1 -0
- package/dist/chunk-NGBBNL4K.cjs +1 -3
- package/dist/chunk-P6WPEUAJ.cjs +2 -0
- package/dist/chunk-P6WPEUAJ.cjs.map +1 -0
- package/dist/chunk-PS272DZJ.cjs +2 -0
- package/dist/chunk-PS272DZJ.cjs.map +1 -0
- package/dist/chunk-QXQE7X4S.js +2 -0
- package/dist/chunk-QXQE7X4S.js.map +1 -0
- package/dist/chunk-R2ENWQ76.js +2 -0
- package/dist/chunk-R2ENWQ76.js.map +1 -0
- package/dist/chunk-R2SZFJTT.cjs +2 -0
- package/dist/chunk-R2SZFJTT.cjs.map +1 -0
- package/dist/chunk-RAF57WYO.js +2 -0
- package/dist/chunk-RAF57WYO.js.map +1 -0
- package/dist/chunk-RSF25YSJ.js +2 -0
- package/dist/chunk-RSF25YSJ.js.map +1 -0
- package/dist/chunk-SOMGSIO4.cjs +3 -0
- package/dist/chunk-SOMGSIO4.cjs.map +1 -0
- package/dist/chunk-SUXRZWH2.cjs +3 -0
- package/dist/chunk-SUXRZWH2.cjs.map +1 -0
- package/dist/chunk-SYYE3QAX.cjs +2 -0
- package/dist/chunk-SYYE3QAX.cjs.map +1 -0
- package/dist/chunk-SZGK6RIP.cjs +2 -0
- package/dist/chunk-SZGK6RIP.cjs.map +1 -0
- package/dist/chunk-TCZSPH4A.js +2 -0
- package/dist/chunk-TCZSPH4A.js.map +1 -0
- package/dist/chunk-TLG7VZRX.cjs +2 -0
- package/dist/chunk-TLG7VZRX.cjs.map +1 -0
- package/dist/chunk-TRBXW6HW.js +2 -0
- package/dist/{chunk-AQNHHJMJ.cjs.map → chunk-TRBXW6HW.js.map} +1 -1
- package/dist/chunk-TTFO4YDP.cjs +2 -0
- package/dist/chunk-TTFO4YDP.cjs.map +1 -0
- package/dist/chunk-TWC7K3ZX.js +2 -0
- package/dist/chunk-TWC7K3ZX.js.map +1 -0
- package/dist/chunk-UDQ57ZRX.cjs +2 -0
- package/dist/chunk-UDQ57ZRX.cjs.map +1 -0
- package/dist/chunk-UI6IFGBT.js +2 -0
- package/dist/chunk-UI6IFGBT.js.map +1 -0
- package/dist/chunk-UURM7P3P.cjs +4 -0
- package/dist/chunk-UURM7P3P.cjs.map +1 -0
- package/dist/chunk-W2JAR233.js +2 -0
- package/dist/chunk-W2JAR233.js.map +1 -0
- package/dist/chunk-WGZ3FNHI.js +2 -0
- package/dist/chunk-WGZ3FNHI.js.map +1 -0
- package/dist/chunk-WN5CMP4T.cjs +3 -0
- package/dist/chunk-WN5CMP4T.cjs.map +1 -0
- package/dist/chunk-XEIDV5JP.js +2 -0
- package/dist/chunk-XEIDV5JP.js.map +1 -0
- package/dist/chunk-XNIWQHXY.js +2 -0
- package/dist/chunk-XNIWQHXY.js.map +1 -0
- package/dist/chunk-XR7HEC7B.js +5 -0
- package/dist/chunk-XR7HEC7B.js.map +1 -0
- package/dist/chunk-Y7O4D3BJ.cjs +2 -0
- package/dist/chunk-Y7O4D3BJ.cjs.map +1 -0
- package/dist/chunk-YAYBVVG2.js +3 -0
- package/dist/chunk-YAYBVVG2.js.map +1 -0
- package/dist/chunk-YJ2OPULK.js +2 -0
- package/dist/chunk-YJ2OPULK.js.map +1 -0
- package/dist/chunk-YVKHEAFT.js +2 -0
- package/dist/chunk-YVKHEAFT.js.map +1 -0
- package/dist/chunk-ZCNBT44X.cjs +2 -0
- package/dist/chunk-ZCNBT44X.cjs.map +1 -0
- package/dist/chunk-ZLRJ7TDP.cjs +2 -0
- package/dist/chunk-ZLRJ7TDP.cjs.map +1 -0
- package/dist/constants.cjs +1 -21
- package/dist/constants.d.cts +1 -1
- package/dist/constants.d.ts +1 -1
- package/dist/constants.js +1 -4
- package/dist/engine.cjs +1 -94
- package/dist/engine.d.cts +10 -11
- package/dist/engine.d.ts +10 -11
- package/dist/engine.js +1 -37
- package/dist/errors.cjs +1 -105
- package/dist/errors.d.cts +3 -3
- package/dist/errors.d.ts +3 -3
- package/dist/errors.js +1 -4
- package/dist/format.cjs +1 -26
- package/dist/format.d.cts +2 -2
- package/dist/format.d.ts +2 -2
- package/dist/format.js +1 -9
- package/dist/index.cjs +1 -314
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +52 -20
- package/dist/index.d.ts +52 -20
- package/dist/index.js +1 -278
- package/dist/index.js.map +1 -1
- package/dist/language.cjs +1 -369
- package/dist/language.cjs.map +1 -1
- package/dist/language.d.cts +9 -10
- package/dist/language.d.ts +9 -10
- package/dist/language.js +1 -348
- package/dist/language.js.map +1 -1
- package/dist/lexer.cjs +1 -63
- package/dist/lexer.js +1 -10
- package/dist/normalizer.cjs +1 -39
- package/dist/normalizer.js +1 -10
- package/dist/packages.cjs +1 -132
- package/dist/packages.d.cts +8 -9
- package/dist/packages.d.ts +8 -9
- package/dist/packages.js +1 -23
- package/dist/parser.cjs +1 -54
- package/dist/parser.d.cts +8 -8
- package/dist/parser.d.ts +8 -8
- package/dist/parser.js +1 -9
- package/dist/{pipeline-D-PS9gVw.d.ts → pipeline-72QmQlGx.d.ts} +1 -1
- package/dist/{pipeline-DtSBJ8TS.d.cts → pipeline-DCQicwWX.d.cts} +1 -1
- package/dist/resolvers.cjs +1 -12
- package/dist/resolvers.d.cts +2 -2
- package/dist/resolvers.d.ts +2 -2
- package/dist/resolvers.js +1 -3
- package/dist/services.cjs +1 -20
- package/dist/services.js +1 -3
- package/dist/testing.cjs +3 -477
- package/dist/testing.cjs.map +1 -1
- package/dist/testing.d.cts +9 -10
- package/dist/testing.d.ts +9 -10
- package/dist/testing.js +3 -469
- package/dist/testing.js.map +1 -1
- package/dist/uom.cjs +1 -55
- package/dist/uom.d.cts +2 -2
- package/dist/uom.d.ts +2 -2
- package/dist/uom.js +1 -10
- package/dist/utilities.cjs +1 -36
- package/dist/utilities.js +1 -7
- package/dist/vm.cjs +1 -295
- package/dist/vm.cjs.map +1 -1
- package/dist/vm.d.cts +22 -10
- package/dist/vm.d.ts +22 -10
- package/dist/vm.js +1 -193
- package/dist/vm.js.map +1 -1
- package/dist/worker.cjs +2 -492
- package/dist/worker.cjs.map +1 -1
- package/dist/worker.d.cts +16 -17
- package/dist/worker.d.ts +16 -17
- package/dist/worker.js +2 -483
- package/dist/worker.js.map +1 -1
- package/package.json +1 -13
- package/dist/chunk-3BOK2LDK.js +0 -17
- package/dist/chunk-3BOK2LDK.js.map +0 -1
- package/dist/chunk-3VGDNEE3.js +0 -84
- package/dist/chunk-3VGDNEE3.js.map +0 -1
- package/dist/chunk-4K5W7EH2.cjs +0 -112
- package/dist/chunk-4K5W7EH2.cjs.map +0 -1
- package/dist/chunk-5EFKSKMA.js +0 -413
- package/dist/chunk-5EFKSKMA.js.map +0 -1
- package/dist/chunk-5HRB36DK.js +0 -405
- package/dist/chunk-5HRB36DK.js.map +0 -1
- package/dist/chunk-5ON7PUAZ.js +0 -12
- package/dist/chunk-5ON7PUAZ.js.map +0 -1
- package/dist/chunk-7AXJNQMF.cjs +0 -297
- package/dist/chunk-7AXJNQMF.cjs.map +0 -1
- package/dist/chunk-7JM3F4KL.js +0 -1795
- package/dist/chunk-7JM3F4KL.js.map +0 -1
- package/dist/chunk-7USV76HV.cjs +0 -341
- package/dist/chunk-7USV76HV.cjs.map +0 -1
- package/dist/chunk-A2DZ5BEJ.cjs +0 -1930
- package/dist/chunk-A2DZ5BEJ.cjs.map +0 -1
- package/dist/chunk-ADBA3XBE.cjs +0 -20
- package/dist/chunk-ADBA3XBE.cjs.map +0 -1
- package/dist/chunk-AKNGX4TZ.cjs +0 -236
- package/dist/chunk-AKNGX4TZ.cjs.map +0 -1
- package/dist/chunk-ALYRJ72W.cjs +0 -434
- package/dist/chunk-ALYRJ72W.cjs.map +0 -1
- package/dist/chunk-AMOJYLG2.cjs +0 -1692
- package/dist/chunk-AMOJYLG2.cjs.map +0 -1
- package/dist/chunk-AOH6UR2L.js +0 -825
- package/dist/chunk-AOH6UR2L.js.map +0 -1
- package/dist/chunk-AQNHHJMJ.cjs +0 -261
- package/dist/chunk-B7LXJ6LC.cjs +0 -36
- package/dist/chunk-B7LXJ6LC.cjs.map +0 -1
- package/dist/chunk-BESTLPRK.cjs +0 -6919
- package/dist/chunk-BESTLPRK.cjs.map +0 -1
- package/dist/chunk-BLI4NIQY.js +0 -98
- package/dist/chunk-BLI4NIQY.js.map +0 -1
- package/dist/chunk-BSPXMGIS.js +0 -455
- package/dist/chunk-BSPXMGIS.js.map +0 -1
- package/dist/chunk-C2OMO3WN.cjs +0 -2806
- package/dist/chunk-C2OMO3WN.cjs.map +0 -1
- package/dist/chunk-CSDQMDU2.js +0 -204
- package/dist/chunk-CSDQMDU2.js.map +0 -1
- package/dist/chunk-EJ3ILXX6.cjs +0 -223
- package/dist/chunk-EJ3ILXX6.cjs.map +0 -1
- package/dist/chunk-ENRIK36Q.cjs +0 -94
- package/dist/chunk-ENRIK36Q.cjs.map +0 -1
- package/dist/chunk-F4UB4XIL.js +0 -109
- package/dist/chunk-F4UB4XIL.js.map +0 -1
- package/dist/chunk-FD5ZZHEU.js +0 -92
- package/dist/chunk-FD5ZZHEU.js.map +0 -1
- package/dist/chunk-FE4RC37D.js +0 -2801
- package/dist/chunk-FE4RC37D.js.map +0 -1
- package/dist/chunk-FEAIOR7N.cjs +0 -91
- package/dist/chunk-FEAIOR7N.cjs.map +0 -1
- package/dist/chunk-FR7RNOPT.cjs +0 -3303
- package/dist/chunk-FR7RNOPT.cjs.map +0 -1
- package/dist/chunk-G2YPPLGX.cjs +0 -484
- package/dist/chunk-G2YPPLGX.cjs.map +0 -1
- package/dist/chunk-GCM5JHMX.js +0 -88
- package/dist/chunk-GCM5JHMX.js.map +0 -1
- package/dist/chunk-GDEU72RG.cjs +0 -829
- package/dist/chunk-GDEU72RG.cjs.map +0 -1
- package/dist/chunk-HKTQCQ4Z.cjs +0 -8383
- package/dist/chunk-HKTQCQ4Z.cjs.map +0 -1
- package/dist/chunk-HWHU642X.cjs +0 -316
- package/dist/chunk-HWHU642X.cjs.map +0 -1
- package/dist/chunk-ICEKS6YC.cjs +0 -507
- package/dist/chunk-ICEKS6YC.cjs.map +0 -1
- package/dist/chunk-IJGOFP2J.js +0 -6904
- package/dist/chunk-IJGOFP2J.js.map +0 -1
- package/dist/chunk-IQJGDZOP.js +0 -333
- package/dist/chunk-IQJGDZOP.js.map +0 -1
- package/dist/chunk-IT74O4BE.cjs +0 -456
- package/dist/chunk-IT74O4BE.cjs.map +0 -1
- package/dist/chunk-KXDQKVNX.cjs +0 -459
- package/dist/chunk-KXDQKVNX.cjs.map +0 -1
- package/dist/chunk-L2TE7PMO.cjs +0 -14
- package/dist/chunk-L2TE7PMO.cjs.map +0 -1
- package/dist/chunk-L5YHV6BQ.js +0 -499
- package/dist/chunk-L5YHV6BQ.js.map +0 -1
- package/dist/chunk-LO7HU5WB.cjs +0 -209
- package/dist/chunk-LO7HU5WB.cjs.map +0 -1
- package/dist/chunk-LSALB3IN.js +0 -292
- package/dist/chunk-LSALB3IN.js.map +0 -1
- package/dist/chunk-MI7OTUHL.cjs +0 -339
- package/dist/chunk-MI7OTUHL.cjs.map +0 -1
- package/dist/chunk-MIGXCBXT.cjs +0 -381
- package/dist/chunk-MIGXCBXT.cjs.map +0 -1
- package/dist/chunk-MVTOCRV2.js +0 -213
- package/dist/chunk-MVTOCRV2.js.map +0 -1
- package/dist/chunk-N7FNVFXW.cjs +0 -32
- package/dist/chunk-N7FNVFXW.cjs.map +0 -1
- package/dist/chunk-N7OA4WPJ.js +0 -362
- package/dist/chunk-N7OA4WPJ.js.map +0 -1
- package/dist/chunk-NAWZATKT.js +0 -478
- package/dist/chunk-NAWZATKT.js.map +0 -1
- package/dist/chunk-NLNDMWZC.js +0 -31
- package/dist/chunk-NLNDMWZC.js.map +0 -1
- package/dist/chunk-ORM7CHYZ.js +0 -1531
- package/dist/chunk-ORM7CHYZ.js.map +0 -1
- package/dist/chunk-OUHT5Z36.cjs +0 -393
- package/dist/chunk-OUHT5Z36.cjs.map +0 -1
- package/dist/chunk-PCZVMMWU.cjs +0 -74
- package/dist/chunk-PCZVMMWU.cjs.map +0 -1
- package/dist/chunk-RNKDIXDV.js +0 -336
- package/dist/chunk-RNKDIXDV.js.map +0 -1
- package/dist/chunk-SBUFNJVE.js +0 -258
- package/dist/chunk-SBUFNJVE.js.map +0 -1
- package/dist/chunk-TC6BTUSU.cjs +0 -1799
- package/dist/chunk-TC6BTUSU.cjs.map +0 -1
- package/dist/chunk-TPOK3UNI.js +0 -8355
- package/dist/chunk-TPOK3UNI.js.map +0 -1
- package/dist/chunk-UF6JG5SG.js +0 -312
- package/dist/chunk-UF6JG5SG.js.map +0 -1
- package/dist/chunk-UKQHXPGW.js +0 -30
- package/dist/chunk-UKQHXPGW.js.map +0 -1
- package/dist/chunk-V4XG5QF6.js +0 -1685
- package/dist/chunk-V4XG5QF6.js.map +0 -1
- package/dist/chunk-VEKIWQ3F.cjs +0 -39
- package/dist/chunk-VEKIWQ3F.cjs.map +0 -1
- package/dist/chunk-WMQRJTAO.js +0 -3266
- package/dist/chunk-WMQRJTAO.js.map +0 -1
- package/dist/chunk-X6K3HUOY.cjs +0 -86
- package/dist/chunk-X6K3HUOY.cjs.map +0 -1
- package/dist/chunk-XBTEO4OB.js +0 -391
- package/dist/chunk-XBTEO4OB.js.map +0 -1
- package/dist/chunk-XIYYHA65.cjs +0 -101
- package/dist/chunk-XIYYHA65.cjs.map +0 -1
- package/dist/chunk-YJHY7CMN.cjs +0 -1534
- package/dist/chunk-YLJ4XMA6.js +0 -33
- package/dist/chunk-YLJ4XMA6.js.map +0 -1
- package/dist/chunk-YNIWOYW6.js +0 -232
- package/dist/chunk-YNIWOYW6.js.map +0 -1
- package/dist/chunk-Z2XP767T.cjs +0 -35
- package/dist/chunk-Z2XP767T.cjs.map +0 -1
- package/dist/chunk-Z4X2RWOF.js +0 -37
- package/dist/chunk-Z4X2RWOF.js.map +0 -1
- package/dist/chunk-ZN6YYPIW.js +0 -67
- package/dist/chunk-ZN6YYPIW.js.map +0 -1
- package/dist/chunk-ZNFFTYWH.js +0 -1854
- package/dist/chunk-ZNFFTYWH.js.map +0 -1
- package/dist/variables.cjs +0 -17
- package/dist/variables.cjs.map +0 -1
- package/dist/variables.d.cts +0 -87
- package/dist/variables.d.ts +0 -87
- package/dist/variables.js +0 -4
- package/dist/variables.js.map +0 -1
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import { a as PrecedenceParser, b as PrefixParselet, I as InfixParselet } from './Parselet-
|
|
2
|
-
import { V as Value, b as ValueType } from './Value-
|
|
3
|
-
import { IVariableSource } from './variables.js';
|
|
1
|
+
import { a as PrecedenceParser, b as PrefixParselet, I as InfixParselet } from './Parselet-B-zoPrTa.js';
|
|
2
|
+
import { V as Value, b as ValueType } from './Value-CCi_Eecs.js';
|
|
4
3
|
import { M as MarkdownLineType, L as Lexer, e as TokenCategory, c as LexerVocabulary } from './Lexer-DKMlj7Sy.js';
|
|
5
4
|
import { IAsyncResolver } from './resolvers.js';
|
|
6
5
|
import { T as TokenFusion, c as TokenNormalizer, a as NormalizerRule } from './TokenNormalizer-DCWdZjGz.js';
|
|
7
|
-
import { a as DependencyGraph, V as VM, D as DagSnapshot, b as EngineContext, S as ScopeManager,
|
|
8
|
-
import { a as BytecodeProgram } from './BytecodeBuilder-
|
|
6
|
+
import { a as DependencyGraph, V as VM, D as DagSnapshot, b as EngineContext, S as ScopeManager, P as PluginFunctionHandler } from './ScopeManager-C2LDOrDx.js';
|
|
7
|
+
import { a as BytecodeProgram } from './BytecodeBuilder-DGGeByAP.js';
|
|
9
8
|
import { QueryClient } from '@tanstack/query-core';
|
|
10
|
-
import { E as EngineError } from './EngineError-
|
|
11
|
-
import { a as DiagnosticReportJSON, D as DiagnosticPipeline } from './pipeline-
|
|
9
|
+
import { E as EngineError } from './EngineError-Ce1lPkjZ.js';
|
|
10
|
+
import { a as DiagnosticReportJSON, D as DiagnosticPipeline } from './pipeline-72QmQlGx.js';
|
|
12
11
|
import { T as Token } from './Token-CbP_OutD.js';
|
|
13
|
-
import {
|
|
12
|
+
import { E as EngineConfigOverride, a as EngineConfig } from './Configuration-B6W0-T67.js';
|
|
14
13
|
|
|
15
14
|
/**
|
|
16
15
|
* One line's compiled bytecode, plus the variables it reads and writes.
|
|
@@ -1444,15 +1443,16 @@ interface EngineRestoreOptions {
|
|
|
1444
1443
|
* Packages to register on the restored engine. This MUST be the same set
|
|
1445
1444
|
* the snapshot was taken with: a snapshot carries compiled bytecode whose
|
|
1446
1445
|
* plugin-function indices and parselet-produced opcodes only line up
|
|
1447
|
-
* against the packages that were present when it was written.
|
|
1448
|
-
*
|
|
1449
|
-
* parameter, so a host
|
|
1446
|
+
* against the packages that were present when it was written. Registers no
|
|
1447
|
+
* packages when omitted, exactly like the constructor's own `packages`
|
|
1448
|
+
* parameter, so a host that snapshotted a full engine passes the same
|
|
1449
|
+
* `BUILTIN_PACKAGES` here that it constructed with.
|
|
1450
1450
|
*/
|
|
1451
1451
|
packages?: IEnginePackage[];
|
|
1452
1452
|
/** Config overrides, merged over `DEFAULT_CONFIG`, as in the constructor. */
|
|
1453
|
-
config?:
|
|
1454
|
-
/** Turn on the diagnostic pipeline, as in the constructor's `
|
|
1455
|
-
|
|
1453
|
+
config?: EngineConfigOverride;
|
|
1454
|
+
/** Turn on the diagnostic pipeline, as in the constructor's `diagnostics`. */
|
|
1455
|
+
diagnostics?: boolean;
|
|
1456
1456
|
/**
|
|
1457
1457
|
* Override the locale the snapshot recorded. Rarely needed: the snapshot's
|
|
1458
1458
|
* own {@link EngineSnapshot.locale} is used by default, so a restored engine
|
|
@@ -1461,17 +1461,23 @@ interface EngineRestoreOptions {
|
|
|
1461
1461
|
locale?: string;
|
|
1462
1462
|
}
|
|
1463
1463
|
/**
|
|
1464
|
-
*
|
|
1464
|
+
* Options for constructing an {@link ExpressionEngine}. Every field is optional.
|
|
1465
1465
|
*
|
|
1466
|
-
*
|
|
1467
|
-
*
|
|
1466
|
+
* An engine registers exactly the {@link EngineOptions.packages} it is given, so
|
|
1467
|
+
* a bundler can tree-shake away every built-in a consumer never imports; pass
|
|
1468
|
+
* `BUILTIN_PACKAGES` (from `solve-engine/packages`) for the full set, a subset
|
|
1469
|
+
* for a slimmer engine, or use {@link createEngine} for the batteries-included
|
|
1470
|
+
* convenience.
|
|
1468
1471
|
*/
|
|
1469
|
-
interface
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1472
|
+
interface EngineOptions {
|
|
1473
|
+
/** BCP-47 locale. Defaults to `"en"`. */
|
|
1474
|
+
locale?: string;
|
|
1475
|
+
/** Packages to register. None when omitted, so nothing but what you pass is bundled. */
|
|
1476
|
+
packages?: IEnginePackage[];
|
|
1477
|
+
/** Config overrides, merged per section over {@link DEFAULT_CONFIG}. */
|
|
1478
|
+
config?: EngineConfigOverride;
|
|
1479
|
+
/** Turn on the diagnostic pipeline (per-stage timing and detail). Defaults to `false`. */
|
|
1480
|
+
diagnostics?: boolean;
|
|
1475
1481
|
}
|
|
1476
1482
|
/**
|
|
1477
1483
|
* Core expression evaluation engine, the top-level orchestrator.
|
|
@@ -1511,13 +1517,26 @@ interface LineEvaluation {
|
|
|
1511
1517
|
* is the intended usage. Reusing a single engine across documents is also fine:
|
|
1512
1518
|
* `clear()` resets it for the next one rather than consuming it.
|
|
1513
1519
|
*
|
|
1520
|
+
* The constructor registers only the packages it is given, so a consumer's
|
|
1521
|
+
* bundler can tree-shake away every built-in they do not use. For the common
|
|
1522
|
+
* "I want everything" case, {@link createEngine} registers the full built-in
|
|
1523
|
+
* set in one call; pass an explicit package list to the constructor when
|
|
1524
|
+
* bundle size matters.
|
|
1525
|
+
*
|
|
1514
1526
|
* @example
|
|
1515
1527
|
* ```typescript
|
|
1516
|
-
* import {
|
|
1517
|
-
* const engine =
|
|
1518
|
-
* const
|
|
1528
|
+
* import { createEngine } from "solve-engine";
|
|
1529
|
+
* const engine = createEngine(); // every built-in package
|
|
1530
|
+
* const value = engine.evaluateExpression("2 + 2 * 10");
|
|
1519
1531
|
* console.log(value.toNumber()); // 22
|
|
1520
1532
|
* ```
|
|
1533
|
+
* @example
|
|
1534
|
+
* ```typescript
|
|
1535
|
+
* // A slimmer engine: only arithmetic and units reach the bundle.
|
|
1536
|
+
* import { ExpressionEngine } from "solve-engine";
|
|
1537
|
+
* import { ARITHMETIC_PACKAGE, UOM_PACKAGE } from "solve-engine/packages";
|
|
1538
|
+
* const engine = new ExpressionEngine({ packages: [ARITHMETIC_PACKAGE, UOM_PACKAGE] });
|
|
1539
|
+
* ```
|
|
1521
1540
|
*/
|
|
1522
1541
|
declare class ExpressionEngine {
|
|
1523
1542
|
private dag;
|
|
@@ -1557,8 +1576,8 @@ declare class ExpressionEngine {
|
|
|
1557
1576
|
/** Registry of async resolvers from registered packages. */
|
|
1558
1577
|
private resolverRegistry;
|
|
1559
1578
|
/**
|
|
1560
|
-
* Per-package record of contributions made to the
|
|
1561
|
-
* (
|
|
1579
|
+
* Per-package record of contributions made to the engine's registries
|
|
1580
|
+
* (plugin functions, resolver namespaces, token categories), so
|
|
1562
1581
|
* {@link unregisterPackage} can reverse them. Keyed by package name.
|
|
1563
1582
|
*/
|
|
1564
1583
|
private packageContributions;
|
|
@@ -1689,10 +1708,11 @@ declare class ExpressionEngine {
|
|
|
1689
1708
|
* the bytecode-cache benefit on re-evaluation regardless of config.
|
|
1690
1709
|
*/
|
|
1691
1710
|
private cacheBytecode;
|
|
1711
|
+
private pluginFunctionIndexByName;
|
|
1692
1712
|
private builderPool;
|
|
1693
1713
|
private builderPoolIndex;
|
|
1694
1714
|
private lastTelemetry;
|
|
1695
|
-
constructor(
|
|
1715
|
+
constructor(options?: EngineOptions);
|
|
1696
1716
|
/**
|
|
1697
1717
|
* Get the native event stream from the batcher for stream-based consumers.
|
|
1698
1718
|
*
|
|
@@ -1724,7 +1744,6 @@ declare class ExpressionEngine {
|
|
|
1724
1744
|
* - `lexerVocabulary` → engine's isolated lexer (via this.lexer.registerVocabulary)
|
|
1725
1745
|
* - `prefixParselets` → engine's isolated ParseletRegistry
|
|
1726
1746
|
* - `infixParselets` → engine's isolated ParseletRegistry
|
|
1727
|
-
* - `variableSources` → this engine's own variable resolver
|
|
1728
1747
|
*
|
|
1729
1748
|
* Built-in packages (ARITHMETIC, FUNCTION, UOM, etc.) are registered
|
|
1730
1749
|
* via this method during construction. External user packages can also
|
|
@@ -2197,8 +2216,8 @@ declare class ExpressionEngine {
|
|
|
2197
2216
|
* compile-only callers. NOT used by `evaluateLine()`/
|
|
2198
2217
|
* `evaluateExpression()`, those route through
|
|
2199
2218
|
* {@link evaluateExpressionWithDiagnostic} instead (evaluateLine ->
|
|
2200
|
-
*
|
|
2201
|
-
*
|
|
2219
|
+
* evaluateLineWithDebug -> evaluateExpressionWithDiagnostic), which does
|
|
2220
|
+
* its own lexing and its
|
|
2202
2221
|
* own diagnostic-instrumented front-half, delegating to the SAME
|
|
2203
2222
|
* {@link prepareExpression} this method calls. Delegates the front-half
|
|
2204
2223
|
* to {@link prepareExpression}, then runs async preflight (via
|
|
@@ -2210,16 +2229,10 @@ declare class ExpressionEngine {
|
|
|
2210
2229
|
*
|
|
2211
2230
|
* @param lineNumber - 1-based line position in the document.
|
|
2212
2231
|
* @param lineText - The raw line text.
|
|
2213
|
-
* @returns The evaluated Value
|
|
2214
|
-
* @throws {EngineError} On evaluation failure.
|
|
2215
|
-
*/
|
|
2216
|
-
evaluateLine(lineNumber: number, lineText: string): EvalResults;
|
|
2217
|
-
/**
|
|
2218
|
-
* Evaluate a line and return an explicit `{ values }` object.
|
|
2219
|
-
*
|
|
2232
|
+
* @returns The evaluated {@link Value}.
|
|
2220
2233
|
* @throws {EngineError} On evaluation failure.
|
|
2221
2234
|
*/
|
|
2222
|
-
|
|
2235
|
+
evaluateLine(lineNumber: number, lineText: string): Value;
|
|
2223
2236
|
/**
|
|
2224
2237
|
* Evaluate a line with diagnostic information, supporting both regular expressions and inline solves.
|
|
2225
2238
|
*
|
|
@@ -2489,9 +2502,9 @@ declare class ExpressionEngine {
|
|
|
2489
2502
|
getLastTelemetry(): PipelineTelemetry | null;
|
|
2490
2503
|
/**
|
|
2491
2504
|
* Evaluate a raw expression string without line-number context.
|
|
2492
|
-
* Returns the Value result. Throws on error.
|
|
2505
|
+
* Returns the {@link Value} result. Throws on error.
|
|
2493
2506
|
*/
|
|
2494
|
-
evaluateExpression(expression: string):
|
|
2507
|
+
evaluateExpression(expression: string): Value;
|
|
2495
2508
|
/**
|
|
2496
2509
|
* Explain how a line reached its answer, as a readable derivation.
|
|
2497
2510
|
*
|
|
@@ -2609,15 +2622,25 @@ declare class ExpressionEngine {
|
|
|
2609
2622
|
* Fast path: evaluate an expression and return a number directly.
|
|
2610
2623
|
*
|
|
2611
2624
|
* Skips Value object allocation when only a numeric result is needed.
|
|
2612
|
-
* Returns NaN
|
|
2625
|
+
* Returns NaN whenever the expression has no numeric answer: a thrown
|
|
2626
|
+
* error, a bare undefined variable reference, or a faulted result (an
|
|
2627
|
+
* Error or a Pending value).
|
|
2613
2628
|
*
|
|
2614
2629
|
* Performs a pre-check for bare identifiers (single-token variable
|
|
2615
2630
|
* references). If the identifier is not a known variable, returns NaN
|
|
2616
2631
|
* immediately without attempting evaluation, avoids the ambiguity of
|
|
2617
2632
|
* "result === 0" when a variable might legitimately store the value 0.
|
|
2618
2633
|
*
|
|
2634
|
+
* A faulted result is treated the same way, and for the same reason: an
|
|
2635
|
+
* Error or Pending reads as 0 through {@link Value.toNumber}, so returning
|
|
2636
|
+
* that 0 would be indistinguishable from a real zero. NaN is this fast
|
|
2637
|
+
* path's established "no value" signal, so `evaluateNumber("5 kg to m")`
|
|
2638
|
+
* (an impossible conversion) is NaN rather than a silent `0`. A caller that
|
|
2639
|
+
* needs the fault's detail should use {@link evaluateExpression} and read
|
|
2640
|
+
* {@link Value.errorCode}/{@link Value.isPending} off the result.
|
|
2641
|
+
*
|
|
2619
2642
|
* @param expression - The raw expression string to evaluate.
|
|
2620
|
-
* @returns The numeric result, or NaN on error/undefined variable.
|
|
2643
|
+
* @returns The numeric result, or NaN on error / undefined variable / fault.
|
|
2621
2644
|
*/
|
|
2622
2645
|
evaluateNumber(expression: string): number;
|
|
2623
2646
|
clear(): void;
|
|
@@ -2903,50 +2926,25 @@ declare class LanguageService {
|
|
|
2903
2926
|
invalidateCache(): void;
|
|
2904
2927
|
}
|
|
2905
2928
|
|
|
2906
|
-
/**
|
|
2907
|
-
* Public API for registering plugins with the solve-js engine.
|
|
2908
|
-
*
|
|
2909
|
-
* All registration goes through this interface, parselets, variable
|
|
2910
|
-
* sources, and full packages. The default implementation is
|
|
2911
|
-
* {@link PackageRegistry} (singleton via {@link packageRegistry}).
|
|
2912
|
-
*
|
|
2913
|
-
* @example
|
|
2914
|
-
* ```typescript
|
|
2915
|
-
* import { packageRegistry } from "solve-engine";
|
|
2916
|
-
* packageRegistry.registerPackage(myCustomPackage);
|
|
2917
|
-
* ```
|
|
2918
|
-
*/
|
|
2919
|
-
interface IPackageRegistry {
|
|
2920
|
-
/** Register a prefix parselet (e.g., `GE`, `NOW`, `floor`). */
|
|
2921
|
-
registerPrefixParselet(tokenType: string, parselet: PrefixParselet): void;
|
|
2922
|
-
/** Register an infix parselet (e.g., `+`, `in`, `to`). */
|
|
2923
|
-
registerInfixParselet(tokenType: string, parselet: InfixParselet): void;
|
|
2924
|
-
/** @deprecated Has no effect. See {@link IEnginePackage.variableSources}. */
|
|
2925
|
-
registerVariableSource(source: IVariableSource): void;
|
|
2926
|
-
/** Register a complete package (parselets + variable sources). */
|
|
2927
|
-
registerPackage(pkg: IEnginePackage): void;
|
|
2928
|
-
/** Convenience reference to the Value class for creating typed values. */
|
|
2929
|
-
Value: typeof Value;
|
|
2930
|
-
}
|
|
2931
2929
|
/**
|
|
2932
2930
|
* Package descriptor for registering a complete provider with the engine.
|
|
2933
2931
|
*
|
|
2934
2932
|
* A package bundles all the pieces needed for a domain-specific provider:
|
|
2935
2933
|
* lexer plugins for custom token recognition, parselets for Pratt parsing,
|
|
2936
|
-
* plugin functions dispatched via CALL_PLUGIN bytecode,
|
|
2937
|
-
*
|
|
2938
|
-
*
|
|
2934
|
+
* plugin functions dispatched via CALL_PLUGIN bytecode, and optional async
|
|
2935
|
+
* resolvers for data that loads asynchronously (e.g., exchange rates, game
|
|
2936
|
+
* prices).
|
|
2939
2937
|
*
|
|
2940
2938
|
* @example
|
|
2941
2939
|
* ```typescript
|
|
2942
2940
|
* const myPackage: IEnginePackage = {
|
|
2943
2941
|
* name: "MyProvider",
|
|
2944
2942
|
* lexerVocabulary: myLexerVocabulary,
|
|
2945
|
-
* prefixParselets:
|
|
2946
|
-
* pluginFunctions:
|
|
2943
|
+
* prefixParselets: { MY_FUNC: new MyParselet() },
|
|
2944
|
+
* pluginFunctions: { myFn: myHandler },
|
|
2947
2945
|
* asyncResolvers: [myAsyncResolver],
|
|
2948
2946
|
* };
|
|
2949
|
-
*
|
|
2947
|
+
* const engine = createEngine({ extraPackages: [myPackage] });
|
|
2950
2948
|
* ```
|
|
2951
2949
|
*/
|
|
2952
2950
|
interface IEnginePackage {
|
|
@@ -2973,59 +2971,30 @@ interface IEnginePackage {
|
|
|
2973
2971
|
engineVersion?: string;
|
|
2974
2972
|
/** Optional lexer vocabulary (keywords/operators/units) for recognizing custom tokens (e.g., `GE`, `£`). */
|
|
2975
2973
|
lexerVocabulary?: LexerVocabulary;
|
|
2976
|
-
/** Prefix parselets for this package's custom functions/operators. */
|
|
2977
|
-
prefixParselets?:
|
|
2978
|
-
|
|
2979
|
-
|
|
2980
|
-
|
|
2981
|
-
|
|
2982
|
-
|
|
2983
|
-
|
|
2984
|
-
|
|
2985
|
-
|
|
2986
|
-
|
|
2987
|
-
*
|
|
2988
|
-
*
|
|
2989
|
-
*
|
|
2990
|
-
*
|
|
2991
|
-
*
|
|
2992
|
-
* independently picking the same index would silently overwrite each
|
|
2993
|
-
* other's handler in the shared registry.
|
|
2994
|
-
*
|
|
2995
|
-
* The handler's optional second parameter, `context`, carries the
|
|
2996
|
-
* current line's {@link LineExecutionContext} (line number, and, only
|
|
2997
|
-
* inside a real document, never `evaluateExpression()`'s single-shot
|
|
2998
|
-
* path, closures for reading another line's cached result). Every
|
|
2999
|
-
* handler that doesn't need cross-line data can ignore it entirely.
|
|
2974
|
+
/** Prefix parselets for this package's custom functions/operators, keyed by token type. */
|
|
2975
|
+
prefixParselets?: Record<string, PrefixParselet>;
|
|
2976
|
+
/** Infix parselets for this package's custom binary operators, keyed by token type. */
|
|
2977
|
+
infixParselets?: Record<string, InfixParselet>;
|
|
2978
|
+
/**
|
|
2979
|
+
* Functions dispatched via `CALL_PLUGIN` bytecode, keyed by a package-local
|
|
2980
|
+
* name. The engine assigns each a registry index at registration, so a
|
|
2981
|
+
* parselet emits the call by that name (`builder.emitPluginCall(name, argCount)`)
|
|
2982
|
+
* and never touches a numeric index. Two packages naming a function the same
|
|
2983
|
+
* is a `checkPackageCompatibility` warning, the later registration wins.
|
|
2984
|
+
*
|
|
2985
|
+
* The handler's optional second parameter, `context`, carries the current
|
|
2986
|
+
* line's `LineExecutionContext` (line number, and, only inside a real
|
|
2987
|
+
* document, never `evaluateExpression()`'s single-shot path, closures for
|
|
2988
|
+
* reading another line's cached result). Every handler that doesn't need
|
|
2989
|
+
* cross-line data can ignore it entirely.
|
|
3000
2990
|
*
|
|
3001
2991
|
* @example
|
|
3002
2992
|
* ```ts
|
|
3003
|
-
*
|
|
3004
|
-
*
|
|
3005
|
-
* pluginFunctions: [{ index: MY_FN_IDX, handler: myHandler }]
|
|
2993
|
+
* // In a parselet's parse(): builder.emitPluginCall("myFn", argCount);
|
|
2994
|
+
* pluginFunctions: { myFn: myHandler }
|
|
3006
2995
|
* ```
|
|
3007
2996
|
*/
|
|
3008
|
-
pluginFunctions?:
|
|
3009
|
-
index: number;
|
|
3010
|
-
handler: (args: Value[], context?: LineExecutionContext) => Value | Promise<Value>;
|
|
3011
|
-
}>;
|
|
3012
|
-
/**
|
|
3013
|
-
* Named-variable sources.
|
|
3014
|
-
*
|
|
3015
|
-
* @deprecated Currently has no effect. Sources declared here are registered
|
|
3016
|
-
* into the engine's {@link EngineContext} and unregistered again on package
|
|
3017
|
-
* removal, but no evaluation path ever calls `VariableResolver.resolve()`, so
|
|
3018
|
-
* a variable a source provides is never found. Verified by searching every
|
|
3019
|
-
* use of `IVariableSource` outside its own declaration: they are all
|
|
3020
|
-
* registration bookkeeping.
|
|
3021
|
-
*
|
|
3022
|
-
* Declared here rather than deleted because removing a public field is a
|
|
3023
|
-
* breaking change and the intended behaviour is worth keeping. Documented as
|
|
3024
|
-
* dead so a package author does not spend an afternoon working out why their
|
|
3025
|
-
* variables resolve to nothing. To expose a value today, contribute a plugin
|
|
3026
|
-
* function through {@link IEnginePackage.pluginFunctions}.
|
|
3027
|
-
*/
|
|
3028
|
-
variableSources?: IVariableSource[];
|
|
2997
|
+
pluginFunctions?: Record<string, PluginFunctionHandler>;
|
|
3029
2998
|
/**
|
|
3030
2999
|
* Async resolvers for this package's domain.
|
|
3031
3000
|
* When set, the ExpressionEngine runs preflight() before VM execution
|
|
@@ -3117,53 +3086,5 @@ interface IEnginePackage {
|
|
|
3117
3086
|
*/
|
|
3118
3087
|
asConverters?: Record<string, (value: Value) => Value>;
|
|
3119
3088
|
}
|
|
3120
|
-
/**
|
|
3121
|
-
* Default implementation of {@link IPackageRegistry}, the plugin registration API.
|
|
3122
|
-
*
|
|
3123
|
-
* All registrations delegate to shared singletons (parselet registry,
|
|
3124
|
-
* variable resolver, lexer). This ensures that packages registered through
|
|
3125
|
-
* any PackageRegistry instance are visible engine-wide.
|
|
3126
|
-
*
|
|
3127
|
-
* @example
|
|
3128
|
-
* ```typescript
|
|
3129
|
-
* import { packageRegistry } from "solve-engine";
|
|
3130
|
-
*
|
|
3131
|
-
* // Register a complete provider package
|
|
3132
|
-
* packageRegistry.registerPackage({
|
|
3133
|
-
* name: "MyProvider",
|
|
3134
|
-
* prefixParselets: [{ tokenType: "MY_FUNC", parselet: new MyParselet() }],
|
|
3135
|
-
* });
|
|
3136
|
-
* ```
|
|
3137
|
-
*
|
|
3138
|
-
* @deprecated Register on an engine instead:
|
|
3139
|
-
* `engine.registerPackage(pkg)`.
|
|
3140
|
-
*
|
|
3141
|
-
* This class writes into process-wide singletons, which is incompatible with an
|
|
3142
|
-
* engine owning its own registries. Since the introduction of
|
|
3143
|
-
* {@link EngineContext}, an engine reads plugin functions, opcode handlers and
|
|
3144
|
-
* variable sources from its own context, so a package registered here is not
|
|
3145
|
-
* visible to any engine. Parselets and lexer vocabulary registered here reach
|
|
3146
|
-
* the shared registries, which an engine also does not read: it builds its own
|
|
3147
|
-
* `ParseletRegistry` and its own `Lexer`.
|
|
3148
|
-
*
|
|
3149
|
-
* In other words this path registers into state nothing evaluates against. It
|
|
3150
|
-
* remains exported because removing it is a breaking change, and it is where
|
|
3151
|
-
* the singletons that survive are still written from, but it should not be used
|
|
3152
|
-
* in new code and will be removed before 1.0 proper.
|
|
3153
|
-
*/
|
|
3154
|
-
declare class PackageRegistry implements IPackageRegistry {
|
|
3155
|
-
Value: typeof Value;
|
|
3156
|
-
registerPrefixParselet(tokenType: string, parselet: PrefixParselet): void;
|
|
3157
|
-
registerInfixParselet(tokenType: string, parselet: InfixParselet): void;
|
|
3158
|
-
registerVariableSource(source: IVariableSource): void;
|
|
3159
|
-
registerPackage(pkg: IEnginePackage): void;
|
|
3160
|
-
}
|
|
3161
|
-
/**
|
|
3162
|
-
* Singleton PackageRegistry instance, the default plugin registration API.
|
|
3163
|
-
*
|
|
3164
|
-
* All packages should register through this instance. The underlying registries
|
|
3165
|
-
* are shared singletons, so multiple PackageRegistry instances would be redundant.
|
|
3166
|
-
*/
|
|
3167
|
-
declare const packageRegistry: PackageRegistry;
|
|
3168
3089
|
|
|
3169
|
-
export { type ApplyChangesResult as A, type BatcherMetrics as B, type CacheSnapshot as C, DocumentModel as D, ExpressionEngine as E,
|
|
3090
|
+
export { type ApplyChangesResult as A, type BatcherMetrics as B, type CacheSnapshot as C, DocumentModel as D, ExpressionEngine as E, LanguageService as F, type LanguageServiceOptions as G, type SemanticToken as H, type IEnginePackage as I, type ParsingResult as J, type LineChange as L, type ParsedLine as P, SNAPSHOT_FORMAT as S, type UnifiedParsingOptions as U, type ViewportRange as V, type EngineOptions as a, type EngineRestoreOptions as b, type EngineSnapshot as c, type Explanation as d, type ExplanationStep as e, SNAPSHOT_VERSION as f, type SerializedAnonymousBody as g, type SerializedBytecode as h, type SerializedDecimal as i, type SerializedLineCacheEntry as j, type SerializedNumber as k, type SerializedRational as l, type SerializedUserFunction as m, type SerializedValue as n, SnapshotErrorCodes as o, type InlineSolvePosition as p, type AsyncCachePackageInfo as q, type AsyncErrorEvent as r, AsyncResolutionBatcher as s, type AsyncResolutionEvent as t, type BytecodeCacheEntry as u, type CheckpointSnapshot as v, type LineCacheEntryInfo as w, type LineState as x, type LinesUpdatedEvent as y, type CompletionItem as z };
|