jssm 5.143.26 → 5.143.28

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 CHANGED
@@ -18,10 +18,10 @@ Please edit the file it's derived from, instead: `./src/md/readme_base.md`
18
18
 
19
19
 
20
20
 
21
- * Generated for version 5.143.26 at 6/12/2026, 2:39:54 PM
21
+ * Generated for version 5.143.28 at 6/12/2026, 4:10:08 PM
22
22
 
23
23
  -->
24
- # jssm 5.143.26
24
+ # jssm 5.143.28
25
25
 
26
26
  [**Try the live editor**](https://stonecypher.github.io/jssm-viz-demo/graph_explorer.html) ·
27
27
  [Documentation](https://stonecypher.github.io/jssm/docs/) ·
@@ -281,7 +281,7 @@ That decision shows up everywhere downstream:
281
281
  or run `npm run benny` against your own machine.
282
282
 
283
283
  - **More thoroughly tested than any other JavaScript state-machine
284
- library.** 7,013 tests at 100.0% line coverage
284
+ library.** 7,017 tests at 100.0% line coverage
285
285
  ([report](https://coveralls.io/github/StoneCypher/jssm)), plus
286
286
  fuzz testing via `fast-check`, with parser test data across ten natural
287
287
  languages and Emoji.
@@ -414,9 +414,9 @@ If your contribution is missing here, please open an issue.
414
414
 
415
415
  <br/>
416
416
 
417
- ***7,013 tests***, run 81,857 times.
417
+ ***7,017 tests***, run 81,861 times.
418
418
 
419
- - 6,257 specs with 100.0% coverage
419
+ - 6,261 specs with 100.0% coverage
420
420
  - 756 fuzz tests with 83.5% coverage
421
421
  - 5,880 TypeScript lines - 1.2 tests per line, 13.9 generated tests per line
422
422
 
@@ -11154,511 +11154,65 @@ function peg$parse(input, options) {
11154
11154
  }
11155
11155
  return s0;
11156
11156
  }
11157
+ var peg$timetype_alts = [
11158
+ [12, peg$c1230, peg$c1231, peg$c1232, 109],
11159
+ [11, peg$c1233, peg$c1234, peg$c1232, 109],
11160
+ [5, peg$c1235, peg$c1236, peg$c1232, 109],
11161
+ [4, peg$c1237, peg$c1238, peg$c1232, 109],
11162
+ [2, peg$c1239, peg$c1240, peg$c1232, 109],
11163
+ [7, peg$c1241, peg$c1242, peg$c1243, 115],
11164
+ [6, peg$c1244, peg$c1245, peg$c1243, 115],
11165
+ [4, peg$c1246, peg$c1247, peg$c1243, 115],
11166
+ [3, peg$c1248, peg$c1249, peg$c1243, 115],
11167
+ [1, peg$c1250, peg$c1251, peg$c1243, 115],
11168
+ [7, peg$c1252, peg$c1253, peg$c1254, 109],
11169
+ [6, peg$c1255, peg$c1256, peg$c1254, 109],
11170
+ [4, peg$c1257, peg$c1258, peg$c1254, 109],
11171
+ [3, peg$c1259, peg$c1260, peg$c1254, 109],
11172
+ [1, peg$c1261, peg$c1262, peg$c1254, 109],
11173
+ [5, peg$c1263, peg$c1264, peg$c1265, 104],
11174
+ [4, peg$c1266, peg$c1267, peg$c1265, 104],
11175
+ [3, peg$c1268, peg$c1269, peg$c1265, 104],
11176
+ [2, peg$c1270, peg$c1271, peg$c1265, 104],
11177
+ [1, peg$c1272, peg$c1273, peg$c1265, 104],
11178
+ [4, peg$c1274, peg$c1275, peg$c1276, 100],
11179
+ [3, peg$c1277, peg$c1278, peg$c1276, 100],
11180
+ [1, peg$c1279, peg$c1280, peg$c1276, 100],
11181
+ [5, peg$c1281, peg$c1282, peg$c1283, 119],
11182
+ [4, peg$c1284, peg$c1285, peg$c1283, 119],
11183
+ [3, peg$c1286, peg$c1287, peg$c1283, 119],
11184
+ [2, peg$c1288, peg$c1289, peg$c1283, 119],
11185
+ [1, peg$c1290, peg$c1291, peg$c1283, 119]
11186
+ ];
11157
11187
  function peg$parseTimeType() {
11158
- var s0, s1;
11159
- s0 = peg$currPos;
11160
- if (input.substr(peg$currPos, 12) === peg$c1230) {
11161
- s1 = peg$c1230;
11162
- peg$currPos += 12;
11163
- }
11164
- else {
11165
- s1 = peg$FAILED;
11166
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11167
- peg$fail(peg$c1231);
11168
- }
11169
- }
11170
- if (s1 !== peg$FAILED) {
11171
- peg$savedPos = s0;
11172
- s1 = peg$c1232();
11173
- }
11174
- s0 = s1;
11175
- if (s0 === peg$FAILED) {
11176
- s0 = peg$currPos;
11177
- if (input.substr(peg$currPos, 11) === peg$c1233) {
11178
- s1 = peg$c1233;
11179
- peg$currPos += 11;
11188
+ var i, j, alt, start;
11189
+ var c = input.charCodeAt(peg$currPos);
11190
+ for (i = 0; i < 28; i++) {
11191
+ alt = peg$timetype_alts[i];
11192
+ if (alt[4] !== c) {
11193
+ continue;
11194
+ } // first-char gate
11195
+ if (alt[0] !== 1 && input.substr(peg$currPos, alt[0]) !== alt[1]) {
11196
+ continue;
11180
11197
  }
11181
- else {
11182
- s1 = peg$FAILED;
11183
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11184
- peg$fail(peg$c1234);
11198
+ // replay the expectations of every alternative the generated chain
11199
+ // would have probed and failed before this one, at the unmoved position
11200
+ if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11201
+ for (j = 0; j < i; j++) {
11202
+ peg$fail(peg$timetype_alts[j][2]);
11185
11203
  }
11186
11204
  }
11187
- if (s1 !== peg$FAILED) {
11188
- peg$savedPos = s0;
11189
- s1 = peg$c1232();
11190
- }
11191
- s0 = s1;
11192
- if (s0 === peg$FAILED) {
11193
- s0 = peg$currPos;
11194
- if (input.substr(peg$currPos, 5) === peg$c1235) {
11195
- s1 = peg$c1235;
11196
- peg$currPos += 5;
11197
- }
11198
- else {
11199
- s1 = peg$FAILED;
11200
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11201
- peg$fail(peg$c1236);
11202
- }
11203
- }
11204
- if (s1 !== peg$FAILED) {
11205
- peg$savedPos = s0;
11206
- s1 = peg$c1232();
11207
- }
11208
- s0 = s1;
11209
- if (s0 === peg$FAILED) {
11210
- s0 = peg$currPos;
11211
- if (input.substr(peg$currPos, 4) === peg$c1237) {
11212
- s1 = peg$c1237;
11213
- peg$currPos += 4;
11214
- }
11215
- else {
11216
- s1 = peg$FAILED;
11217
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11218
- peg$fail(peg$c1238);
11219
- }
11220
- }
11221
- if (s1 !== peg$FAILED) {
11222
- peg$savedPos = s0;
11223
- s1 = peg$c1232();
11224
- }
11225
- s0 = s1;
11226
- if (s0 === peg$FAILED) {
11227
- s0 = peg$currPos;
11228
- if (input.substr(peg$currPos, 2) === peg$c1239) {
11229
- s1 = peg$c1239;
11230
- peg$currPos += 2;
11231
- }
11232
- else {
11233
- s1 = peg$FAILED;
11234
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11235
- peg$fail(peg$c1240);
11236
- }
11237
- }
11238
- if (s1 !== peg$FAILED) {
11239
- peg$savedPos = s0;
11240
- s1 = peg$c1232();
11241
- }
11242
- s0 = s1;
11243
- if (s0 === peg$FAILED) {
11244
- s0 = peg$currPos;
11245
- if (input.substr(peg$currPos, 7) === peg$c1241) {
11246
- s1 = peg$c1241;
11247
- peg$currPos += 7;
11248
- }
11249
- else {
11250
- s1 = peg$FAILED;
11251
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11252
- peg$fail(peg$c1242);
11253
- }
11254
- }
11255
- if (s1 !== peg$FAILED) {
11256
- peg$savedPos = s0;
11257
- s1 = peg$c1243();
11258
- }
11259
- s0 = s1;
11260
- if (s0 === peg$FAILED) {
11261
- s0 = peg$currPos;
11262
- if (input.substr(peg$currPos, 6) === peg$c1244) {
11263
- s1 = peg$c1244;
11264
- peg$currPos += 6;
11265
- }
11266
- else {
11267
- s1 = peg$FAILED;
11268
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11269
- peg$fail(peg$c1245);
11270
- }
11271
- }
11272
- if (s1 !== peg$FAILED) {
11273
- peg$savedPos = s0;
11274
- s1 = peg$c1243();
11275
- }
11276
- s0 = s1;
11277
- if (s0 === peg$FAILED) {
11278
- s0 = peg$currPos;
11279
- if (input.substr(peg$currPos, 4) === peg$c1246) {
11280
- s1 = peg$c1246;
11281
- peg$currPos += 4;
11282
- }
11283
- else {
11284
- s1 = peg$FAILED;
11285
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11286
- peg$fail(peg$c1247);
11287
- }
11288
- }
11289
- if (s1 !== peg$FAILED) {
11290
- peg$savedPos = s0;
11291
- s1 = peg$c1243();
11292
- }
11293
- s0 = s1;
11294
- if (s0 === peg$FAILED) {
11295
- s0 = peg$currPos;
11296
- if (input.substr(peg$currPos, 3) === peg$c1248) {
11297
- s1 = peg$c1248;
11298
- peg$currPos += 3;
11299
- }
11300
- else {
11301
- s1 = peg$FAILED;
11302
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11303
- peg$fail(peg$c1249);
11304
- }
11305
- }
11306
- if (s1 !== peg$FAILED) {
11307
- peg$savedPos = s0;
11308
- s1 = peg$c1243();
11309
- }
11310
- s0 = s1;
11311
- if (s0 === peg$FAILED) {
11312
- s0 = peg$currPos;
11313
- if (input.charCodeAt(peg$currPos) === 115) {
11314
- s1 = peg$c1250;
11315
- peg$currPos++;
11316
- }
11317
- else {
11318
- s1 = peg$FAILED;
11319
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11320
- peg$fail(peg$c1251);
11321
- }
11322
- }
11323
- if (s1 !== peg$FAILED) {
11324
- peg$savedPos = s0;
11325
- s1 = peg$c1243();
11326
- }
11327
- s0 = s1;
11328
- if (s0 === peg$FAILED) {
11329
- s0 = peg$currPos;
11330
- if (input.substr(peg$currPos, 7) === peg$c1252) {
11331
- s1 = peg$c1252;
11332
- peg$currPos += 7;
11333
- }
11334
- else {
11335
- s1 = peg$FAILED;
11336
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11337
- peg$fail(peg$c1253);
11338
- }
11339
- }
11340
- if (s1 !== peg$FAILED) {
11341
- peg$savedPos = s0;
11342
- s1 = peg$c1254();
11343
- }
11344
- s0 = s1;
11345
- if (s0 === peg$FAILED) {
11346
- s0 = peg$currPos;
11347
- if (input.substr(peg$currPos, 6) === peg$c1255) {
11348
- s1 = peg$c1255;
11349
- peg$currPos += 6;
11350
- }
11351
- else {
11352
- s1 = peg$FAILED;
11353
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11354
- peg$fail(peg$c1256);
11355
- }
11356
- }
11357
- if (s1 !== peg$FAILED) {
11358
- peg$savedPos = s0;
11359
- s1 = peg$c1254();
11360
- }
11361
- s0 = s1;
11362
- if (s0 === peg$FAILED) {
11363
- s0 = peg$currPos;
11364
- if (input.substr(peg$currPos, 4) === peg$c1257) {
11365
- s1 = peg$c1257;
11366
- peg$currPos += 4;
11367
- }
11368
- else {
11369
- s1 = peg$FAILED;
11370
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11371
- peg$fail(peg$c1258);
11372
- }
11373
- }
11374
- if (s1 !== peg$FAILED) {
11375
- peg$savedPos = s0;
11376
- s1 = peg$c1254();
11377
- }
11378
- s0 = s1;
11379
- if (s0 === peg$FAILED) {
11380
- s0 = peg$currPos;
11381
- if (input.substr(peg$currPos, 3) === peg$c1259) {
11382
- s1 = peg$c1259;
11383
- peg$currPos += 3;
11384
- }
11385
- else {
11386
- s1 = peg$FAILED;
11387
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11388
- peg$fail(peg$c1260);
11389
- }
11390
- }
11391
- if (s1 !== peg$FAILED) {
11392
- peg$savedPos = s0;
11393
- s1 = peg$c1254();
11394
- }
11395
- s0 = s1;
11396
- if (s0 === peg$FAILED) {
11397
- s0 = peg$currPos;
11398
- if (input.charCodeAt(peg$currPos) === 109) {
11399
- s1 = peg$c1261;
11400
- peg$currPos++;
11401
- }
11402
- else {
11403
- s1 = peg$FAILED;
11404
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11405
- peg$fail(peg$c1262);
11406
- }
11407
- }
11408
- if (s1 !== peg$FAILED) {
11409
- peg$savedPos = s0;
11410
- s1 = peg$c1254();
11411
- }
11412
- s0 = s1;
11413
- if (s0 === peg$FAILED) {
11414
- s0 = peg$currPos;
11415
- if (input.substr(peg$currPos, 5) === peg$c1263) {
11416
- s1 = peg$c1263;
11417
- peg$currPos += 5;
11418
- }
11419
- else {
11420
- s1 = peg$FAILED;
11421
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11422
- peg$fail(peg$c1264);
11423
- }
11424
- }
11425
- if (s1 !== peg$FAILED) {
11426
- peg$savedPos = s0;
11427
- s1 = peg$c1265();
11428
- }
11429
- s0 = s1;
11430
- if (s0 === peg$FAILED) {
11431
- s0 = peg$currPos;
11432
- if (input.substr(peg$currPos, 4) === peg$c1266) {
11433
- s1 = peg$c1266;
11434
- peg$currPos += 4;
11435
- }
11436
- else {
11437
- s1 = peg$FAILED;
11438
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11439
- peg$fail(peg$c1267);
11440
- }
11441
- }
11442
- if (s1 !== peg$FAILED) {
11443
- peg$savedPos = s0;
11444
- s1 = peg$c1265();
11445
- }
11446
- s0 = s1;
11447
- if (s0 === peg$FAILED) {
11448
- s0 = peg$currPos;
11449
- if (input.substr(peg$currPos, 3) === peg$c1268) {
11450
- s1 = peg$c1268;
11451
- peg$currPos += 3;
11452
- }
11453
- else {
11454
- s1 = peg$FAILED;
11455
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11456
- peg$fail(peg$c1269);
11457
- }
11458
- }
11459
- if (s1 !== peg$FAILED) {
11460
- peg$savedPos = s0;
11461
- s1 = peg$c1265();
11462
- }
11463
- s0 = s1;
11464
- if (s0 === peg$FAILED) {
11465
- s0 = peg$currPos;
11466
- if (input.substr(peg$currPos, 2) === peg$c1270) {
11467
- s1 = peg$c1270;
11468
- peg$currPos += 2;
11469
- }
11470
- else {
11471
- s1 = peg$FAILED;
11472
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11473
- peg$fail(peg$c1271);
11474
- }
11475
- }
11476
- if (s1 !== peg$FAILED) {
11477
- peg$savedPos = s0;
11478
- s1 = peg$c1265();
11479
- }
11480
- s0 = s1;
11481
- if (s0 === peg$FAILED) {
11482
- s0 = peg$currPos;
11483
- if (input.charCodeAt(peg$currPos) === 104) {
11484
- s1 = peg$c1272;
11485
- peg$currPos++;
11486
- }
11487
- else {
11488
- s1 = peg$FAILED;
11489
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11490
- peg$fail(peg$c1273);
11491
- }
11492
- }
11493
- if (s1 !== peg$FAILED) {
11494
- peg$savedPos = s0;
11495
- s1 = peg$c1265();
11496
- }
11497
- s0 = s1;
11498
- if (s0 === peg$FAILED) {
11499
- s0 = peg$currPos;
11500
- if (input.substr(peg$currPos, 4) === peg$c1274) {
11501
- s1 = peg$c1274;
11502
- peg$currPos += 4;
11503
- }
11504
- else {
11505
- s1 = peg$FAILED;
11506
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11507
- peg$fail(peg$c1275);
11508
- }
11509
- }
11510
- if (s1 !== peg$FAILED) {
11511
- peg$savedPos = s0;
11512
- s1 = peg$c1276();
11513
- }
11514
- s0 = s1;
11515
- if (s0 === peg$FAILED) {
11516
- s0 = peg$currPos;
11517
- if (input.substr(peg$currPos, 3) === peg$c1277) {
11518
- s1 = peg$c1277;
11519
- peg$currPos += 3;
11520
- }
11521
- else {
11522
- s1 = peg$FAILED;
11523
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11524
- peg$fail(peg$c1278);
11525
- }
11526
- }
11527
- if (s1 !== peg$FAILED) {
11528
- peg$savedPos = s0;
11529
- s1 = peg$c1276();
11530
- }
11531
- s0 = s1;
11532
- if (s0 === peg$FAILED) {
11533
- s0 = peg$currPos;
11534
- if (input.charCodeAt(peg$currPos) === 100) {
11535
- s1 = peg$c1279;
11536
- peg$currPos++;
11537
- }
11538
- else {
11539
- s1 = peg$FAILED;
11540
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11541
- peg$fail(peg$c1280);
11542
- }
11543
- }
11544
- if (s1 !== peg$FAILED) {
11545
- peg$savedPos = s0;
11546
- s1 = peg$c1276();
11547
- }
11548
- s0 = s1;
11549
- if (s0 === peg$FAILED) {
11550
- s0 = peg$currPos;
11551
- if (input.substr(peg$currPos, 5) === peg$c1281) {
11552
- s1 = peg$c1281;
11553
- peg$currPos += 5;
11554
- }
11555
- else {
11556
- s1 = peg$FAILED;
11557
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11558
- peg$fail(peg$c1282);
11559
- }
11560
- }
11561
- if (s1 !== peg$FAILED) {
11562
- peg$savedPos = s0;
11563
- s1 = peg$c1283();
11564
- }
11565
- s0 = s1;
11566
- if (s0 === peg$FAILED) {
11567
- s0 = peg$currPos;
11568
- if (input.substr(peg$currPos, 4) === peg$c1284) {
11569
- s1 = peg$c1284;
11570
- peg$currPos += 4;
11571
- }
11572
- else {
11573
- s1 = peg$FAILED;
11574
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11575
- peg$fail(peg$c1285);
11576
- }
11577
- }
11578
- if (s1 !== peg$FAILED) {
11579
- peg$savedPos = s0;
11580
- s1 = peg$c1283();
11581
- }
11582
- s0 = s1;
11583
- if (s0 === peg$FAILED) {
11584
- s0 = peg$currPos;
11585
- if (input.substr(peg$currPos, 3) === peg$c1286) {
11586
- s1 = peg$c1286;
11587
- peg$currPos += 3;
11588
- }
11589
- else {
11590
- s1 = peg$FAILED;
11591
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11592
- peg$fail(peg$c1287);
11593
- }
11594
- }
11595
- if (s1 !== peg$FAILED) {
11596
- peg$savedPos = s0;
11597
- s1 = peg$c1283();
11598
- }
11599
- s0 = s1;
11600
- if (s0 === peg$FAILED) {
11601
- s0 = peg$currPos;
11602
- if (input.substr(peg$currPos, 2) === peg$c1288) {
11603
- s1 = peg$c1288;
11604
- peg$currPos += 2;
11605
- }
11606
- else {
11607
- s1 = peg$FAILED;
11608
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11609
- peg$fail(peg$c1289);
11610
- }
11611
- }
11612
- if (s1 !== peg$FAILED) {
11613
- peg$savedPos = s0;
11614
- s1 = peg$c1283();
11615
- }
11616
- s0 = s1;
11617
- if (s0 === peg$FAILED) {
11618
- s0 = peg$currPos;
11619
- if (input.charCodeAt(peg$currPos) === 119) {
11620
- s1 = peg$c1290;
11621
- peg$currPos++;
11622
- }
11623
- else {
11624
- s1 = peg$FAILED;
11625
- if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11626
- peg$fail(peg$c1291);
11627
- }
11628
- }
11629
- if (s1 !== peg$FAILED) {
11630
- peg$savedPos = s0;
11631
- s1 = peg$c1283();
11632
- }
11633
- s0 = s1;
11634
- }
11635
- }
11636
- }
11637
- }
11638
- }
11639
- }
11640
- }
11641
- }
11642
- }
11643
- }
11644
- }
11645
- }
11646
- }
11647
- }
11648
- }
11649
- }
11650
- }
11651
- }
11652
- }
11653
- }
11654
- }
11655
- }
11656
- }
11657
- }
11658
- }
11205
+ start = peg$currPos;
11206
+ peg$currPos += alt[0];
11207
+ peg$savedPos = start;
11208
+ return alt[3]();
11209
+ }
11210
+ if (peg$silentFails === 0 && peg$currPos >= peg$maxFailPos) {
11211
+ for (j = 0; j < 28; j++) {
11212
+ peg$fail(peg$timetype_alts[j][2]);
11659
11213
  }
11660
11214
  }
11661
- return s0;
11215
+ return peg$FAILED;
11662
11216
  }
11663
11217
  function peg$parseArrowAfter() {
11664
11218
  var s0, s1, s2, s3, s4, s5;
@@ -22388,7 +21942,7 @@ var constants = /*#__PURE__*/Object.freeze({
22388
21942
  * Useful for runtime diagnostics and for embedding in serialized machine
22389
21943
  * snapshots so that deserializers can detect version-skew.
22390
21944
  */
22391
- const version = "5.143.26";
21945
+ const version = "5.143.28";
22392
21946
 
22393
21947
  // whargarbl lots of these return arrays could/should be sets
22394
21948
  const { state_name_chars, state_name_first_chars, action_label_chars } = constants;