chess4js 1.0.0-beta.5 → 1.0.0-beta.6

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/chess4js.mjs CHANGED
@@ -35,6 +35,8 @@ import {
35
35
  THROW_IAE23kobfj9wdoxr as THROW_IAE,
36
36
  asSequence2jzw5xbq99nu9 as asSequence_2,
37
37
  emptyList1g2z5xcrvp2zy as emptyList,
38
+ ensureNotNull1e947j3ixpazm as ensureNotNull,
39
+ IllegalArgumentException2asla15b5jaob as IllegalArgumentException,
38
40
  initMetadataForInterface1egvbzx539z91 as initMetadataForInterface,
39
41
  UnsupportedOperationException2tkumpmhredt3 as UnsupportedOperationException,
40
42
  toString30pk9tzaqopn as toString_0,
@@ -71,7 +73,6 @@ import {
71
73
  copyOf1fl7rfmnz2fa3 as copyOf,
72
74
  convertToInty04h231mmjoh as convertToInt,
73
75
  toLongArray23ixicpzp5r3w as toLongArray,
74
- IllegalArgumentException2asla15b5jaob as IllegalArgumentException,
75
76
  toString3o7ifthqydp6e as toString_1,
76
77
  longArray288a0fctlmjmj as longArray,
77
78
  contentEqualsc4e23leqcdd7 as contentEquals,
@@ -88,7 +89,6 @@ import {
88
89
  countOneBits2h2gnqaw24v9c as countOneBits,
89
90
  get_sign1dnxi33u9vk0c as get_sign,
90
91
  negate13xrbakfwasjy as negate,
91
- ensureNotNull1e947j3ixpazm as ensureNotNull,
92
92
  shiftRight2gqph14wydb8s as shiftRight,
93
93
  until1jbpn0z3f8lbg as until,
94
94
  addAll1k27qatfgp3k5 as addAll,
@@ -102,12 +102,12 @@ import {
102
102
  trimIndent1qytc1wvt8suh as trimIndent,
103
103
  Collection1k04j3hzsbod0 as Collection,
104
104
  isInterface3d6p8outrmvmk as isInterface,
105
- startsWith5hna0vjiqaqm as startsWith,
106
105
  hashCodeq5arwsb9dgti as hashCode,
107
106
  getc6436eumi25w as get,
108
107
  Paire9pteg33gng7 as Pair,
109
108
  titlecase36e9fbud5gg4t as titlecase,
110
109
  isLowerCase16nv9n55l9laa as isLowerCase,
110
+ startsWith5hna0vjiqaqm as startsWith,
111
111
  first3kg261hmihapu as first,
112
112
  countTrailingZeroBitszhs0313cn11e as countTrailingZeroBits_0,
113
113
  takeLowestOneBitmqr3ckwas5mk as takeLowestOneBit,
@@ -428,55 +428,94 @@ function hasChildren() {
428
428
  // Inline function 'kotlin.collections.isNotEmpty' call
429
429
  return !this.bj().c2();
430
430
  }
431
+ function toSan(language, pieces) {
432
+ if (this.rk() == null) {
433
+ return '';
434
+ }
435
+ var tmp;
436
+ switch (language) {
437
+ case 'english':
438
+ tmp = toSan_0(ensureNotNull(this.aj()).uj(), ensureNotNull(this.rk()));
439
+ break;
440
+ case 'spanish':
441
+ tmp = toSan_0(ensureNotNull(this.aj()).uj(), ensureNotNull(this.rk()), get_piecesSpanish());
442
+ break;
443
+ case 'dutch':
444
+ tmp = toSan_0(ensureNotNull(this.aj()).uj(), ensureNotNull(this.rk()), get_piecesDutch());
445
+ break;
446
+ case 'french':
447
+ tmp = toSan_0(ensureNotNull(this.aj()).uj(), ensureNotNull(this.rk()), get_piecesFrench());
448
+ break;
449
+ case 'german':
450
+ tmp = toSan_0(ensureNotNull(this.aj()).uj(), ensureNotNull(this.rk()), get_piecesGerman());
451
+ break;
452
+ case 'italian':
453
+ tmp = toSan_0(ensureNotNull(this.aj()).uj(), ensureNotNull(this.rk()), get_piecesItalian());
454
+ break;
455
+ default:
456
+ var tmp_0;
457
+ if (pieces == null) {
458
+ throw IllegalArgumentException.s('unknown language: ' + language + ' and pieces array is null');
459
+ } else if (!(pieces.length === 12)) {
460
+ throw IllegalArgumentException.s('unknown language: ' + language + ' and invalid pieces array');
461
+ } else {
462
+ tmp_0 = toSan_0(ensureNotNull(this.aj()).uj(), ensureNotNull(this.rk()), pieces);
463
+ }
464
+
465
+ tmp = tmp_0;
466
+ break;
467
+ }
468
+ return tmp;
469
+ }
431
470
  class RootNode {
432
471
  constructor($outer, position) {
433
- this.ll_1 = $outer;
434
- this.dl_1 = position;
435
- this.el_1 = null;
472
+ this.ml_1 = $outer;
473
+ this.el_1 = position;
474
+ this.fl_1 = null;
436
475
  var tmp = this;
437
476
  // Inline function 'kotlin.collections.mutableListOf' call
438
- tmp.fl_1 = ArrayList.h1();
439
- this.gl_1 = null;
477
+ tmp.gl_1 = ArrayList.h1();
440
478
  this.hl_1 = null;
441
479
  this.il_1 = null;
442
480
  this.jl_1 = null;
443
481
  this.kl_1 = null;
482
+ this.ll_1 = null;
444
483
  }
445
484
  uj() {
446
- return this.dl_1;
485
+ return this.el_1;
447
486
  }
448
487
  cj() {
449
- return this.el_1;
488
+ return this.fl_1;
450
489
  }
451
490
  bj() {
452
- return this.fl_1;
491
+ return this.gl_1;
453
492
  }
454
493
  dj() {
455
- return this.gl_1;
494
+ return this.hl_1;
456
495
  }
457
- ml(value) {
496
+ nl(value) {
458
497
  throw UnsupportedOperationException.da('RootNode does not accept suffix annotations.');
459
498
  }
460
499
  tk() {
461
- return this.hl_1;
500
+ return this.il_1;
462
501
  }
463
502
  uk(value) {
464
503
  throw UnsupportedOperationException.da('RootNode does not accept a parent');
465
504
  }
466
505
  aj() {
467
- return this.il_1;
506
+ return this.jl_1;
468
507
  }
469
508
  rk() {
470
- return this.jl_1;
509
+ return this.kl_1;
471
510
  }
472
511
  sk() {
473
- return this.kl_1;
512
+ return this.ll_1;
474
513
  }
475
514
  hashCode() {
476
515
  // Inline function 'kotlin.arrayOf' call
477
516
  // Inline function 'kotlin.js.unsafeCast' call
478
517
  // Inline function 'kotlin.js.asDynamic' call
479
- var tmp$ret$2 = [this.dl_1, this.el_1];
518
+ var tmp$ret$2 = [this.el_1, this.fl_1];
480
519
  return genericHashCode(tmp$ret$2);
481
520
  }
482
521
  equals(other) {
@@ -490,14 +529,14 @@ class RootNode {
490
529
  if (!(other instanceof RootNode)) {
491
530
  tmp = false;
492
531
  } else {
493
- tmp = (this.dl_1.equals(other.dl_1) && this.el_1 == other.el_1 && this.gl_1 == other.gl_1);
532
+ tmp = (this.el_1.equals(other.el_1) && this.fl_1 == other.fl_1 && this.hl_1 == other.hl_1);
494
533
  }
495
534
  }
496
535
  }
497
536
  return tmp;
498
537
  }
499
538
  toString() {
500
- var tmp0_safe_receiver = this.el_1;
539
+ var tmp0_safe_receiver = this.fl_1;
501
540
  var tmp;
502
541
  if (tmp0_safe_receiver == null) {
503
542
  tmp = null;
@@ -506,7 +545,7 @@ class RootNode {
506
545
  tmp = '{' + tmp0_safe_receiver + '}';
507
546
  }
508
547
  var tmp_0 = tmp;
509
- var tmp1_safe_receiver = this.gl_1;
548
+ var tmp1_safe_receiver = this.hl_1;
510
549
  var tmp_1;
511
550
  if (tmp1_safe_receiver == null) {
512
551
  tmp_1 = null;
@@ -517,18 +556,18 @@ class RootNode {
517
556
  return '' + tmp_0 + tmp_1;
518
557
  }
519
558
  vk(move_0, initialComment, comment, endLineComment, suffixAnnotations, notation) {
520
- if (immutable(this.ll_1)) {
521
- Companion_getInstance_1().vj_1.nl('trying to make move ' + move_0 + ' on immutable game id=' + toString_0(this.ll_1.lk_1));
559
+ if (immutable(this.ml_1)) {
560
+ Companion_getInstance_1().vj_1.ol('trying to make move ' + move_0 + ' on immutable game id=' + toString_0(this.ml_1.lk_1));
522
561
  return this;
523
562
  }
524
- if (this.fl_1.b1() === 1 && this.ll_1.dk_1.equals(GameMode_MATCH_getInstance())) {
525
- throw GameModeException.rl('Match mode cannot accept variations (RAVs); only the main line is allowed.');
563
+ if (this.gl_1.b1() === 1 && this.ml_1.dk_1.equals(GameMode_MATCH_getInstance())) {
564
+ throw GameModeException.sl('Match mode cannot accept variations (RAVs); only the main line is allowed.');
526
565
  }
527
566
  try {
528
567
  var tmp;
529
568
  switch (notation.m2_1) {
530
569
  case 1:
531
- tmp = sanToMove(this.dl_1, move_0);
570
+ tmp = sanToMove(this.el_1, move_0);
532
571
  break;
533
572
  case 0:
534
573
  tmp = moveOf_2(move_0);
@@ -538,22 +577,22 @@ class RootNode {
538
577
  break;
539
578
  }
540
579
  var m = tmp;
541
- var child = new MoveNode(this.ll_1, move(this.dl_1, m), m, initialComment, comment, endLineComment, suffixAnnotations, this);
542
- this.fl_1.k(child);
543
- if (this.fl_1.b1() === 1) {
544
- if (this.ll_1.dk_1.equals(GameMode_MATCH_getInstance())) {
545
- this.ll_1.sl();
580
+ var child = new MoveNode(this.ml_1, move(this.el_1, m), m, initialComment, comment, endLineComment, suffixAnnotations, this);
581
+ this.gl_1.k(child);
582
+ if (this.gl_1.b1() === 1) {
583
+ if (this.ml_1.dk_1.equals(GameMode_MATCH_getInstance())) {
584
+ this.ml_1.tl();
546
585
  }
547
- this.ll_1.tl(child);
548
- this.ll_1.ul(child);
549
- this.ll_1.vl(child);
550
- this.ll_1.wl(child);
586
+ this.ml_1.ul(child);
587
+ this.ml_1.vl(child);
588
+ this.ml_1.wl(child);
589
+ this.ml_1.xl(child);
551
590
  }
552
591
  return child;
553
592
  } catch ($p) {
554
593
  if ($p instanceof MoveException) {
555
594
  var e = $p;
556
- Companion_getInstance_1().vj_1.xl(e);
595
+ Companion_getInstance_1().vj_1.yl(e);
557
596
  return this;
558
597
  } else {
559
598
  throw $p;
@@ -565,12 +604,12 @@ class RootNode {
565
604
  }
566
605
  cl(parent) {
567
606
  // Inline function 'kotlin.apply' call
568
- var this_0 = new RootNode(this.ll_1, this.dl_1);
569
- this_0.el_1 = this.el_1;
570
- this_0.gl_1 = this.gl_1;
571
- this_0.ml(this.hl_1);
607
+ var this_0 = new RootNode(this.ml_1, this.el_1);
608
+ this_0.fl_1 = this.fl_1;
609
+ this_0.hl_1 = this.hl_1;
610
+ this_0.nl(this.il_1);
572
611
  // Inline function 'kotlin.collections.map' call
573
- var this_1 = this.fl_1;
612
+ var this_1 = this.gl_1;
574
613
  // Inline function 'kotlin.collections.mapTo' call
575
614
  var destination = ArrayList.l5(collectionSizeOrDefault(this_1, 10));
576
615
  var _iterator__ex2g4s = this_1.x();
@@ -579,7 +618,7 @@ class RootNode {
579
618
  var tmp$ret$0 = item.cl(this_0);
580
619
  destination.k(tmp$ret$0);
581
620
  }
582
- this_0.fl_1.b4(destination);
621
+ this_0.gl_1.b4(destination);
583
622
  return this_0;
584
623
  }
585
624
  }
@@ -653,7 +692,7 @@ class MoveNode {
653
692
  }
654
693
  vk(move_0, initialComment, comment, endLineComment, suffixAnnotations, notation) {
655
694
  if (immutable(this.vi_1)) {
656
- Companion_getInstance_1().vj_1.nl('trying to make move ' + move_0 + ' on immutable game id=' + toString_0(this.vi_1.lk_1));
695
+ Companion_getInstance_1().vj_1.ol('trying to make move ' + move_0 + ' on immutable game id=' + toString_0(this.vi_1.lk_1));
657
696
  return this;
658
697
  }
659
698
  var tmp;
@@ -664,7 +703,7 @@ class MoveNode {
664
703
  tmp = false;
665
704
  }
666
705
  if (tmp) {
667
- throw GameModeException.rl('Match mode cannot accept variations. Only the main line is allowed.');
706
+ throw GameModeException.sl('Match mode cannot accept variations. Only the main line is allowed.');
668
707
  }
669
708
  try {
670
709
  var tmp_0;
@@ -687,18 +726,18 @@ class MoveNode {
687
726
  }
688
727
  if (last(asSequence_1(this.vi_1.x())) === child) {
689
728
  if (this.vi_1.dk_1.equals(GameMode_MATCH_getInstance())) {
690
- this.vi_1.sl();
729
+ this.vi_1.tl();
691
730
  }
692
- this.vi_1.tl(child);
693
731
  this.vi_1.ul(child);
694
732
  this.vi_1.vl(child);
695
733
  this.vi_1.wl(child);
734
+ this.vi_1.xl(child);
696
735
  }
697
736
  return child;
698
737
  } catch ($p) {
699
738
  if ($p instanceof MoveException) {
700
739
  var e = $p;
701
- Companion_getInstance_1().vj_1.xl(e);
740
+ Companion_getInstance_1().vj_1.yl(e);
702
741
  return this;
703
742
  } else {
704
743
  throw $p;
@@ -752,7 +791,7 @@ class MoveNode {
752
791
  var tmp2_elvis_lhs = tmp_0;
753
792
  var tmp_1;
754
793
  if (tmp2_elvis_lhs == null) {
755
- throw Companion_getInstance_1().vj_1.xl(UnexpectedGameInternalError.zi("node parent can't be null"));
794
+ throw Companion_getInstance_1().vj_1.yl(UnexpectedGameInternalError.zi("node parent can't be null"));
756
795
  } else {
757
796
  tmp_1 = tmp2_elvis_lhs;
758
797
  }
@@ -770,23 +809,23 @@ class FiftyMovesRuleMode extends Enum {}
770
809
  class Result extends Enum {
771
810
  constructor(name, ordinal, str) {
772
811
  super(name, ordinal);
773
- this.am_1 = str;
812
+ this.bm_1 = str;
774
813
  }
775
814
  }
776
815
  class NodeIterator {
777
816
  constructor(curr) {
778
- this.bm_1 = curr;
817
+ this.cm_1 = curr;
779
818
  }
780
819
  a1() {
781
- var aux = this.bm_1;
782
- var tmp1_safe_receiver = this.bm_1;
820
+ var aux = this.cm_1;
821
+ var tmp1_safe_receiver = this.cm_1;
783
822
  var tmp2_elvis_lhs = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.al();
784
823
  if (tmp2_elvis_lhs == null ? false : tmp2_elvis_lhs) {
785
824
  var tmp = this;
786
- var tmp0_safe_receiver = this.bm_1;
787
- tmp.bm_1 = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.bj().c1(0);
825
+ var tmp0_safe_receiver = this.cm_1;
826
+ tmp.cm_1 = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.bj().c1(0);
788
827
  } else {
789
- this.bm_1 = null;
828
+ this.cm_1 = null;
790
829
  }
791
830
  var tmp_0;
792
831
  if (aux == null) {
@@ -797,19 +836,19 @@ class NodeIterator {
797
836
  return tmp_0;
798
837
  }
799
838
  z() {
800
- return !(this.bm_1 == null);
839
+ return !(this.cm_1 == null);
801
840
  }
802
841
  }
803
842
  class Repetitions {
804
843
  constructor() {
805
844
  var tmp = this;
806
845
  // Inline function 'kotlin.collections.mutableMapOf' call
807
- tmp.cm_1 = LinkedHashMap.v8();
846
+ tmp.dm_1 = LinkedHashMap.v8();
808
847
  }
809
- dm(node) {
810
- var tmp0 = this.cm_1;
848
+ em(node) {
849
+ var tmp0 = this.dm_1;
811
850
  var tmp2 = node.uj();
812
- var tmp0_safe_receiver = this.cm_1.j2(node.uj());
851
+ var tmp0_safe_receiver = this.dm_1.j2(node.uj());
813
852
  var tmp;
814
853
  if (tmp0_safe_receiver == null) {
815
854
  tmp = null;
@@ -821,11 +860,11 @@ class Repetitions {
821
860
  // Inline function 'kotlin.collections.set' call
822
861
  var value = tmp1_elvis_lhs == null ? 1 : tmp1_elvis_lhs;
823
862
  tmp0.f5(tmp2, value);
824
- var tmp2_elvis_lhs = this.cm_1.j2(node.uj());
863
+ var tmp2_elvis_lhs = this.dm_1.j2(node.uj());
825
864
  return tmp2_elvis_lhs == null ? 1 : tmp2_elvis_lhs;
826
865
  }
827
- em(node) {
828
- var tmp = asSequence(this.cm_1.k2());
866
+ fm(node) {
867
+ var tmp = asSequence(this.dm_1.k2());
829
868
  var tmp0 = filter(tmp, Game$Repetitions$warning$lambda);
830
869
  var tmp$ret$5;
831
870
  $l$block: {
@@ -863,79 +902,79 @@ class UnexpectedGameInternalError extends RuntimeException {
863
902
  }
864
903
  }
865
904
  class GameModeException extends RuntimeException {
866
- static rl(msg) {
905
+ static sl(msg) {
867
906
  var $this = this.l7(msg);
868
- captureStack($this, $this.ql_1);
907
+ captureStack($this, $this.rl_1);
869
908
  return $this;
870
909
  }
871
910
  }
872
911
  class Game {
873
- fm(value) {
912
+ gm(value) {
874
913
  if (immutable(this)) {
875
914
  return Unit_instance;
876
915
  }
877
916
  this.wj_1 = value;
878
917
  }
879
- gm(value) {
918
+ hm(value) {
880
919
  if (immutable(this)) {
881
920
  return Unit_instance;
882
921
  }
883
922
  this.yj_1 = value;
884
923
  }
885
- hm(value) {
924
+ im(value) {
886
925
  if (immutable(this)) {
887
926
  return Unit_instance;
888
927
  }
889
928
  this.zj_1 = value;
890
929
  }
891
- im(value) {
930
+ jm(value) {
892
931
  if (immutable(this)) {
893
932
  return Unit_instance;
894
933
  }
895
934
  this.ak_1 = value;
896
935
  }
897
- jm(value) {
936
+ km(value) {
898
937
  if (immutable(this)) {
899
938
  return Unit_instance;
900
939
  }
901
940
  this.bk_1 = value;
902
941
  }
903
- km(value) {
942
+ lm(value) {
904
943
  if (immutable(this)) {
905
944
  return Unit_instance;
906
945
  }
907
946
  this.ck_1 = value;
908
947
  }
909
- lm(value) {
948
+ mm(value) {
910
949
  if (immutable(this)) {
911
950
  return Unit_instance;
912
951
  }
913
952
  this.ek_1 = value;
914
953
  }
915
- mm(value) {
954
+ nm(value) {
916
955
  if (immutable(this)) {
917
956
  return Unit_instance;
918
957
  }
919
958
  var tmp0 = this.xj_1;
920
- var tmp1_elvis_lhs = value == null ? null : value.am_1;
959
+ var tmp1_elvis_lhs = value == null ? null : value.bm_1;
921
960
  // Inline function 'kotlin.collections.set' call
922
961
  var value_0 = tmp1_elvis_lhs == null ? 'unknown' : tmp1_elvis_lhs;
923
962
  tmp0.f5('result', value_0);
924
963
  this.fk_1 = value;
925
964
  }
926
- nm(value) {
965
+ om(value) {
927
966
  if (immutable(this)) {
928
967
  return Unit_instance;
929
968
  }
930
969
  this.jk_1 = value;
931
970
  }
932
- om(value) {
971
+ pm(value) {
933
972
  if (immutable(this)) {
934
973
  return Unit_instance;
935
974
  }
936
975
  this.kk_1 = value;
937
976
  }
938
- static pm(tags, gameMode, threeRepetitionsMode, fiftyMovesRuleMode, root, idSupplier) {
977
+ static qm(tags, gameMode, threeRepetitionsMode, fiftyMovesRuleMode, root, idSupplier) {
939
978
  Companion_getInstance_1();
940
979
  root = root === VOID ? null : root;
941
980
  var tmp;
@@ -948,7 +987,7 @@ class Game {
948
987
  var $this = createThis(this);
949
988
  init_io_github_lunalobos_chess4kt_Game($this);
950
989
  if (!(root == null)) {
951
- $this.fm(root);
990
+ $this.gm(root);
952
991
  } else {
953
992
  var tmp0_safe_receiver = tags.j2('fen');
954
993
  var tmp_0;
@@ -959,7 +998,7 @@ class Game {
959
998
  tmp_0 = positionOf_0(tmp0_safe_receiver);
960
999
  }
961
1000
  var tmp1_elvis_lhs = tmp_0;
962
- $this.fm(new RootNode($this, tmp1_elvis_lhs == null ? positionOf() : tmp1_elvis_lhs));
1001
+ $this.gm(new RootNode($this, tmp1_elvis_lhs == null ? positionOf() : tmp1_elvis_lhs));
963
1002
  }
964
1003
  $this.dk_1 = gameMode;
965
1004
  $this.gk_1 = threeRepetitionsMode;
@@ -974,7 +1013,7 @@ class Game {
974
1013
  tmp0.f5('id', value);
975
1014
  return $this;
976
1015
  }
977
- static qm(tags, gameMode, threeRepetitionsMode, fiftyMovesRuleMode, idSupplier) {
1016
+ static rm(tags, gameMode, threeRepetitionsMode, fiftyMovesRuleMode, idSupplier) {
978
1017
  Companion_getInstance_1();
979
1018
  var tmp;
980
1019
  if (idSupplier === VOID) {
@@ -994,7 +1033,7 @@ class Game {
994
1033
  tmp_0 = positionOf_0(tmp0_safe_receiver);
995
1034
  }
996
1035
  var tmp1_elvis_lhs = tmp_0;
997
- $this.fm(new RootNode($this, tmp1_elvis_lhs == null ? positionOf() : tmp1_elvis_lhs));
1036
+ $this.gm(new RootNode($this, tmp1_elvis_lhs == null ? positionOf() : tmp1_elvis_lhs));
998
1037
  $this.dk_1 = gameMode;
999
1038
  $this.gk_1 = threeRepetitionsMode;
1000
1039
  $this.hk_1 = fiftyMovesRuleMode;
@@ -1008,22 +1047,22 @@ class Game {
1008
1047
  tmp0.f5('id', value);
1009
1048
  return $this;
1010
1049
  }
1011
- tl(node) {
1012
- var count = this.ik_1.dm(node);
1050
+ ul(node) {
1051
+ var count = this.ik_1.em(node);
1013
1052
  if (this.dk_1.equals(GameMode_MATCH_getInstance()) && count === 5) {
1014
- this.hm(true);
1015
- this.om('five repetitions');
1016
- this.mm(Result_DRAW_getInstance());
1053
+ this.im(true);
1054
+ this.pm('five repetitions');
1055
+ this.nm(Result_DRAW_getInstance());
1017
1056
  }
1018
1057
  if (count === 3) {
1019
1058
  switch (this.gk_1.m2_1) {
1020
1059
  case 2:
1021
- this.gm(true);
1060
+ this.hm(true);
1022
1061
  break;
1023
1062
  case 1:
1024
- this.gm(true);
1025
- this.om('three repetitions');
1026
- this.mm(Result_DRAW_getInstance());
1063
+ this.hm(true);
1064
+ this.pm('three repetitions');
1065
+ this.nm(Result_DRAW_getInstance());
1027
1066
  break;
1028
1067
  case 0:
1029
1068
  break;
@@ -1032,15 +1071,15 @@ class Game {
1032
1071
  break;
1033
1072
  }
1034
1073
  } else {
1035
- this.gm(false);
1074
+ this.hm(false);
1036
1075
  }
1037
- if (this.ik_1.em(node)) {
1076
+ if (this.ik_1.fm(node)) {
1038
1077
  switch (this.gk_1.m2_1) {
1039
1078
  case 2:
1040
- this.im(true);
1079
+ this.jm(true);
1041
1080
  break;
1042
1081
  case 1:
1043
- this.im(true);
1082
+ this.jm(true);
1044
1083
  break;
1045
1084
  case 0:
1046
1085
  break;
@@ -1050,40 +1089,40 @@ class Game {
1050
1089
  }
1051
1090
  }
1052
1091
  }
1053
- vl(node) {
1054
- if (node.uj().rm()) {
1092
+ wl(node) {
1093
+ if (node.uj().sm()) {
1055
1094
  switch (this.hk_1.m2_1) {
1056
1095
  case 0:
1057
1096
  break;
1058
1097
  case 2:
1059
- this.jm(true);
1098
+ this.km(true);
1060
1099
  break;
1061
1100
  case 1:
1062
- this.jm(true);
1063
- this.mm(Result_DRAW_getInstance());
1101
+ this.km(true);
1102
+ this.nm(Result_DRAW_getInstance());
1064
1103
  break;
1065
1104
  default:
1066
1105
  noWhenBranchMatchedException();
1067
1106
  break;
1068
1107
  }
1069
1108
  } else {
1070
- this.jm(false);
1109
+ this.km(false);
1071
1110
  }
1072
1111
  }
1073
- wl(node) {
1112
+ xl(node) {
1074
1113
  if (node.uj().mj_1 === 75) {
1075
- this.km(true);
1076
- this.om('75 moves rule');
1077
- this.mm(Result_DRAW_getInstance());
1114
+ this.lm(true);
1115
+ this.pm('75 moves rule');
1116
+ this.nm(Result_DRAW_getInstance());
1078
1117
  }
1079
1118
  }
1080
- sl() {
1119
+ tl() {
1081
1120
  var iterator = this.x();
1082
1121
  iterator.a1();
1083
1122
  while (iterator.z()) {
1084
1123
  var node = iterator.a1();
1085
1124
  var tmp0_elvis_lhs = ecoInfo(node.uj());
1086
- this.lm(tmp0_elvis_lhs == null ? this.ek_1 : tmp0_elvis_lhs);
1125
+ this.mm(tmp0_elvis_lhs == null ? this.ek_1 : tmp0_elvis_lhs);
1087
1126
  }
1088
1127
  var tmp0 = this.xj_1;
1089
1128
  var tmp1_safe_receiver = this.ek_1;
@@ -1098,7 +1137,7 @@ class Game {
1098
1137
  var value_0 = tmp4_elvis_lhs == null ? 'unknown' : tmp4_elvis_lhs;
1099
1138
  tmp0_0.f5('opening', value_0);
1100
1139
  }
1101
- ul(node) {
1140
+ vl(node) {
1102
1141
  if (get_gameOver(node.uj())) {
1103
1142
  var tmp;
1104
1143
  if (get_draw(node.uj())) {
@@ -1108,7 +1147,7 @@ class Game {
1108
1147
  } else {
1109
1148
  tmp = Result_WHITE_WIN_getInstance();
1110
1149
  }
1111
- this.mm(tmp);
1150
+ this.nm(tmp);
1112
1151
  }
1113
1152
  }
1114
1153
  toString() {
@@ -1122,7 +1161,7 @@ class Game {
1122
1161
  sb.j8(toString(element));
1123
1162
  }
1124
1163
  var tmp0_safe_receiver = this.fk_1;
1125
- var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.am_1;
1164
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.bm_1;
1126
1165
  var tmp_0 = sb.j8(tmp1_elvis_lhs == null ? '' : tmp1_elvis_lhs);
1127
1166
  var tmp2_safe_receiver = this.jk_1;
1128
1167
  var tmp_1;
@@ -1149,72 +1188,72 @@ class Game {
1149
1188
  x() {
1150
1189
  return new NodeIterator(this.wj_1);
1151
1190
  }
1152
- sm(idSupplier) {
1191
+ tm(idSupplier) {
1153
1192
  // Inline function 'kotlin.collections.mutableMapOf' call
1154
1193
  // Inline function 'kotlin.apply' call
1155
1194
  var this_0 = LinkedHashMap.v8();
1156
1195
  this_0.g5(this.xj_1);
1157
1196
  // Inline function 'kotlin.apply' call
1158
- var this_1 = Game.pm(this_0, GameMode_ANALYSIS_getInstance(), ThreeRepetitionsMode_AWARE_getInstance(), FiftyMovesRuleMode_AWARE_getInstance(), this.wj_1.cl(null), idSupplier);
1159
- this_1.nm(this.jk_1);
1160
- this_1.om(this.kk_1);
1161
- this_1.lm(this.ek_1);
1162
- this_1.mm(this.fk_1);
1163
- this_1.gm(this.yj_1);
1164
- this_1.jm(this.bk_1);
1197
+ var this_1 = Game.qm(this_0, GameMode_ANALYSIS_getInstance(), ThreeRepetitionsMode_AWARE_getInstance(), FiftyMovesRuleMode_AWARE_getInstance(), this.wj_1.cl(null), idSupplier);
1198
+ this_1.om(this.jk_1);
1199
+ this_1.pm(this.kk_1);
1200
+ this_1.mm(this.ek_1);
1201
+ this_1.nm(this.fk_1);
1202
+ this_1.hm(this.yj_1);
1203
+ this_1.km(this.bk_1);
1165
1204
  return this_1;
1166
1205
  }
1167
1206
  }
1168
1207
  class KingMoves$allMovesList$delegate$lambda$slambda {
1169
1208
  constructor(this$0) {
1170
- this.tm_1 = this$0;
1209
+ this.um_1 = this$0;
1171
1210
  }
1172
- gn($this$sequence, $completion) {
1211
+ hn($this$sequence, $completion) {
1173
1212
  return suspendOrReturn(/*#__NOINLINE__*/_generator_invoke__zhh2q8.bind(VOID, this, $this$sequence), $completion);
1174
1213
  }
1175
1214
  w9(p1, $completion) {
1176
- return this.gn(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
1215
+ return this.hn(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
1177
1216
  }
1178
1217
  }
1179
1218
  class KingMoves {
1180
1219
  constructor(kingPiece, originSquare, enemies, regularMoves, castleMoves, regularMoveFunction) {
1181
- this.um_1 = kingPiece;
1182
- this.vm_1 = originSquare;
1183
- this.wm_1 = enemies;
1184
- this.xm_1 = regularMoves;
1185
- this.ym_1 = castleMoves;
1186
- this.zm_1 = regularMoveFunction;
1220
+ this.vm_1 = kingPiece;
1221
+ this.wm_1 = originSquare;
1222
+ this.xm_1 = enemies;
1223
+ this.ym_1 = regularMoves;
1224
+ this.zm_1 = castleMoves;
1225
+ this.an_1 = regularMoveFunction;
1187
1226
  var tmp = this;
1188
- tmp.an_1 = lazy(KingMoves$regularMovesList$delegate$lambda(this));
1227
+ tmp.bn_1 = lazy(KingMoves$regularMovesList$delegate$lambda(this));
1189
1228
  var tmp_0 = this;
1190
- tmp_0.bn_1 = lazy(KingMoves$castleMovesList$delegate$lambda(this));
1191
- this.cn_1 = this.xm_1 | this.ym_1;
1229
+ tmp_0.cn_1 = lazy(KingMoves$castleMovesList$delegate$lambda(this));
1230
+ this.dn_1 = this.ym_1 | this.zm_1;
1192
1231
  var tmp_1 = this;
1193
- tmp_1.dn_1 = lazy(KingMoves$allMovesList$delegate$lambda(this));
1232
+ tmp_1.en_1 = lazy(KingMoves$allMovesList$delegate$lambda(this));
1194
1233
  }
1195
- en() {
1196
- var tmp0 = this.an_1;
1234
+ fn() {
1235
+ var tmp0 = this.bn_1;
1197
1236
  var tmp = KProperty1;
1198
1237
  // Inline function 'kotlin.getValue' call
1199
1238
  getPropertyCallableRef('regularMovesList', 1, tmp, KingMoves$_get_regularMovesList_$ref_1r6ljl(), null);
1200
1239
  return tmp0.h2();
1201
1240
  }
1202
- fn() {
1203
- var tmp0 = this.bn_1;
1241
+ gn() {
1242
+ var tmp0 = this.cn_1;
1204
1243
  var tmp = KProperty1;
1205
1244
  // Inline function 'kotlin.getValue' call
1206
1245
  getPropertyCallableRef('castleMovesList', 1, tmp, KingMoves$_get_castleMovesList_$ref_3suu4f(), null);
1207
1246
  return tmp0.h2();
1208
1247
  }
1209
- hn() {
1210
- var tmp0 = this.dn_1;
1248
+ in() {
1249
+ var tmp0 = this.en_1;
1211
1250
  var tmp = KProperty1;
1212
1251
  // Inline function 'kotlin.getValue' call
1213
1252
  getPropertyCallableRef('allMovesList', 1, tmp, KingMoves$_get_allMovesList_$ref_go3t84(), null);
1214
1253
  return tmp0.h2();
1215
1254
  }
1216
1255
  toString() {
1217
- return 'KingMoves(piece=' + get_entries_0().c1(this.um_1).toString() + ', origin=' + get_entries_2().c1(this.vm_1).toString() + ', enemies=' + toString(toSquares(_Bitboard___init__impl__wiz5h4(this.wm_1))) + ', moves=' + toString(this.hn()) + ')';
1256
+ return 'KingMoves(piece=' + get_entries_0().c1(this.vm_1).toString() + ', origin=' + get_entries_2().c1(this.wm_1).toString() + ', enemies=' + toString(toSquares(_Bitboard___init__impl__wiz5h4(this.xm_1))) + ', moves=' + toString(this.in()) + ')';
1218
1257
  }
1219
1258
  }
1220
1259
  class Level extends Enum {}
@@ -1223,7 +1262,7 @@ class Logger {
1223
1262
  this.ii_1 = name;
1224
1263
  this.ji_1 = filterLevel;
1225
1264
  }
1226
- in(message) {
1265
+ jn(message) {
1227
1266
  var tmp0_level = Level_DEBUG_getInstance();
1228
1267
  log(this, tmp0_level, message);
1229
1268
  }
@@ -1231,50 +1270,50 @@ class Logger {
1231
1270
  var tmp0_level = Level_INFO_getInstance();
1232
1271
  log(this, tmp0_level, message);
1233
1272
  }
1234
- nl(message) {
1273
+ ol(message) {
1235
1274
  var tmp0_level = Level_WARN_getInstance();
1236
1275
  log(this, tmp0_level, message);
1237
1276
  }
1238
- jn(message) {
1277
+ kn(message) {
1239
1278
  var tmp0_level = Level_ERROR_getInstance();
1240
1279
  log(this, tmp0_level, message);
1241
1280
  }
1242
- xl(err) {
1281
+ yl(err) {
1243
1282
  var tmp0_elvis_lhs = err.message;
1244
- this.jn(tmp0_elvis_lhs == null ? 'none' : tmp0_elvis_lhs);
1283
+ this.kn(tmp0_elvis_lhs == null ? 'none' : tmp0_elvis_lhs);
1245
1284
  return err;
1246
1285
  }
1247
- kn(message) {
1286
+ ln(message) {
1248
1287
  var tmp0_level = Level_FATAL_getInstance();
1249
1288
  log(this, tmp0_level, message);
1250
1289
  }
1251
- ln(err) {
1290
+ mn(err) {
1252
1291
  var tmp0_elvis_lhs = err.message;
1253
- this.kn(tmp0_elvis_lhs == null ? 'none' : tmp0_elvis_lhs);
1292
+ this.ln(tmp0_elvis_lhs == null ? 'none' : tmp0_elvis_lhs);
1254
1293
  return err;
1255
1294
  }
1256
- mn(t1, t2) {
1295
+ nn(t1, t2) {
1257
1296
  var ms = subtract(t2.wg(), t1.wg());
1258
- this.in(this.ii_1 + ' created in ' + ms.toString() + ' ms');
1297
+ this.jn(this.ii_1 + ' created in ' + ms.toString() + ' ms');
1259
1298
  }
1260
1299
  }
1261
1300
  class Companion_2 {
1262
1301
  constructor() {
1263
1302
  Companion_instance_2 = this;
1264
- this.nn_1 = getLogger('io.github.lunalobos.chess4kt.Move');
1303
+ this.on_1 = getLogger('io.github.lunalobos.chess4kt.Move');
1265
1304
  }
1266
1305
  }
1267
1306
  class Move {
1268
- static sn(move, origin, promotionPiece) {
1307
+ static tn(move, origin, promotionPiece) {
1269
1308
  Companion_getInstance_2();
1270
1309
  promotionPiece = promotionPiece === VOID ? -1 : promotionPiece;
1271
1310
  var $this = createThis(this);
1272
1311
  init_io_github_lunalobos_chess4kt_Move($this);
1273
1312
  if (move === 0n) {
1274
- throw Companion_getInstance_2().nn_1.ln(RuntimeException.l7('Move mask cannot be zero.'));
1313
+ throw Companion_getInstance_2().on_1.mn(RuntimeException.l7('Move mask cannot be zero.'));
1275
1314
  }
1276
1315
  if (!(0 <= origin ? origin <= 63 : false)) {
1277
- throw Companion_getInstance_2().nn_1.ln(RuntimeException.l7('Origin square index must be between 0 and 63 (inclusive), but was ' + origin + '.'));
1316
+ throw Companion_getInstance_2().on_1.mn(RuntimeException.l7('Origin square index must be between 0 and 63 (inclusive), but was ' + origin + '.'));
1278
1317
  }
1279
1318
  var tmp;
1280
1319
  if (!(promotionPiece === -1)) {
@@ -1293,31 +1332,31 @@ class Move {
1293
1332
  tmp = false;
1294
1333
  }
1295
1334
  if (tmp) {
1296
- throw Companion_getInstance_2().nn_1.ln(RuntimeException.l7('Promotion piece ordinal must be -1 or a valid promotable piece ordinal, but was ' + promotionPiece + '.'));
1335
+ throw Companion_getInstance_2().on_1.mn(RuntimeException.l7('Promotion piece ordinal must be -1 or a valid promotable piece ordinal, but was ' + promotionPiece + '.'));
1297
1336
  }
1298
- $this.on_1 = move;
1299
- $this.pn_1 = origin;
1300
- $this.qn_1 = promotionPiece;
1301
- $this.rn_1 = countTrailingZeroBits(move);
1337
+ $this.pn_1 = move;
1338
+ $this.qn_1 = origin;
1339
+ $this.rn_1 = promotionPiece;
1340
+ $this.sn_1 = countTrailingZeroBits(move);
1302
1341
  return $this;
1303
1342
  }
1304
- tn() {
1305
- return Companion_instance_6.c1(this.pn_1);
1306
- }
1307
1343
  un() {
1308
- return Companion_instance_6.c1(this.rn_1);
1344
+ return Companion_instance_6.c1(this.qn_1);
1309
1345
  }
1310
1346
  vn() {
1347
+ return Companion_instance_6.c1(this.sn_1);
1348
+ }
1349
+ wn() {
1311
1350
  var tmp;
1312
- if (this.qn_1 < 0) {
1351
+ if (this.rn_1 < 0) {
1313
1352
  tmp = Piece_EMPTY_getInstance();
1314
1353
  } else {
1315
- tmp = get_entries_0().c1(this.qn_1);
1354
+ tmp = get_entries_0().c1(this.rn_1);
1316
1355
  }
1317
1356
  return tmp;
1318
1357
  }
1319
1358
  hashCode() {
1320
- return this.pn_1 | countTrailingZeroBits(this.on_1) << 6 | (this.qn_1 === -1 ? 0 : this.qn_1 << 12);
1359
+ return this.qn_1 | countTrailingZeroBits(this.pn_1) << 6 | (this.rn_1 === -1 ? 0 : this.rn_1 << 12);
1321
1360
  }
1322
1361
  equals(other) {
1323
1362
  if (other == null)
@@ -1326,32 +1365,32 @@ class Move {
1326
1365
  return true;
1327
1366
  if (!(other instanceof Move))
1328
1367
  return false;
1329
- return this.pn_1 === other.pn_1 && this.on_1 === other.on_1 && this.qn_1 === other.qn_1;
1368
+ return this.qn_1 === other.qn_1 && this.pn_1 === other.pn_1 && this.rn_1 === other.rn_1;
1330
1369
  }
1331
1370
  toString() {
1332
1371
  var sb = StringBuilder.u();
1333
1372
  // Inline function 'kotlin.text.lowercase' call
1334
1373
  // Inline function 'kotlin.js.asDynamic' call
1335
- var tmp$ret$1 = this.tn().l2_1.toLowerCase();
1374
+ var tmp$ret$1 = this.un().l2_1.toLowerCase();
1336
1375
  var tmp = sb.j8(tmp$ret$1);
1337
1376
  // Inline function 'kotlin.text.lowercase' call
1338
1377
  // Inline function 'kotlin.js.asDynamic' call
1339
- var tmp$ret$3 = this.un().l2_1.toLowerCase();
1378
+ var tmp$ret$3 = this.vn().l2_1.toLowerCase();
1340
1379
  tmp.j8(tmp$ret$3);
1341
1380
  var tmp_0;
1342
- if (this.qn_1 === -1) {
1381
+ if (this.rn_1 === -1) {
1343
1382
  tmp_0 = sb.toString();
1344
1383
  } else {
1345
1384
  // Inline function 'kotlin.text.lowercase' call
1346
1385
  // Inline function 'kotlin.js.asDynamic' call
1347
- var tmp$ret$5 = substring(this.vn().l2_1, 1).toLowerCase();
1386
+ var tmp$ret$5 = substring(this.wn().l2_1, 1).toLowerCase();
1348
1387
  tmp_0 = sb.j8(tmp$ret$5).toString();
1349
1388
  }
1350
1389
  return tmp_0;
1351
1390
  }
1352
1391
  }
1353
1392
  class MoveException extends RuntimeException {
1354
- static zn(msg) {
1393
+ static ao(msg) {
1355
1394
  var $this = this.l7(msg);
1356
1395
  init_io_github_lunalobos_chess4kt_MoveException($this);
1357
1396
  return $this;
@@ -1359,228 +1398,228 @@ class MoveException extends RuntimeException {
1359
1398
  }
1360
1399
  class MovesInfo$movesList$delegate$lambda$slambda {
1361
1400
  constructor(this$0) {
1362
- this.io_1 = this$0;
1401
+ this.jo_1 = this$0;
1363
1402
  }
1364
- gn($this$sequence, $completion) {
1403
+ hn($this$sequence, $completion) {
1365
1404
  return suspendOrReturn(/*#__NOINLINE__*/_generator_invoke__zhh2q8_0.bind(VOID, this, $this$sequence), $completion);
1366
1405
  }
1367
1406
  w9(p1, $completion) {
1368
- return this.gn(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
1407
+ return this.hn(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
1369
1408
  }
1370
1409
  }
1371
1410
  class MovesInfo {
1372
1411
  constructor(pawnMoves, knightMoves, bishopMoves, rookMoves, queenMoves, kingMoves) {
1373
- this.ao_1 = pawnMoves;
1374
- this.bo_1 = knightMoves;
1375
- this.co_1 = bishopMoves;
1376
- this.do_1 = rookMoves;
1377
- this.eo_1 = queenMoves;
1378
- this.fo_1 = kingMoves;
1412
+ this.bo_1 = pawnMoves;
1413
+ this.co_1 = knightMoves;
1414
+ this.do_1 = bishopMoves;
1415
+ this.eo_1 = rookMoves;
1416
+ this.fo_1 = queenMoves;
1417
+ this.go_1 = kingMoves;
1379
1418
  var tmp = this;
1380
- tmp.go_1 = lazy(MovesInfo$moves$delegate$lambda(this));
1419
+ tmp.ho_1 = lazy(MovesInfo$moves$delegate$lambda(this));
1381
1420
  var tmp_0 = this;
1382
- tmp_0.ho_1 = lazy(MovesInfo$movesList$delegate$lambda(this));
1421
+ tmp_0.io_1 = lazy(MovesInfo$movesList$delegate$lambda(this));
1383
1422
  }
1384
- ep() {
1385
- var tmp0 = this.go_1;
1423
+ fp() {
1424
+ var tmp0 = this.ho_1;
1386
1425
  var tmp = KProperty1;
1387
1426
  // Inline function 'kotlin.getValue' call
1388
1427
  getPropertyCallableRef('moves', 1, tmp, MovesInfo$_get_moves_$ref_54hm5y(), null);
1389
1428
  return tmp0.h2();
1390
1429
  }
1391
- fp() {
1392
- var tmp0 = this.ho_1;
1430
+ gp() {
1431
+ var tmp0 = this.io_1;
1393
1432
  var tmp = KProperty1;
1394
1433
  // Inline function 'kotlin.getValue' call
1395
1434
  getPropertyCallableRef('movesList', 1, tmp, MovesInfo$_get_movesList_$ref_o79khg(), null);
1396
1435
  return tmp0.h2();
1397
1436
  }
1398
1437
  toString() {
1399
- return 'MovesInfo(moves = ' + toString(this.fp()) + ')';
1438
+ return 'MovesInfo(moves = ' + toString(this.gp()) + ')';
1400
1439
  }
1401
1440
  }
1402
1441
  class Notation extends Enum {}
1403
1442
  class Companion_3 {
1404
1443
  constructor() {
1405
1444
  Companion_instance_3 = this;
1406
- this.gp_1 = getLogger('io.github.lunalobos.chess4kt.Parser');
1445
+ this.hp_1 = getLogger('io.github.lunalobos.chess4kt.Parser');
1407
1446
  }
1408
1447
  }
1409
1448
  class ParserException extends RuntimeException {
1410
- static kp(msg) {
1449
+ static lp(msg) {
1411
1450
  var $this = this.l7(msg);
1412
- captureStack($this, $this.jp_1);
1451
+ captureStack($this, $this.kp_1);
1413
1452
  return $this;
1414
1453
  }
1415
1454
  }
1416
1455
  class Parser {
1417
1456
  constructor(tokens) {
1418
1457
  Companion_getInstance_3();
1419
- this.op_1 = tokens;
1458
+ this.pp_1 = tokens;
1420
1459
  var tmp = this;
1421
1460
  // Inline function 'kotlin.collections.mutableMapOf' call
1422
- tmp.qp_1 = LinkedHashMap.v8();
1423
- this.rp_1 = null;
1424
- this.sp_1 = this.op_1.x();
1461
+ tmp.rp_1 = LinkedHashMap.v8();
1462
+ this.sp_1 = null;
1463
+ this.tp_1 = this.pp_1.x();
1425
1464
  var tmp_0 = this;
1426
1465
  // Inline function 'kotlin.collections.mutableListOf' call
1427
- tmp_0.tp_1 = ArrayList.h1();
1466
+ tmp_0.up_1 = ArrayList.h1();
1428
1467
  var tmp_1 = this;
1429
1468
  var tmp_2;
1430
- if (this.sp_1.z()) {
1431
- tmp_2 = this.sp_1.a1();
1469
+ if (this.tp_1.z()) {
1470
+ tmp_2 = this.tp_1.a1();
1432
1471
  } else {
1433
- throw ParserException.kp('no tokens to parse');
1472
+ throw ParserException.lp('no tokens to parse');
1434
1473
  }
1435
- tmp_1.pp_1 = tmp_2;
1474
+ tmp_1.qp_1 = tmp_2;
1436
1475
  }
1437
- up(idSupplier) {
1476
+ vp(idSupplier) {
1438
1477
  do {
1439
1478
  parseGame(this, idSupplier);
1440
- this.pp_1 = nextTokenOrFail(this, 'error in main function ');
1479
+ this.qp_1 = nextTokenOrFail(this, 'error in main function ');
1441
1480
  }
1442
- while (!this.pp_1.lp_1.equals(TokenType_EOF_getInstance()));
1443
- return this.tp_1;
1481
+ while (!this.qp_1.mp_1.equals(TokenType_EOF_getInstance()));
1482
+ return this.up_1;
1444
1483
  }
1445
1484
  }
1446
1485
  class PawnMoves$allMovesList$delegate$lambda$slambda {
1447
1486
  constructor(this$0) {
1448
- this.vp_1 = this$0;
1487
+ this.wp_1 = this$0;
1449
1488
  }
1450
- gn($this$sequence, $completion) {
1489
+ hn($this$sequence, $completion) {
1451
1490
  return suspendOrReturn(/*#__NOINLINE__*/_generator_invoke__zhh2q8_1.bind(VOID, this, $this$sequence), $completion);
1452
1491
  }
1453
1492
  w9(p1, $completion) {
1454
- return this.gn(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
1493
+ return this.hn(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
1455
1494
  }
1456
1495
  }
1457
1496
  class PawnMoves {
1458
1497
  constructor(pawnPiece, originSquare, enemies, regularMoves, advanceEpMoves, promotionMoves, epCapture, regularMoveFunction, promotionMoveFunction) {
1459
- this.jo_1 = pawnPiece;
1460
- this.ko_1 = originSquare;
1461
- this.lo_1 = enemies;
1462
- this.mo_1 = regularMoves;
1463
- this.no_1 = advanceEpMoves;
1464
- this.oo_1 = promotionMoves;
1465
- this.po_1 = epCapture;
1466
- this.qo_1 = regularMoveFunction;
1467
- this.ro_1 = promotionMoveFunction;
1498
+ this.ko_1 = pawnPiece;
1499
+ this.lo_1 = originSquare;
1500
+ this.mo_1 = enemies;
1501
+ this.no_1 = regularMoves;
1502
+ this.oo_1 = advanceEpMoves;
1503
+ this.po_1 = promotionMoves;
1504
+ this.qo_1 = epCapture;
1505
+ this.ro_1 = regularMoveFunction;
1506
+ this.so_1 = promotionMoveFunction;
1468
1507
  var tmp = this;
1469
- tmp.so_1 = lazy(PawnMoves$regularMovesList$delegate$lambda(this));
1508
+ tmp.to_1 = lazy(PawnMoves$regularMovesList$delegate$lambda(this));
1470
1509
  var tmp_0 = this;
1471
- tmp_0.to_1 = lazy(PawnMoves$advanceEpMovesList$delegate$lambda(this));
1510
+ tmp_0.uo_1 = lazy(PawnMoves$advanceEpMovesList$delegate$lambda(this));
1472
1511
  var tmp_1 = this;
1473
- tmp_1.uo_1 = lazy(PawnMoves$promotionMovesList$delegate$lambda(this));
1512
+ tmp_1.vo_1 = lazy(PawnMoves$promotionMovesList$delegate$lambda(this));
1474
1513
  var tmp_2 = this;
1475
- tmp_2.vo_1 = lazy(PawnMoves$epCaptureMove$delegate$lambda(this));
1476
- this.wo_1 = this.mo_1 | this.no_1 | this.oo_1 | this.po_1;
1514
+ tmp_2.wo_1 = lazy(PawnMoves$epCaptureMove$delegate$lambda(this));
1515
+ this.xo_1 = this.no_1 | this.oo_1 | this.po_1 | this.qo_1;
1477
1516
  var tmp_3 = this;
1478
- tmp_3.xo_1 = lazy(PawnMoves$allMovesList$delegate$lambda(this));
1517
+ tmp_3.yo_1 = lazy(PawnMoves$allMovesList$delegate$lambda(this));
1479
1518
  }
1480
- en() {
1481
- var tmp0 = this.so_1;
1519
+ fn() {
1520
+ var tmp0 = this.to_1;
1482
1521
  var tmp = KProperty1;
1483
1522
  // Inline function 'kotlin.getValue' call
1484
1523
  getPropertyCallableRef('regularMovesList', 1, tmp, PawnMoves$_get_regularMovesList_$ref_qve2sg(), null);
1485
1524
  return tmp0.h2();
1486
1525
  }
1487
- wp() {
1488
- var tmp0 = this.to_1;
1526
+ xp() {
1527
+ var tmp0 = this.uo_1;
1489
1528
  var tmp = KProperty1;
1490
1529
  // Inline function 'kotlin.getValue' call
1491
1530
  getPropertyCallableRef('advanceEpMovesList', 1, tmp, PawnMoves$_get_advanceEpMovesList_$ref_k5ega7(), null);
1492
1531
  return tmp0.h2();
1493
1532
  }
1494
- xp() {
1495
- var tmp0 = this.uo_1;
1533
+ yp() {
1534
+ var tmp0 = this.vo_1;
1496
1535
  var tmp = KProperty1;
1497
1536
  // Inline function 'kotlin.getValue' call
1498
1537
  getPropertyCallableRef('promotionMovesList', 1, tmp, PawnMoves$_get_promotionMovesList_$ref_pb8487(), null);
1499
1538
  return tmp0.h2();
1500
1539
  }
1501
- yp() {
1502
- var tmp0 = this.vo_1;
1540
+ zp() {
1541
+ var tmp0 = this.wo_1;
1503
1542
  var tmp = KProperty1;
1504
1543
  // Inline function 'kotlin.getValue' call
1505
1544
  getPropertyCallableRef('epCaptureMove', 1, tmp, PawnMoves$_get_epCaptureMove_$ref_4vz7gq(), null);
1506
1545
  return tmp0.h2();
1507
1546
  }
1508
- hn() {
1509
- var tmp0 = this.xo_1;
1547
+ in() {
1548
+ var tmp0 = this.yo_1;
1510
1549
  var tmp = KProperty1;
1511
1550
  // Inline function 'kotlin.getValue' call
1512
1551
  getPropertyCallableRef('allMovesList', 1, tmp, PawnMoves$_get_allMovesList_$ref_s0vg9x(), null);
1513
1552
  return tmp0.h2();
1514
1553
  }
1515
1554
  toString() {
1516
- return 'PawnMoves(piece=' + get_entries_0().c1(this.jo_1).toString() + ', origin=' + get_entries_2().c1(this.ko_1).toString() + ', enemies=' + toString(toSquares(_Bitboard___init__impl__wiz5h4(this.lo_1))) + ', moves=' + toString(this.hn()) + ')';
1555
+ return 'PawnMoves(piece=' + get_entries_0().c1(this.ko_1).toString() + ', origin=' + get_entries_2().c1(this.lo_1).toString() + ', enemies=' + toString(toSquares(_Bitboard___init__impl__wiz5h4(this.mo_1))) + ', moves=' + toString(this.in()) + ')';
1517
1556
  }
1518
1557
  }
1519
1558
  class Companion_4 {}
1520
1559
  class Piece extends Enum {
1521
1560
  constructor(name, ordinal, side) {
1522
1561
  super(name, ordinal);
1523
- this.bq_1 = side;
1562
+ this.cq_1 = side;
1524
1563
  }
1525
1564
  }
1526
1565
  class Companion_5 {
1527
1566
  constructor() {
1528
1567
  Companion_instance_5 = this;
1529
- this.cq_1 = listOf([new Char(_Char___init__impl__6a9atx(49)), new Char(_Char___init__impl__6a9atx(50)), new Char(_Char___init__impl__6a9atx(51)), new Char(_Char___init__impl__6a9atx(52)), new Char(_Char___init__impl__6a9atx(53)), new Char(_Char___init__impl__6a9atx(54)), new Char(_Char___init__impl__6a9atx(55)), new Char(_Char___init__impl__6a9atx(56))]);
1568
+ this.dq_1 = listOf([new Char(_Char___init__impl__6a9atx(49)), new Char(_Char___init__impl__6a9atx(50)), new Char(_Char___init__impl__6a9atx(51)), new Char(_Char___init__impl__6a9atx(52)), new Char(_Char___init__impl__6a9atx(53)), new Char(_Char___init__impl__6a9atx(54)), new Char(_Char___init__impl__6a9atx(55)), new Char(_Char___init__impl__6a9atx(56))]);
1530
1569
  }
1531
1570
  }
1532
1571
  class Position {
1533
- eq() {
1572
+ fq() {
1534
1573
  return copyOf(this.ej_1);
1535
1574
  }
1536
- dq() {
1537
- return get_movesInfo()(this.eq(), this.fj_1, this.hj_1, this.ij_1, this.jj_1, this.kj_1, this.gj_1);
1575
+ eq() {
1576
+ return get_movesInfo()(this.fq(), this.fj_1, this.hj_1, this.ij_1, this.jj_1, this.kj_1, this.gj_1);
1538
1577
  }
1539
- fq() {
1578
+ gq() {
1540
1579
  var tmp0 = this.oj_1;
1541
1580
  var tmp = KProperty1;
1542
1581
  // Inline function 'kotlin.getValue' call
1543
1582
  getPropertyCallableRef('check', 1, tmp, Position$_get_check_$ref_tp97h(), null);
1544
1583
  return tmp0.h2();
1545
1584
  }
1546
- gq() {
1585
+ hq() {
1547
1586
  var tmp0 = this.pj_1;
1548
1587
  var tmp = KProperty1;
1549
1588
  // Inline function 'kotlin.getValue' call
1550
1589
  getPropertyCallableRef('checkmate', 1, tmp, Position$_get_checkmate_$ref_mwt4hk(), null);
1551
1590
  return tmp0.h2();
1552
1591
  }
1553
- hq() {
1592
+ iq() {
1554
1593
  var tmp0 = this.qj_1;
1555
1594
  var tmp = KProperty1;
1556
1595
  // Inline function 'kotlin.getValue' call
1557
1596
  getPropertyCallableRef('stalemate', 1, tmp, Position$_get_stalemate_$ref_l6lqf(), null);
1558
1597
  return tmp0.h2();
1559
1598
  }
1560
- iq() {
1599
+ jq() {
1561
1600
  var tmp0 = this.rj_1;
1562
1601
  var tmp = KProperty1;
1563
1602
  // Inline function 'kotlin.getValue' call
1564
1603
  getPropertyCallableRef('lackOfMaterial', 1, tmp, Position$_get_lackOfMaterial_$ref_whrjuu(), null);
1565
1604
  return tmp0.h2();
1566
1605
  }
1567
- rm() {
1606
+ sm() {
1568
1607
  var tmp0 = this.sj_1;
1569
1608
  var tmp = KProperty1;
1570
1609
  // Inline function 'kotlin.getValue' call
1571
1610
  getPropertyCallableRef('fiftyMoves', 1, tmp, Position$_get_fiftyMoves_$ref_ima66z(), null);
1572
1611
  return tmp0.h2();
1573
1612
  }
1574
- jq() {
1613
+ kq() {
1575
1614
  var tmp0 = this.tj_1;
1576
1615
  var tmp = KProperty1;
1577
1616
  // Inline function 'kotlin.getValue' call
1578
1617
  getPropertyCallableRef('zobrist', 1, tmp, Position$_get_zobrist_$ref_t8al0g(), null);
1579
1618
  return tmp0.h2();
1580
1619
  }
1581
- kq() {
1620
+ lq() {
1582
1621
  var sqs = new Int32Array(64);
1583
- var b = this.eq();
1622
+ var b = this.fq();
1584
1623
  var inductionVariable = 0;
1585
1624
  if (inductionVariable <= 63)
1586
1625
  do {
@@ -1600,10 +1639,10 @@ class Position {
1600
1639
  while (inductionVariable <= 63);
1601
1640
  return sqs;
1602
1641
  }
1603
- lq() {
1604
- return toFen(this.kq(), this.fj_1, this.hj_1, this.ij_1, this.jj_1, this.kj_1, this.gj_1, this.mj_1, this.lj_1);
1642
+ mq() {
1643
+ return toFen(this.lq(), this.fj_1, this.hj_1, this.ij_1, this.jj_1, this.kj_1, this.gj_1, this.mj_1, this.lj_1);
1605
1644
  }
1606
- static mq() {
1645
+ static nq() {
1607
1646
  Companion_getInstance_5();
1608
1647
  var $this = createThis(this);
1609
1648
  init_io_github_lunalobos_chess4kt_Position($this);
@@ -1681,7 +1720,7 @@ class Position {
1681
1720
  $this.mj_1 = 0;
1682
1721
  return $this;
1683
1722
  }
1684
- static nq(bitboards, whiteMove, enPassant, whiteCastleKingside, whiteCastleQueenside, blackCastleKingside, blackCastleQueenside, mc, hm) {
1723
+ static oq(bitboards, whiteMove, enPassant, whiteCastleKingside, whiteCastleQueenside, blackCastleKingside, blackCastleQueenside, mc, hm) {
1685
1724
  Companion_getInstance_5();
1686
1725
  var $this = createThis(this);
1687
1726
  init_io_github_lunalobos_chess4kt_Position($this);
@@ -1696,7 +1735,7 @@ class Position {
1696
1735
  $this.mj_1 = hm;
1697
1736
  return $this;
1698
1737
  }
1699
- static oq(fen) {
1738
+ static pq(fen) {
1700
1739
  Companion_getInstance_5();
1701
1740
  var $this = createThis(this);
1702
1741
  init_io_github_lunalobos_chess4kt_Position($this);
@@ -1715,7 +1754,7 @@ class Position {
1715
1754
  while (inductionVariable_0 < last) {
1716
1755
  var character = chars[inductionVariable_0];
1717
1756
  inductionVariable_0 = inductionVariable_0 + 1 | 0;
1718
- if (Companion_getInstance_5().cq_1.d2(new Char(character))) {
1757
+ if (Companion_getInstance_5().dq_1.d2(new Char(character))) {
1719
1758
  i = i + toInt(toString_1(character)) | 0;
1720
1759
  } else {
1721
1760
  if (character === _Char___init__impl__6a9atx(80)) {
@@ -1816,10 +1855,10 @@ class Position {
1816
1855
  return $this;
1817
1856
  }
1818
1857
  hashCode() {
1819
- return getBigIntHashCode(this.jq());
1858
+ return getBigIntHashCode(this.kq());
1820
1859
  }
1821
1860
  toString() {
1822
- return stringRepresentation(this.kq(), this.lq());
1861
+ return stringRepresentation(this.lq(), this.mq());
1823
1862
  }
1824
1863
  equals(other) {
1825
1864
  var tmp;
@@ -1832,7 +1871,7 @@ class Position {
1832
1871
  if (!(other instanceof Position)) {
1833
1872
  tmp = false;
1834
1873
  } else {
1835
- tmp = (contentEquals(this.eq(), other.eq()) && this.fj_1 === other.fj_1 && this.gj_1 === other.gj_1 && this.hj_1 === other.hj_1 && this.ij_1 === other.ij_1 && this.jj_1 === other.jj_1 && this.kj_1 === other.kj_1);
1874
+ tmp = (contentEquals(this.fq(), other.fq()) && this.fj_1 === other.fj_1 && this.gj_1 === other.gj_1 && this.hj_1 === other.hj_1 && this.ij_1 === other.ij_1 && this.jj_1 === other.jj_1 && this.kj_1 === other.kj_1);
1836
1875
  }
1837
1876
  }
1838
1877
  }
@@ -1841,23 +1880,23 @@ class Position {
1841
1880
  }
1842
1881
  class RegularPieceMoves {
1843
1882
  constructor(piece, square, enemies, moves, moveFunction) {
1844
- this.yo_1 = piece;
1845
- this.zo_1 = square;
1846
- this.ap_1 = enemies;
1847
- this.bp_1 = moves;
1848
- this.cp_1 = moveFunction;
1883
+ this.zo_1 = piece;
1884
+ this.ap_1 = square;
1885
+ this.bp_1 = enemies;
1886
+ this.cp_1 = moves;
1887
+ this.dp_1 = moveFunction;
1849
1888
  var tmp = this;
1850
- tmp.dp_1 = lazy(RegularPieceMoves$allMovesList$delegate$lambda(this));
1889
+ tmp.ep_1 = lazy(RegularPieceMoves$allMovesList$delegate$lambda(this));
1851
1890
  }
1852
- hn() {
1853
- var tmp0 = this.dp_1;
1891
+ in() {
1892
+ var tmp0 = this.ep_1;
1854
1893
  var tmp = KProperty1;
1855
1894
  // Inline function 'kotlin.getValue' call
1856
1895
  getPropertyCallableRef('allMovesList', 1, tmp, RegularPieceMoves$_get_allMovesList_$ref_ts1d8v(), null);
1857
1896
  return tmp0.h2();
1858
1897
  }
1859
1898
  toString() {
1860
- return 'RegularPieceMoves(piece=' + get_entries_0().c1(this.yo_1).toString() + ', origin=' + get_entries_2().c1(this.zo_1).toString() + ', enemies=' + toString(toSquares(_Bitboard___init__impl__wiz5h4(this.ap_1))) + ', moves=' + toString(this.hn()) + ')';
1899
+ return 'RegularPieceMoves(piece=' + get_entries_0().c1(this.zo_1).toString() + ', origin=' + get_entries_2().c1(this.ap_1).toString() + ', enemies=' + toString(toSquares(_Bitboard___init__impl__wiz5h4(this.bp_1))) + ', moves=' + toString(this.in()) + ')';
1861
1900
  }
1862
1901
  }
1863
1902
  class Side extends Enum {}
@@ -1870,17 +1909,17 @@ class Square extends Enum {}
1870
1909
  class Token {
1871
1910
  constructor(type, value, line) {
1872
1911
  line = line === VOID ? 0 : line;
1873
- this.lp_1 = type;
1874
- this.mp_1 = value;
1875
- this.np_1 = line;
1912
+ this.mp_1 = type;
1913
+ this.np_1 = value;
1914
+ this.op_1 = line;
1876
1915
  }
1877
1916
  toString() {
1878
- return 'Token(type=' + this.lp_1.toString() + ', value=' + this.mp_1 + ', line=' + this.np_1 + ')';
1917
+ return 'Token(type=' + this.mp_1.toString() + ', value=' + this.np_1 + ', line=' + this.op_1 + ')';
1879
1918
  }
1880
1919
  hashCode() {
1881
- var result = this.lp_1.hashCode();
1882
- result = imul(result, 31) + getStringHashCode(this.mp_1) | 0;
1883
- result = imul(result, 31) + this.np_1 | 0;
1920
+ var result = this.mp_1.hashCode();
1921
+ result = imul(result, 31) + getStringHashCode(this.np_1) | 0;
1922
+ result = imul(result, 31) + this.op_1 | 0;
1884
1923
  return result;
1885
1924
  }
1886
1925
  equals(other) {
@@ -1888,28 +1927,28 @@ class Token {
1888
1927
  return true;
1889
1928
  if (!(other instanceof Token))
1890
1929
  return false;
1891
- if (!this.lp_1.equals(other.lp_1))
1892
- return false;
1893
- if (!(this.mp_1 === other.mp_1))
1930
+ if (!this.mp_1.equals(other.mp_1))
1894
1931
  return false;
1895
1932
  if (!(this.np_1 === other.np_1))
1896
1933
  return false;
1934
+ if (!(this.op_1 === other.op_1))
1935
+ return false;
1897
1936
  return true;
1898
1937
  }
1899
1938
  }
1900
1939
  class TokenType extends Enum {}
1901
1940
  class Tokenizer {
1902
1941
  constructor(pgnInput) {
1903
- this.pq_1 = pgnInput;
1904
- this.qq_1 = 0;
1905
- this.rq_1 = 1;
1942
+ this.qq_1 = pgnInput;
1943
+ this.rq_1 = 0;
1944
+ this.sq_1 = 1;
1906
1945
  var tmp = this;
1907
1946
  // Inline function 'kotlin.collections.mutableListOf' call
1908
- tmp.sq_1 = ArrayList.h1();
1947
+ tmp.tq_1 = ArrayList.h1();
1909
1948
  }
1910
- tq() {
1911
- while (this.qq_1 < this.pq_1.length) {
1912
- var char = charCodeAt(this.pq_1, this.qq_1);
1949
+ uq() {
1950
+ while (this.rq_1 < this.qq_1.length) {
1951
+ var char = charCodeAt(this.qq_1, this.rq_1);
1913
1952
  if (isWhitespace(char)) {
1914
1953
  consumeWhitespace(this);
1915
1954
  } else if (char === _Char___init__impl__6a9atx(91)) {
@@ -1937,15 +1976,15 @@ class Tokenizer {
1937
1976
  } else if (isLetter(char) || char === _Char___init__impl__6a9atx(95) || char === _Char___init__impl__6a9atx(43) || char === _Char___init__impl__6a9atx(35) || char === _Char___init__impl__6a9atx(61) || char === _Char___init__impl__6a9atx(58) || char === _Char___init__impl__6a9atx(45)) {
1938
1977
  consumeSymbol(this);
1939
1978
  } else {
1940
- this.qq_1 = this.qq_1 + 1 | 0;
1979
+ this.rq_1 = this.rq_1 + 1 | 0;
1941
1980
  }
1942
1981
  }
1943
- this.sq_1.k(new Token(TokenType_EOF_getInstance(), '', this.rq_1));
1944
- return this.sq_1;
1982
+ this.tq_1.k(new Token(TokenType_EOF_getInstance(), '', this.sq_1));
1983
+ return this.tq_1;
1945
1984
  }
1946
1985
  }
1947
1986
  class Tuple {
1948
- static uq(v1, v2) {
1987
+ static vq(v1, v2) {
1949
1988
  var $this = createThis(this);
1950
1989
  init_io_github_lunalobos_chess4kt_Tuple($this);
1951
1990
  $this.pk_1 = v1;
@@ -1985,14 +2024,14 @@ class Tuple {
1985
2024
  }
1986
2025
  class bitboardToSequence$slambda {
1987
2026
  constructor($bitboard, $entitiesFactory) {
1988
- this.vq_1 = $bitboard;
1989
- this.wq_1 = $entitiesFactory;
2027
+ this.wq_1 = $bitboard;
2028
+ this.xq_1 = $entitiesFactory;
1990
2029
  }
1991
- xq($this$sequence, $completion) {
2030
+ yq($this$sequence, $completion) {
1992
2031
  return suspendOrReturn(/*#__NOINLINE__*/_generator_invoke__zhh2q8_2.bind(VOID, this, $this$sequence), $completion);
1993
2032
  }
1994
2033
  w9(p1, $completion) {
1995
- return this.xq(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
2034
+ return this.yq(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
1996
2035
  }
1997
2036
  }
1998
2037
  class Companion_7 {
@@ -2013,11 +2052,11 @@ class Companion_7 {
2013
2052
  }
2014
2053
  class Bitboard {
2015
2054
  constructor(value) {
2016
- this.yq_1 = value;
2055
+ this.zq_1 = value;
2017
2056
  }
2018
2057
  toString() {
2019
2058
  var sb = StringBuilder.n8(500);
2020
- var inverted = reverse(Companion_instance_7, this.yq_1);
2059
+ var inverted = reverse(Companion_instance_7, this.zq_1);
2021
2060
  var mask = 255n;
2022
2061
  sb.j8('\n+---+---+---+---+---+---+---+---+ \n');
2023
2062
  var inductionVariable = 0;
@@ -2047,73 +2086,73 @@ class Bitboard {
2047
2086
  return sb.toString();
2048
2087
  }
2049
2088
  peekLastBit() {
2050
- return new Bitboard(takeLowestOneBit(this.yq_1));
2089
+ return new Bitboard(takeLowestOneBit(this.zq_1));
2051
2090
  }
2052
2091
  peekFirstBit() {
2053
- return new Bitboard(takeHighestOneBit(this.yq_1));
2092
+ return new Bitboard(takeHighestOneBit(this.zq_1));
2054
2093
  }
2055
2094
  trailingZeros() {
2056
- return countTrailingZeroBits(this.yq_1);
2095
+ return countTrailingZeroBits(this.zq_1);
2057
2096
  }
2058
2097
  leadingZeros() {
2059
- return countLeadingZeroBits(this.yq_1);
2098
+ return countLeadingZeroBits(this.zq_1);
2060
2099
  }
2061
2100
  and(other) {
2062
- return new Bitboard(this.yq_1 & other.yq_1);
2101
+ return new Bitboard(this.zq_1 & other.zq_1);
2063
2102
  }
2064
2103
  or(other) {
2065
- return new Bitboard(this.yq_1 | other.yq_1);
2104
+ return new Bitboard(this.zq_1 | other.zq_1);
2066
2105
  }
2067
2106
  xor(other) {
2068
- return new Bitboard(this.yq_1 ^ other.yq_1);
2107
+ return new Bitboard(this.zq_1 ^ other.zq_1);
2069
2108
  }
2070
2109
  inv() {
2071
- return new Bitboard(~this.yq_1);
2110
+ return new Bitboard(~this.zq_1);
2072
2111
  }
2073
2112
  shl(i) {
2074
- return new Bitboard(shiftLeft(this.yq_1, i));
2113
+ return new Bitboard(shiftLeft(this.zq_1, i));
2075
2114
  }
2076
2115
  ushr(i) {
2077
- return new Bitboard(shiftRightUnsigned(this.yq_1, i));
2116
+ return new Bitboard(shiftRightUnsigned(this.zq_1, i));
2078
2117
  }
2079
2118
  toArray() {
2080
- return toList(bitboardToSequence(this.yq_1, Bitboard$toArray$lambda)).e2();
2119
+ return toList(bitboardToSequence(this.zq_1, Bitboard$toArray$lambda)).e2();
2081
2120
  }
2082
2121
  }
2083
2122
  class EcoInfo_0 {
2084
2123
  constructor(backedEcoInfo) {
2085
- this.zq_1 = backedEcoInfo;
2086
- }
2087
- ar() {
2088
- return this.zq_1;
2124
+ this.ar_1 = backedEcoInfo;
2089
2125
  }
2090
2126
  br() {
2091
- return this.zq_1.mi_1;
2127
+ return this.ar_1;
2092
2128
  }
2093
2129
  cr() {
2094
- return this.zq_1.li_1;
2130
+ return this.ar_1.mi_1;
2131
+ }
2132
+ dr() {
2133
+ return this.ar_1.li_1;
2095
2134
  }
2096
2135
  get name() {
2097
- return this.br();
2136
+ return this.cr();
2098
2137
  }
2099
2138
  get eco() {
2100
- return this.cr();
2139
+ return this.dr();
2101
2140
  }
2102
2141
  }
2103
2142
  class Game_0 {
2104
2143
  constructor(backedGame) {
2105
- this.dr_1 = backedGame;
2106
- this.root = new Node_0(this.dr_1.wj_1);
2107
- this.id = this.dr_1.lk_1;
2144
+ this.er_1 = backedGame;
2145
+ this.root = new Node_0(this.er_1.wj_1);
2146
+ this.id = this.er_1.lk_1;
2108
2147
  }
2109
- er() {
2148
+ fr() {
2110
2149
  return this.root;
2111
2150
  }
2112
- fr(value) {
2113
- this.dr_1.lm(value == null ? null : value.zq_1);
2151
+ gr(value) {
2152
+ this.er_1.mm(value == null ? null : value.ar_1);
2114
2153
  }
2115
- gr() {
2116
- var tmp0_safe_receiver = this.dr_1.ek_1;
2154
+ hr() {
2155
+ var tmp0_safe_receiver = this.er_1.ek_1;
2117
2156
  var tmp;
2118
2157
  if (tmp0_safe_receiver == null) {
2119
2158
  tmp = null;
@@ -2123,10 +2162,10 @@ class Game_0 {
2123
2162
  }
2124
2163
  return tmp;
2125
2164
  }
2126
- hr() {
2165
+ ir() {
2127
2166
  return this.id;
2128
2167
  }
2129
- ir(value) {
2168
+ jr(value) {
2130
2169
  var tmp;
2131
2170
  if (value == null) {
2132
2171
  tmp = null;
@@ -2134,58 +2173,58 @@ class Game_0 {
2134
2173
  // Inline function 'kotlin.let' call
2135
2174
  tmp = valueOf_2(value);
2136
2175
  }
2137
- this.dr_1.mm(tmp);
2176
+ this.er_1.nm(tmp);
2138
2177
  }
2139
- jr() {
2140
- var tmp0_safe_receiver = this.dr_1.fk_1;
2178
+ kr() {
2179
+ var tmp0_safe_receiver = this.er_1.fk_1;
2141
2180
  return tmp0_safe_receiver == null ? null : tmp0_safe_receiver.toString();
2142
2181
  }
2143
- jm(value) {
2144
- this.dr_1.jm(value);
2145
- }
2146
- rm() {
2147
- return this.dr_1.bk_1;
2182
+ km(value) {
2183
+ this.er_1.km(value);
2148
2184
  }
2149
- nm(value) {
2150
- this.dr_1.nm(value);
2185
+ sm() {
2186
+ return this.er_1.bk_1;
2151
2187
  }
2152
- kr() {
2153
- return this.dr_1.jk_1;
2188
+ om(value) {
2189
+ this.er_1.om(value);
2154
2190
  }
2155
2191
  lr() {
2156
- return this.dr_1.hk_1.toString();
2157
- }
2158
- om(value) {
2159
- this.dr_1.om(value);
2192
+ return this.er_1.jk_1;
2160
2193
  }
2161
2194
  mr() {
2162
- return this.dr_1.kk_1;
2195
+ return this.er_1.hk_1.toString();
2163
2196
  }
2164
- hm(value) {
2165
- this.dr_1.hm(value);
2197
+ pm(value) {
2198
+ this.er_1.pm(value);
2166
2199
  }
2167
2200
  nr() {
2168
- return this.dr_1.zj_1;
2201
+ return this.er_1.kk_1;
2169
2202
  }
2170
- km(value) {
2171
- this.dr_1.km(value);
2203
+ im(value) {
2204
+ this.er_1.im(value);
2172
2205
  }
2173
2206
  pr() {
2174
- return this.dr_1.ck_1;
2207
+ return this.er_1.zj_1;
2175
2208
  }
2176
- qr() {
2177
- return this.dr_1.gk_1.toString();
2209
+ lm(value) {
2210
+ this.er_1.lm(value);
2178
2211
  }
2179
- im(value) {
2180
- this.dr_1.im(value);
2212
+ qr() {
2213
+ return this.er_1.ck_1;
2181
2214
  }
2182
2215
  rr() {
2183
- return this.dr_1.ak_1;
2216
+ return this.er_1.gk_1.toString();
2217
+ }
2218
+ jm(value) {
2219
+ this.er_1.jm(value);
2184
2220
  }
2185
2221
  sr() {
2222
+ return this.er_1.ak_1;
2223
+ }
2224
+ tr() {
2186
2225
  var p = {};
2187
2226
  // Inline function 'kotlin.collections.forEach' call
2188
- var _iterator__ex2g4s = this.dr_1.xj_1.k2().x();
2227
+ var _iterator__ex2g4s = this.er_1.xj_1.k2().x();
2189
2228
  while (_iterator__ex2g4s.z()) {
2190
2229
  var element = _iterator__ex2g4s.a1();
2191
2230
  p[element.g2()] = element.h2();
@@ -2194,16 +2233,16 @@ class Game_0 {
2194
2233
  }
2195
2234
  setTag(name, value) {
2196
2235
  // Inline function 'kotlin.collections.set' call
2197
- this.dr_1.xj_1.f5(name, value);
2236
+ this.er_1.xj_1.f5(name, value);
2198
2237
  }
2199
2238
  getTag(name) {
2200
- return this.dr_1.xj_1.j2(name);
2239
+ return this.er_1.xj_1.j2(name);
2201
2240
  }
2202
2241
  toString() {
2203
- return this.dr_1.toString();
2242
+ return this.er_1.toString();
2204
2243
  }
2205
- sm(idSupplier) {
2206
- return new Game_0(this.dr_1.sm(idSupplier));
2244
+ tm(idSupplier) {
2245
+ return new Game_0(this.er_1.tm(idSupplier));
2207
2246
  }
2208
2247
  toAnalysis(idSupplier, $super) {
2209
2248
  var tmp;
@@ -2213,90 +2252,93 @@ class Game_0 {
2213
2252
  tmp = idSupplier;
2214
2253
  }
2215
2254
  idSupplier = tmp;
2216
- return $super === VOID ? this.sm(idSupplier) : $super.sm.call(this, idSupplier);
2255
+ return $super === VOID ? this.tm(idSupplier) : $super.tm.call(this, idSupplier);
2217
2256
  }
2218
2257
  deleteFromExclusive(node) {
2219
- return new Node_0(deleteFromExclusive(this.dr_1, node.tr_1));
2258
+ return new Node_0(deleteFromExclusive(this.er_1, node.ur_1));
2220
2259
  }
2221
2260
  deleteFromInclusive(node) {
2222
- return new Node_0(deleteFromInclusive(this.dr_1, node.tr_1));
2261
+ return new Node_0(deleteFromInclusive(this.er_1, node.ur_1));
2223
2262
  }
2224
2263
  deleteBefore(_this__u8e3s4, node) {
2225
- return new Node_0(deleteBefore(_this__u8e3s4.dr_1, node.tr_1));
2264
+ return new Node_0(deleteBefore(_this__u8e3s4.er_1, node.ur_1));
2265
+ }
2266
+ updateEco() {
2267
+ this.er_1.tl();
2226
2268
  }
2227
2269
  get ecoInfo() {
2228
- return this.gr();
2270
+ return this.hr();
2229
2271
  }
2230
2272
  set ecoInfo(value) {
2231
- this.fr(value);
2273
+ this.gr(value);
2232
2274
  }
2233
2275
  get result() {
2234
- return this.jr();
2276
+ return this.kr();
2235
2277
  }
2236
2278
  set result(value) {
2237
- this.ir(value);
2279
+ this.jr(value);
2238
2280
  }
2239
2281
  get fiftyMoves() {
2240
- return this.rm();
2282
+ return this.sm();
2241
2283
  }
2242
2284
  set fiftyMoves(value) {
2243
- this.jm(value);
2285
+ this.km(value);
2244
2286
  }
2245
2287
  get finalComment() {
2246
- return this.kr();
2288
+ return this.lr();
2247
2289
  }
2248
2290
  set finalComment(value) {
2249
- this.nm(value);
2291
+ this.om(value);
2250
2292
  }
2251
2293
  get fiftyMovesRuleMode() {
2252
- return this.lr();
2294
+ return this.mr();
2253
2295
  }
2254
2296
  get finalEndLineComment() {
2255
- return this.mr();
2297
+ return this.nr();
2256
2298
  }
2257
2299
  set finalEndLineComment(value) {
2258
- this.om(value);
2300
+ this.pm(value);
2259
2301
  }
2260
2302
  get fiveRepetitions() {
2261
- return this.nr();
2303
+ return this.pr();
2262
2304
  }
2263
2305
  set fiveRepetitions(value) {
2264
- this.hm(value);
2306
+ this.im(value);
2265
2307
  }
2266
2308
  get seventyFiveMoves() {
2267
- return this.pr();
2309
+ return this.qr();
2268
2310
  }
2269
2311
  set seventyFiveMoves(value) {
2270
- this.km(value);
2312
+ this.lm(value);
2271
2313
  }
2272
2314
  get threeRepetitionsMode() {
2273
- return this.qr();
2315
+ return this.rr();
2274
2316
  }
2275
2317
  get threeRepetitionsWarning() {
2276
- return this.rr();
2318
+ return this.sr();
2277
2319
  }
2278
2320
  set threeRepetitionsWarning(value) {
2279
- this.im(value);
2321
+ this.jm(value);
2280
2322
  }
2281
2323
  get tags() {
2282
- return this.sr();
2324
+ return this.tr();
2283
2325
  }
2284
2326
  }
2285
2327
  class Move_0 {
2286
2328
  constructor(backedMove) {
2287
2329
  this.backedMove = backedMove;
2288
2330
  }
2289
- ur() {
2290
- return this.backedMove;
2291
- }
2292
2331
  vr() {
2293
- return this.backedMove.pn_1;
2332
+ return this.backedMove;
2294
2333
  }
2295
2334
  wr() {
2296
- return this.backedMove.rn_1;
2335
+ return this.backedMove.qn_1;
2297
2336
  }
2298
2337
  xr() {
2299
- return this.backedMove.qn_1;
2338
+ return this.backedMove.sn_1;
2339
+ }
2340
+ yr() {
2341
+ return this.backedMove.rn_1;
2300
2342
  }
2301
2343
  hashCode() {
2302
2344
  return this.backedMove.hashCode();
@@ -2314,27 +2356,27 @@ class Move_0 {
2314
2356
  return this.backedMove.toString();
2315
2357
  }
2316
2358
  get origin() {
2317
- return this.vr();
2359
+ return this.wr();
2318
2360
  }
2319
2361
  get target() {
2320
- return this.wr();
2362
+ return this.xr();
2321
2363
  }
2322
2364
  get promotionPiece() {
2323
- return this.xr();
2365
+ return this.yr();
2324
2366
  }
2325
2367
  }
2326
2368
  class Node_0 {
2327
2369
  constructor(backedNode) {
2328
- this.tr_1 = backedNode;
2370
+ this.ur_1 = backedNode;
2329
2371
  }
2330
- yr() {
2331
- return this.tr_1;
2372
+ zr() {
2373
+ return this.ur_1;
2332
2374
  }
2333
2375
  uj() {
2334
- return new Position_0(this.tr_1.uj());
2376
+ return new Position_0(this.ur_1.uj());
2335
2377
  }
2336
2378
  rk() {
2337
- var tmp0_safe_receiver = this.tr_1.rk();
2379
+ var tmp0_safe_receiver = this.ur_1.rk();
2338
2380
  var tmp;
2339
2381
  if (tmp0_safe_receiver == null) {
2340
2382
  tmp = null;
@@ -2346,7 +2388,7 @@ class Node_0 {
2346
2388
  }
2347
2389
  bj() {
2348
2390
  // Inline function 'kotlin.collections.map' call
2349
- var this_0 = this.tr_1.bj();
2391
+ var this_0 = this.ur_1.bj();
2350
2392
  // Inline function 'kotlin.collections.mapTo' call
2351
2393
  var destination = ArrayList.l5(collectionSizeOrDefault(this_0, 10));
2352
2394
  var _iterator__ex2g4s = this_0.x();
@@ -2358,20 +2400,20 @@ class Node_0 {
2358
2400
  return destination.e2();
2359
2401
  }
2360
2402
  sk() {
2361
- return this.tr_1.sk();
2403
+ return this.ur_1.sk();
2362
2404
  }
2363
2405
  cj() {
2364
- return this.tr_1.cj();
2406
+ return this.ur_1.cj();
2365
2407
  }
2366
2408
  dj() {
2367
- return this.tr_1.dj();
2409
+ return this.ur_1.dj();
2368
2410
  }
2369
2411
  tk() {
2370
- var tmp0_safe_receiver = this.tr_1.tk();
2412
+ var tmp0_safe_receiver = this.ur_1.tk();
2371
2413
  return tmp0_safe_receiver == null ? null : tmp0_safe_receiver.e2();
2372
2414
  }
2373
2415
  aj() {
2374
- var tmp0_safe_receiver = this.tr_1.aj();
2416
+ var tmp0_safe_receiver = this.ur_1.aj();
2375
2417
  var tmp;
2376
2418
  if (tmp0_safe_receiver == null) {
2377
2419
  tmp = null;
@@ -2381,7 +2423,7 @@ class Node_0 {
2381
2423
  }
2382
2424
  return tmp;
2383
2425
  }
2384
- zr(move, initialComment, comment, endLineComment, suffixAnnotations, notation) {
2426
+ as(move, initialComment, comment, endLineComment, suffixAnnotations, notation) {
2385
2427
  var tmp;
2386
2428
  if (suffixAnnotations == null) {
2387
2429
  tmp = null;
@@ -2389,7 +2431,7 @@ class Node_0 {
2389
2431
  // Inline function 'kotlin.js.collections.toList' call
2390
2432
  tmp = createListFrom(suffixAnnotations);
2391
2433
  }
2392
- return new Node_0(this.tr_1.vk(move, initialComment, comment, endLineComment, tmp, valueOf_3(notation.name)));
2434
+ return new Node_0(this.ur_1.vk(move, initialComment, comment, endLineComment, tmp, valueOf_3(notation.name)));
2393
2435
  }
2394
2436
  appendMove(move, initialComment, comment, endLineComment, suffixAnnotations, notation, $super) {
2395
2437
  initialComment = initialComment === VOID ? null : initialComment;
@@ -2397,40 +2439,48 @@ class Node_0 {
2397
2439
  endLineComment = endLineComment === VOID ? null : endLineComment;
2398
2440
  suffixAnnotations = suffixAnnotations === VOID ? null : suffixAnnotations;
2399
2441
  notation = notation === VOID ? get_SAN() : notation;
2400
- return $super === VOID ? this.zr(move, initialComment, comment, endLineComment, suffixAnnotations, notation) : $super.zr.call(this, move, initialComment, comment, endLineComment, suffixAnnotations, notation);
2442
+ return $super === VOID ? this.as(move, initialComment, comment, endLineComment, suffixAnnotations, notation) : $super.as.call(this, move, initialComment, comment, endLineComment, suffixAnnotations, notation);
2401
2443
  }
2402
2444
  promoteChild(index) {
2403
- return this.tr_1.xk(index);
2445
+ return this.ur_1.xk(index);
2404
2446
  }
2405
2447
  promoteNode() {
2406
- return this.tr_1.yk();
2448
+ return this.ur_1.yk();
2407
2449
  }
2408
2450
  removeChild(node) {
2409
- return this.tr_1.zk(node.tr_1);
2451
+ return this.ur_1.zk(node.ur_1);
2410
2452
  }
2411
2453
  hasChildren() {
2412
- return this.tr_1.al();
2454
+ return this.ur_1.al();
2413
2455
  }
2414
2456
  belongsToMainLine() {
2415
- return this.tr_1.bl();
2457
+ return this.ur_1.bl();
2416
2458
  }
2417
2459
  copy(parent) {
2418
- return new Node_0(this.tr_1.cl(parent == null ? null : parent.tr_1));
2460
+ return new Node_0(this.ur_1.cl(parent == null ? null : parent.ur_1));
2419
2461
  }
2420
2462
  hashCode() {
2421
- return hashCode(this.tr_1);
2463
+ return hashCode(this.ur_1);
2422
2464
  }
2423
2465
  equals(other) {
2424
2466
  var tmp;
2425
2467
  if (other instanceof Node_0) {
2426
- tmp = equals(this.tr_1, other.tr_1);
2468
+ tmp = equals(this.ur_1, other.ur_1);
2427
2469
  } else {
2428
2470
  tmp = false;
2429
2471
  }
2430
2472
  return tmp;
2431
2473
  }
2432
2474
  toString() {
2433
- return toString(this.tr_1);
2475
+ return toString(this.ur_1);
2476
+ }
2477
+ dl(language, pieces) {
2478
+ return this.ur_1.dl(language, pieces);
2479
+ }
2480
+ toSan(language, pieces, $super) {
2481
+ language = language === VOID ? 'english' : language;
2482
+ pieces = pieces === VOID ? null : pieces;
2483
+ return $super === VOID ? this.dl(language, pieces) : $super.dl.call(this, language, pieces);
2434
2484
  }
2435
2485
  get position() {
2436
2486
  return this.uj();
@@ -2485,13 +2535,13 @@ class Companion_8 {
2485
2535
  var pair = to(element.l2_1, new Notation_0(element.l2_1));
2486
2536
  destination_0.f5(pair.md_1, pair.nd_1);
2487
2537
  }
2488
- tmp_0.as_1 = destination_0;
2538
+ tmp_0.bs_1 = destination_0;
2489
2539
  }
2490
2540
  k2() {
2491
2541
  return this.entries;
2492
2542
  }
2493
2543
  get(name) {
2494
- return this.as_1.j2(name);
2544
+ return this.bs_1.j2(name);
2495
2545
  }
2496
2546
  }
2497
2547
  class Notation_0 {
@@ -2499,7 +2549,7 @@ class Notation_0 {
2499
2549
  Companion_getInstance_8();
2500
2550
  this.name = name;
2501
2551
  }
2502
- br() {
2552
+ cr() {
2503
2553
  return this.name;
2504
2554
  }
2505
2555
  }
@@ -2529,7 +2579,7 @@ class Companion_9 {
2529
2579
  var tmp$ret$3 = new Piece_0(item_0.m2_1, item_0.l2_1);
2530
2580
  destination_0.k(tmp$ret$3);
2531
2581
  }
2532
- tmp_0.bs_1 = destination_0;
2582
+ tmp_0.cs_1 = destination_0;
2533
2583
  var tmp_1 = this;
2534
2584
  // Inline function 'kotlin.collections.associate' call
2535
2585
  var this_2 = get_entries_2();
@@ -2543,19 +2593,19 @@ class Companion_9 {
2543
2593
  var pair = to(element.l2_1, new Piece_0(element.m2_1, element.l2_1));
2544
2594
  destination_1.f5(pair.md_1, pair.nd_1);
2545
2595
  }
2546
- tmp_1.cs_1 = destination_1;
2596
+ tmp_1.ds_1 = destination_1;
2547
2597
  }
2548
2598
  k2() {
2549
2599
  return this.entries;
2550
2600
  }
2551
- ds() {
2552
- return this.bs_1;
2601
+ es() {
2602
+ return this.cs_1;
2553
2603
  }
2554
2604
  get(name) {
2555
- return this.cs_1.j2(name);
2605
+ return this.ds_1.j2(name);
2556
2606
  }
2557
2607
  indexToPiece(index) {
2558
- return this.bs_1.c1(index);
2608
+ return this.cs_1.c1(index);
2559
2609
  }
2560
2610
  }
2561
2611
  class Piece_0 {
@@ -2564,19 +2614,19 @@ class Piece_0 {
2564
2614
  this.ordinal = ordinal;
2565
2615
  this.name = name;
2566
2616
  }
2567
- es() {
2617
+ fs() {
2568
2618
  return this.ordinal;
2569
2619
  }
2570
- br() {
2620
+ cr() {
2571
2621
  return this.name;
2572
2622
  }
2573
2623
  }
2574
2624
  class Position_0 {
2575
2625
  constructor(backedPosition) {
2576
- this.fs_1 = backedPosition;
2626
+ this.gs_1 = backedPosition;
2577
2627
  var tmp = this;
2578
2628
  // Inline function 'kotlin.collections.map' call
2579
- var this_0 = this.fs_1.eq();
2629
+ var this_0 = this.gs_1.fq();
2580
2630
  // Inline function 'kotlin.collections.mapTo' call
2581
2631
  var destination = ArrayList.l5(this_0.length);
2582
2632
  var inductionVariable = 0;
@@ -2588,69 +2638,69 @@ class Position_0 {
2588
2638
  destination.k(tmp$ret$0);
2589
2639
  }
2590
2640
  tmp.bitboards = destination.e2();
2591
- this.whiteMove = this.fs_1.fj_1;
2592
- this.enPassant = this.fs_1.gj_1;
2593
- this.whiteCastleKingside = this.fs_1.hj_1;
2594
- this.whiteCastleQueenside = this.fs_1.ij_1;
2595
- this.blackCastleKingside = this.fs_1.jj_1;
2596
- this.blackCastleQueenside = this.fs_1.kj_1;
2597
- this.movesCounter = this.fs_1.lj_1;
2598
- this.halfMovesCounter = this.fs_1.mj_1;
2641
+ this.whiteMove = this.gs_1.fj_1;
2642
+ this.enPassant = this.gs_1.gj_1;
2643
+ this.whiteCastleKingside = this.gs_1.hj_1;
2644
+ this.whiteCastleQueenside = this.gs_1.ij_1;
2645
+ this.blackCastleKingside = this.gs_1.jj_1;
2646
+ this.blackCastleQueenside = this.gs_1.kj_1;
2647
+ this.movesCounter = this.gs_1.lj_1;
2648
+ this.halfMovesCounter = this.gs_1.mj_1;
2599
2649
  }
2600
- eq() {
2650
+ fq() {
2601
2651
  return this.bitboards;
2602
2652
  }
2603
- gs() {
2653
+ hs() {
2604
2654
  return this.whiteMove;
2605
2655
  }
2606
- hs() {
2656
+ is() {
2607
2657
  return this.enPassant;
2608
2658
  }
2609
- is() {
2659
+ js() {
2610
2660
  return this.whiteCastleKingside;
2611
2661
  }
2612
- js() {
2662
+ ks() {
2613
2663
  return this.whiteCastleQueenside;
2614
2664
  }
2615
- ks() {
2665
+ ls() {
2616
2666
  return this.blackCastleKingside;
2617
2667
  }
2618
- ls() {
2668
+ ms() {
2619
2669
  return this.blackCastleQueenside;
2620
2670
  }
2621
- ms() {
2671
+ ns() {
2622
2672
  return this.movesCounter;
2623
2673
  }
2624
- ns() {
2674
+ os() {
2625
2675
  return this.halfMovesCounter;
2626
2676
  }
2627
- fq() {
2628
- return this.fs_1.fq();
2629
- }
2630
2677
  gq() {
2631
- return this.fs_1.gq();
2678
+ return this.gs_1.gq();
2632
2679
  }
2633
2680
  hq() {
2634
- return this.fs_1.hq();
2681
+ return this.gs_1.hq();
2635
2682
  }
2636
2683
  iq() {
2637
- return this.fs_1.iq();
2638
- }
2639
- rm() {
2640
- return this.fs_1.rm();
2684
+ return this.gs_1.iq();
2641
2685
  }
2642
2686
  jq() {
2643
- return new Bitboard(this.fs_1.jq());
2687
+ return this.gs_1.jq();
2688
+ }
2689
+ sm() {
2690
+ return this.gs_1.sm();
2644
2691
  }
2645
2692
  kq() {
2646
- return this.fs_1.kq();
2693
+ return new Bitboard(this.gs_1.kq());
2647
2694
  }
2648
2695
  lq() {
2649
- return this.fs_1.lq();
2696
+ return this.gs_1.lq();
2697
+ }
2698
+ mq() {
2699
+ return this.gs_1.mq();
2650
2700
  }
2651
2701
  bj() {
2652
2702
  // Inline function 'kotlin.collections.map' call
2653
- var this_0 = get_children(this.fs_1);
2703
+ var this_0 = get_children(this.gs_1);
2654
2704
  // Inline function 'kotlin.collections.mapTo' call
2655
2705
  var destination = ArrayList.l5(collectionSizeOrDefault(this_0, 10));
2656
2706
  var _iterator__ex2g4s = this_0.x();
@@ -2662,11 +2712,11 @@ class Position_0 {
2662
2712
  }
2663
2713
  return destination.e2();
2664
2714
  }
2665
- os() {
2666
- return get_draw(this.fs_1);
2667
- }
2668
2715
  ps() {
2669
- var tmp0_safe_receiver = get_enPassantSquare(this.fs_1);
2716
+ return get_draw(this.gs_1);
2717
+ }
2718
+ qs() {
2719
+ var tmp0_safe_receiver = get_enPassantSquare(this.gs_1);
2670
2720
  var tmp;
2671
2721
  if (tmp0_safe_receiver == null) {
2672
2722
  tmp = null;
@@ -2676,87 +2726,87 @@ class Position_0 {
2676
2726
  }
2677
2727
  return tmp;
2678
2728
  }
2679
- qs() {
2680
- return get_gameOver(this.fs_1);
2681
- }
2682
2729
  rs() {
2683
- return ensureNotNull(Companion_getInstance_10().get(get_sideToMove(this.fs_1).l2_1));
2730
+ return get_gameOver(this.gs_1);
2731
+ }
2732
+ ss() {
2733
+ return ensureNotNull(Companion_getInstance_10().get(get_sideToMove(this.gs_1).l2_1));
2684
2734
  }
2685
2735
  whiteLacksOfMaterial() {
2686
- return whiteLacksOfMaterial(this.fs_1);
2736
+ return whiteLacksOfMaterial(this.gs_1);
2687
2737
  }
2688
2738
  blackLacksOfMaterial() {
2689
- return blackLacksOfMaterial(this.fs_1);
2739
+ return blackLacksOfMaterial(this.gs_1);
2690
2740
  }
2691
2741
  pieceAt(square) {
2692
- return Companion_getInstance_9().bs_1.c1(this.squares[square.ordinal]);
2742
+ return Companion_getInstance_9().cs_1.c1(this.squares[square.ordinal]);
2693
2743
  }
2694
2744
  isLegal(move) {
2695
- return isLegal(this.fs_1, move.backedMove);
2745
+ return isLegal(this.gs_1, move.backedMove);
2696
2746
  }
2697
2747
  move(move_0) {
2698
- return new Position_0(move(this.fs_1, move_0.backedMove));
2748
+ return new Position_0(move(this.gs_1, move_0.backedMove));
2699
2749
  }
2700
- ss(move, notation) {
2701
- return new Position_0(move_0(this.fs_1, move, valueOf_3(notation.name)));
2750
+ ts(move, notation) {
2751
+ return new Position_0(move_0(this.gs_1, move, valueOf_3(notation.name)));
2702
2752
  }
2703
2753
  moveFromString(move, notation, $super) {
2704
2754
  notation = notation === VOID ? get_UCI() : notation;
2705
- return $super === VOID ? this.ss(move, notation) : $super.ss.call(this, move, notation);
2755
+ return $super === VOID ? this.ts(move, notation) : $super.ts.call(this, move, notation);
2706
2756
  }
2707
2757
  hashCode() {
2708
- return this.fs_1.hashCode();
2758
+ return this.gs_1.hashCode();
2709
2759
  }
2710
2760
  equals(other) {
2711
2761
  var tmp;
2712
2762
  if (other instanceof Position_0) {
2713
- tmp = this.fs_1.equals(other.fs_1);
2763
+ tmp = this.gs_1.equals(other.gs_1);
2714
2764
  } else {
2715
2765
  tmp = false;
2716
2766
  }
2717
2767
  return tmp;
2718
2768
  }
2719
2769
  toString() {
2720
- return this.fs_1.toString();
2770
+ return this.gs_1.toString();
2721
2771
  }
2722
2772
  get check() {
2723
- return this.fq();
2773
+ return this.gq();
2724
2774
  }
2725
2775
  get checkmate() {
2726
- return this.gq();
2776
+ return this.hq();
2727
2777
  }
2728
2778
  get stalemate() {
2729
- return this.hq();
2779
+ return this.iq();
2730
2780
  }
2731
2781
  get lackOfMaterial() {
2732
- return this.iq();
2782
+ return this.jq();
2733
2783
  }
2734
2784
  get fiftyMoves() {
2735
- return this.rm();
2785
+ return this.sm();
2736
2786
  }
2737
2787
  get zobrist() {
2738
- return this.jq();
2788
+ return this.kq();
2739
2789
  }
2740
2790
  get squares() {
2741
- return this.kq();
2791
+ return this.lq();
2742
2792
  }
2743
2793
  get fen() {
2744
- return this.lq();
2794
+ return this.mq();
2745
2795
  }
2746
2796
  get children() {
2747
2797
  return this.bj();
2748
2798
  }
2749
2799
  get draw() {
2750
- return this.os();
2800
+ return this.ps();
2751
2801
  }
2752
2802
  get enPassantSquare() {
2753
- return this.ps();
2803
+ return this.qs();
2754
2804
  }
2755
2805
  get gameOver() {
2756
- return this.qs();
2806
+ return this.rs();
2757
2807
  }
2758
2808
  get sideToMove() {
2759
- return this.rs();
2809
+ return this.ss();
2760
2810
  }
2761
2811
  }
2762
2812
  class Companion_10 {
@@ -2773,7 +2823,7 @@ class Companion_10 {
2773
2823
  var tmp$ret$0 = new Side_0(item.l2_1);
2774
2824
  destination.k(tmp$ret$0);
2775
2825
  }
2776
- tmp.ts_1 = destination;
2826
+ tmp.us_1 = destination;
2777
2827
  var tmp_0 = this;
2778
2828
  // Inline function 'kotlin.collections.map' call
2779
2829
  var this_1 = get_entries_1();
@@ -2799,16 +2849,16 @@ class Companion_10 {
2799
2849
  var pair = to(element.l2_1, new Side_0(element.l2_1));
2800
2850
  destination_1.f5(pair.md_1, pair.nd_1);
2801
2851
  }
2802
- tmp_1.us_1 = destination_1;
2852
+ tmp_1.vs_1 = destination_1;
2803
2853
  }
2804
- ds() {
2805
- return this.ts_1;
2854
+ es() {
2855
+ return this.us_1;
2806
2856
  }
2807
2857
  k2() {
2808
2858
  return this.entries;
2809
2859
  }
2810
2860
  get(name) {
2811
- return this.us_1.j2(name);
2861
+ return this.vs_1.j2(name);
2812
2862
  }
2813
2863
  }
2814
2864
  class Side_0 {
@@ -2816,7 +2866,7 @@ class Side_0 {
2816
2866
  Companion_getInstance_10();
2817
2867
  this.name = name;
2818
2868
  }
2819
- br() {
2869
+ cr() {
2820
2870
  return this.name;
2821
2871
  }
2822
2872
  }
@@ -2846,7 +2896,7 @@ class Companion_11 {
2846
2896
  var tmp$ret$3 = new Square_0(item_0.m2_1, item_0.l2_1);
2847
2897
  destination_0.k(tmp$ret$3);
2848
2898
  }
2849
- tmp_0.vs_1 = destination_0;
2899
+ tmp_0.ws_1 = destination_0;
2850
2900
  var tmp_1 = this;
2851
2901
  // Inline function 'kotlin.collections.associate' call
2852
2902
  var this_2 = get_entries_2();
@@ -2860,19 +2910,19 @@ class Companion_11 {
2860
2910
  var pair = to(element.l2_1, new Square_0(element.m2_1, element.l2_1));
2861
2911
  destination_1.f5(pair.md_1, pair.nd_1);
2862
2912
  }
2863
- tmp_1.ws_1 = destination_1;
2913
+ tmp_1.xs_1 = destination_1;
2864
2914
  }
2865
2915
  k2() {
2866
2916
  return this.entries;
2867
2917
  }
2868
- ds() {
2869
- return this.vs_1;
2918
+ es() {
2919
+ return this.ws_1;
2870
2920
  }
2871
2921
  get(name) {
2872
- return this.ws_1.j2(name);
2922
+ return this.xs_1.j2(name);
2873
2923
  }
2874
2924
  indexToSquare(index) {
2875
- return this.vs_1.c1(index);
2925
+ return this.ws_1.c1(index);
2876
2926
  }
2877
2927
  }
2878
2928
  class Square_0 {
@@ -2881,10 +2931,10 @@ class Square_0 {
2881
2931
  this.ordinal = ordinal;
2882
2932
  this.name = name;
2883
2933
  }
2884
- es() {
2934
+ fs() {
2885
2935
  return this.ordinal;
2886
2936
  }
2887
- br() {
2937
+ cr() {
2888
2938
  return this.name;
2889
2939
  }
2890
2940
  getCol() {
@@ -3105,7 +3155,7 @@ function toString_3($this, tabulation) {
3105
3155
  sb.za(p.uj().lj_1).j8('...');
3106
3156
  }
3107
3157
  }
3108
- sb.j8(toSan(p.uj(), $this.oi_1)).j8(' ');
3158
+ sb.j8(toSan_0(p.uj(), $this.oi_1)).j8(' ');
3109
3159
  var tmp6_safe_receiver = $this.si_1;
3110
3160
  if (tmp6_safe_receiver == null)
3111
3161
  null;
@@ -3403,35 +3453,35 @@ function Result_DRAW_getInstance() {
3403
3453
  return Result_DRAW_instance;
3404
3454
  }
3405
3455
  function *_generator_invoke__zhh2q8($this, $this$sequence, $completion) {
3406
- var tmp = $this$sequence.wd($this.tm_1.en(), $completion);
3456
+ var tmp = $this$sequence.wd($this.um_1.fn(), $completion);
3407
3457
  if (tmp === get_COROUTINE_SUSPENDED())
3408
3458
  tmp = yield tmp;
3409
- var tmp_0 = $this$sequence.wd($this.tm_1.fn(), $completion);
3459
+ var tmp_0 = $this$sequence.wd($this.um_1.gn(), $completion);
3410
3460
  if (tmp_0 === get_COROUTINE_SUSPENDED())
3411
3461
  tmp_0 = yield tmp_0;
3412
3462
  return Unit_instance;
3413
3463
  }
3414
3464
  function KingMoves$regularMovesList$delegate$lambda$lambda(this$0) {
3415
- return (it) => this$0.zm_1(this$0.vm_1, countTrailingZeroBits(it));
3465
+ return (it) => this$0.an_1(this$0.wm_1, countTrailingZeroBits(it));
3416
3466
  }
3417
3467
  function KingMoves$regularMovesList$delegate$lambda(this$0) {
3418
- return () => bitboardToList(this$0.xm_1, KingMoves$regularMovesList$delegate$lambda$lambda(this$0));
3468
+ return () => bitboardToList(this$0.ym_1, KingMoves$regularMovesList$delegate$lambda$lambda(this$0));
3419
3469
  }
3420
3470
  function KingMoves$_get_regularMovesList_$ref_1r6ljl() {
3421
- return (p0) => p0.en();
3471
+ return (p0) => p0.fn();
3422
3472
  }
3423
3473
  function KingMoves$castleMovesList$delegate$lambda$lambda(this$0) {
3424
- return (it) => this$0.zm_1(this$0.vm_1, countTrailingZeroBits(it));
3474
+ return (it) => this$0.an_1(this$0.wm_1, countTrailingZeroBits(it));
3425
3475
  }
3426
3476
  function KingMoves$castleMovesList$delegate$lambda(this$0) {
3427
- return () => bitboardToList(this$0.ym_1, KingMoves$castleMovesList$delegate$lambda$lambda(this$0));
3477
+ return () => bitboardToList(this$0.zm_1, KingMoves$castleMovesList$delegate$lambda$lambda(this$0));
3428
3478
  }
3429
3479
  function KingMoves$_get_castleMovesList_$ref_3suu4f() {
3430
- return (p0) => p0.fn();
3480
+ return (p0) => p0.gn();
3431
3481
  }
3432
3482
  function KingMoves$allMovesList$delegate$lambda$slambda_0(this$0) {
3433
3483
  var i = new KingMoves$allMovesList$delegate$lambda$slambda(this$0);
3434
- var l = ($this$sequence, $completion) => i.gn($this$sequence, $completion);
3484
+ var l = ($this$sequence, $completion) => i.hn($this$sequence, $completion);
3435
3485
  l.$arity = 1;
3436
3486
  return l;
3437
3487
  }
@@ -3439,7 +3489,7 @@ function KingMoves$allMovesList$delegate$lambda(this$0) {
3439
3489
  return () => toList(sequence(KingMoves$allMovesList$delegate$lambda$slambda_0(this$0)));
3440
3490
  }
3441
3491
  function KingMoves$_get_allMovesList_$ref_go3t84() {
3442
- return (p0) => p0.hn();
3492
+ return (p0) => p0.in();
3443
3493
  }
3444
3494
  var Level_TRACE_instance;
3445
3495
  var Level_DEBUG_instance;
@@ -3519,67 +3569,67 @@ function init_io_github_lunalobos_chess4kt_Move(_this__u8e3s4) {
3519
3569
  Companion_getInstance_2();
3520
3570
  }
3521
3571
  function init_io_github_lunalobos_chess4kt_MoveException(_this__u8e3s4) {
3522
- captureStack(_this__u8e3s4, _this__u8e3s4.yn_1);
3572
+ captureStack(_this__u8e3s4, _this__u8e3s4.zn_1);
3523
3573
  }
3524
3574
  function *_generator_invoke__zhh2q8_0($this, $this$sequence, $completion) {
3525
- var tmp = asSequence($this.io_1.ao_1);
3575
+ var tmp = asSequence($this.jo_1.bo_1);
3526
3576
  var tmp_0 = $this$sequence.xd(flatMap(tmp, MovesInfo$movesList$delegate$lambda$slambda$lambda), $completion);
3527
3577
  if (tmp_0 === get_COROUTINE_SUSPENDED())
3528
3578
  tmp_0 = yield tmp_0;
3529
- var tmp_1 = asSequence($this.io_1.bo_1);
3579
+ var tmp_1 = asSequence($this.jo_1.co_1);
3530
3580
  var tmp_2 = $this$sequence.xd(flatMap(tmp_1, MovesInfo$movesList$delegate$lambda$slambda$lambda_0), $completion);
3531
3581
  if (tmp_2 === get_COROUTINE_SUSPENDED())
3532
3582
  tmp_2 = yield tmp_2;
3533
- var tmp_3 = asSequence($this.io_1.co_1);
3583
+ var tmp_3 = asSequence($this.jo_1.do_1);
3534
3584
  var tmp_4 = $this$sequence.xd(flatMap(tmp_3, MovesInfo$movesList$delegate$lambda$slambda$lambda_1), $completion);
3535
3585
  if (tmp_4 === get_COROUTINE_SUSPENDED())
3536
3586
  tmp_4 = yield tmp_4;
3537
- var tmp_5 = asSequence($this.io_1.do_1);
3587
+ var tmp_5 = asSequence($this.jo_1.eo_1);
3538
3588
  var tmp_6 = $this$sequence.xd(flatMap(tmp_5, MovesInfo$movesList$delegate$lambda$slambda$lambda_2), $completion);
3539
3589
  if (tmp_6 === get_COROUTINE_SUSPENDED())
3540
3590
  tmp_6 = yield tmp_6;
3541
- var tmp_7 = asSequence($this.io_1.eo_1);
3591
+ var tmp_7 = asSequence($this.jo_1.fo_1);
3542
3592
  var tmp_8 = $this$sequence.xd(flatMap(tmp_7, MovesInfo$movesList$delegate$lambda$slambda$lambda_3), $completion);
3543
3593
  if (tmp_8 === get_COROUTINE_SUSPENDED())
3544
3594
  tmp_8 = yield tmp_8;
3545
- var tmp_9 = $this$sequence.xd(asSequence($this.io_1.fo_1.hn()), $completion);
3595
+ var tmp_9 = $this$sequence.xd(asSequence($this.jo_1.go_1.in()), $completion);
3546
3596
  if (tmp_9 === get_COROUTINE_SUSPENDED())
3547
3597
  tmp_9 = yield tmp_9;
3548
3598
  return Unit_instance;
3549
3599
  }
3550
3600
  function MovesInfo$movesList$delegate$lambda$slambda$lambda(it) {
3551
- return asSequence(it.hn());
3601
+ return asSequence(it.in());
3552
3602
  }
3553
3603
  function MovesInfo$movesList$delegate$lambda$slambda$lambda_0(it) {
3554
- return asSequence(it.hn());
3604
+ return asSequence(it.in());
3555
3605
  }
3556
3606
  function MovesInfo$movesList$delegate$lambda$slambda$lambda_1(it) {
3557
- return asSequence(it.hn());
3607
+ return asSequence(it.in());
3558
3608
  }
3559
3609
  function MovesInfo$movesList$delegate$lambda$slambda$lambda_2(it) {
3560
- return asSequence(it.hn());
3610
+ return asSequence(it.in());
3561
3611
  }
3562
3612
  function MovesInfo$movesList$delegate$lambda$slambda$lambda_3(it) {
3563
- return asSequence(it.hn());
3613
+ return asSequence(it.in());
3564
3614
  }
3565
3615
  function MovesInfo$moves$delegate$lambda$lambda(it) {
3566
- return it.wo_1;
3616
+ return it.xo_1;
3567
3617
  }
3568
3618
  function MovesInfo$moves$delegate$lambda$lambda_0(it) {
3569
- return it.bp_1;
3619
+ return it.cp_1;
3570
3620
  }
3571
3621
  function MovesInfo$moves$delegate$lambda$lambda_1(it) {
3572
- return it.bp_1;
3622
+ return it.cp_1;
3573
3623
  }
3574
3624
  function MovesInfo$moves$delegate$lambda$lambda_2(it) {
3575
- return it.bp_1;
3625
+ return it.cp_1;
3576
3626
  }
3577
3627
  function MovesInfo$moves$delegate$lambda$lambda_3(it) {
3578
- return it.bp_1;
3628
+ return it.cp_1;
3579
3629
  }
3580
3630
  function MovesInfo$moves$delegate$lambda(this$0) {
3581
3631
  return () => {
3582
- var tmp = asSequence(this$0.ao_1);
3632
+ var tmp = asSequence(this$0.bo_1);
3583
3633
  // Inline function 'kotlin.sequences.fold' call
3584
3634
  var accumulator = 0n;
3585
3635
  var _iterator__ex2g4s = map(tmp, MovesInfo$moves$delegate$lambda$lambda).x();
@@ -3588,7 +3638,7 @@ function MovesInfo$moves$delegate$lambda(this$0) {
3588
3638
  accumulator = accumulator | element;
3589
3639
  }
3590
3640
  var pm = accumulator;
3591
- var tmp_0 = asSequence(this$0.bo_1);
3641
+ var tmp_0 = asSequence(this$0.co_1);
3592
3642
  // Inline function 'kotlin.sequences.fold' call
3593
3643
  var accumulator_0 = 0n;
3594
3644
  var _iterator__ex2g4s_0 = map(tmp_0, MovesInfo$moves$delegate$lambda$lambda_0).x();
@@ -3597,7 +3647,7 @@ function MovesInfo$moves$delegate$lambda(this$0) {
3597
3647
  accumulator_0 = accumulator_0 | element_0;
3598
3648
  }
3599
3649
  var nm = accumulator_0;
3600
- var tmp_1 = asSequence(this$0.co_1);
3650
+ var tmp_1 = asSequence(this$0.do_1);
3601
3651
  // Inline function 'kotlin.sequences.fold' call
3602
3652
  var accumulator_1 = 0n;
3603
3653
  var _iterator__ex2g4s_1 = map(tmp_1, MovesInfo$moves$delegate$lambda$lambda_1).x();
@@ -3606,7 +3656,7 @@ function MovesInfo$moves$delegate$lambda(this$0) {
3606
3656
  accumulator_1 = accumulator_1 | element_1;
3607
3657
  }
3608
3658
  var bm = accumulator_1;
3609
- var tmp_2 = asSequence(this$0.do_1);
3659
+ var tmp_2 = asSequence(this$0.eo_1);
3610
3660
  // Inline function 'kotlin.sequences.fold' call
3611
3661
  var accumulator_2 = 0n;
3612
3662
  var _iterator__ex2g4s_2 = map(tmp_2, MovesInfo$moves$delegate$lambda$lambda_2).x();
@@ -3615,7 +3665,7 @@ function MovesInfo$moves$delegate$lambda(this$0) {
3615
3665
  accumulator_2 = accumulator_2 | element_2;
3616
3666
  }
3617
3667
  var rm = accumulator_2;
3618
- var tmp_3 = asSequence(this$0.eo_1);
3668
+ var tmp_3 = asSequence(this$0.fo_1);
3619
3669
  // Inline function 'kotlin.sequences.fold' call
3620
3670
  var accumulator_3 = 0n;
3621
3671
  var _iterator__ex2g4s_3 = map(tmp_3, MovesInfo$moves$delegate$lambda$lambda_3).x();
@@ -3624,16 +3674,16 @@ function MovesInfo$moves$delegate$lambda(this$0) {
3624
3674
  accumulator_3 = accumulator_3 | element_3;
3625
3675
  }
3626
3676
  var qm = accumulator_3;
3627
- var km = this$0.fo_1.cn_1;
3677
+ var km = this$0.go_1.dn_1;
3628
3678
  return pm | nm | bm | rm | qm | km;
3629
3679
  };
3630
3680
  }
3631
3681
  function MovesInfo$_get_moves_$ref_54hm5y() {
3632
- return (p0) => p0.ep();
3682
+ return (p0) => p0.fp();
3633
3683
  }
3634
3684
  function MovesInfo$movesList$delegate$lambda$slambda_0(this$0) {
3635
3685
  var i = new MovesInfo$movesList$delegate$lambda$slambda(this$0);
3636
- var l = ($this$sequence, $completion) => i.gn($this$sequence, $completion);
3686
+ var l = ($this$sequence, $completion) => i.hn($this$sequence, $completion);
3637
3687
  l.$arity = 1;
3638
3688
  return l;
3639
3689
  }
@@ -3641,7 +3691,7 @@ function MovesInfo$movesList$delegate$lambda(this$0) {
3641
3691
  return () => toList(sequence(MovesInfo$movesList$delegate$lambda$slambda_0(this$0)));
3642
3692
  }
3643
3693
  function MovesInfo$_get_movesList_$ref_o79khg() {
3644
- return (p0) => p0.fp();
3694
+ return (p0) => p0.gp();
3645
3695
  }
3646
3696
  var Notation_UCI_instance;
3647
3697
  var Notation_SAN_instance;
@@ -3689,30 +3739,30 @@ function Companion_getInstance_3() {
3689
3739
  return Companion_instance_3;
3690
3740
  }
3691
3741
  function parseGame($this, idSupplier) {
3692
- if (!$this.pp_1.lp_1.equals(TokenType_LBRACKET_getInstance())) {
3693
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedPgn($this)));
3742
+ if (!$this.qp_1.mp_1.equals(TokenType_LBRACKET_getInstance())) {
3743
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedPgn($this)));
3694
3744
  }
3695
- while ($this.pp_1.lp_1.equals(TokenType_LBRACKET_getInstance())) {
3745
+ while ($this.qp_1.mp_1.equals(TokenType_LBRACKET_getInstance())) {
3696
3746
  parseTag($this);
3697
3747
  }
3698
- $this.rp_1 = customGame(GameMode_ANALYSIS_getInstance(), ThreeRepetitionsMode_AWARE_getInstance(), FiftyMovesRuleMode_AWARE_getInstance(), null, $this.qp_1, idSupplier);
3699
- var tmp0_safe_receiver = $this.rp_1;
3748
+ $this.sp_1 = customGame(GameMode_ANALYSIS_getInstance(), ThreeRepetitionsMode_AWARE_getInstance(), FiftyMovesRuleMode_AWARE_getInstance(), null, $this.rp_1, idSupplier);
3749
+ var tmp0_safe_receiver = $this.sp_1;
3700
3750
  var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.wj_1;
3701
3751
  var tmp;
3702
3752
  if (tmp1_elvis_lhs == null) {
3703
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp("current game can't be null"));
3753
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp("current game can't be null"));
3704
3754
  } else {
3705
3755
  tmp = tmp1_elvis_lhs;
3706
3756
  }
3707
3757
  parseMoves($this, tmp);
3708
- if ($this.pp_1.lp_1.equals(TokenType_RESULT_getInstance())) {
3709
- var tmp2_safe_receiver = $this.rp_1;
3758
+ if ($this.qp_1.mp_1.equals(TokenType_RESULT_getInstance())) {
3759
+ var tmp2_safe_receiver = $this.sp_1;
3710
3760
  if (tmp2_safe_receiver == null)
3711
3761
  null;
3712
3762
  else {
3713
3763
  // Inline function 'kotlin.apply' call
3714
3764
  var tmp_0;
3715
- switch ($this.pp_1.mp_1) {
3765
+ switch ($this.qp_1.np_1) {
3716
3766
  case '1-0':
3717
3767
  tmp_0 = Result_WHITE_WIN_getInstance();
3718
3768
  break;
@@ -3723,80 +3773,80 @@ function parseGame($this, idSupplier) {
3723
3773
  tmp_0 = Result_DRAW_getInstance();
3724
3774
  break;
3725
3775
  default:
3726
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedPgn($this)));
3776
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedPgn($this)));
3727
3777
  }
3728
- tmp2_safe_receiver.mm(tmp_0);
3778
+ tmp2_safe_receiver.nm(tmp_0);
3729
3779
  }
3730
- } else if ($this.pp_1.lp_1.equals(TokenType_STAR_getInstance())) {
3731
- var tmp3_safe_receiver = $this.rp_1;
3780
+ } else if ($this.qp_1.mp_1.equals(TokenType_STAR_getInstance())) {
3781
+ var tmp3_safe_receiver = $this.sp_1;
3732
3782
  if (tmp3_safe_receiver == null)
3733
3783
  null;
3734
3784
  else {
3735
3785
  // Inline function 'kotlin.apply' call
3736
- tmp3_safe_receiver.mm(null);
3786
+ tmp3_safe_receiver.nm(null);
3737
3787
  }
3738
3788
  }
3739
- var tmp4_safe_receiver = $this.rp_1;
3789
+ var tmp4_safe_receiver = $this.sp_1;
3740
3790
  if (tmp4_safe_receiver == null)
3741
3791
  null;
3742
3792
  else {
3743
3793
  // Inline function 'kotlin.let' call
3744
- tmp4_safe_receiver.sl();
3745
- $this.tp_1.k(tmp4_safe_receiver);
3794
+ tmp4_safe_receiver.tl();
3795
+ $this.up_1.k(tmp4_safe_receiver);
3746
3796
  }
3747
3797
  reset($this);
3748
3798
  }
3749
3799
  function reset($this) {
3750
- $this.rp_1 = null;
3800
+ $this.sp_1 = null;
3751
3801
  var tmp = $this;
3752
3802
  // Inline function 'kotlin.collections.mutableMapOf' call
3753
- tmp.qp_1 = LinkedHashMap.v8();
3803
+ tmp.rp_1 = LinkedHashMap.v8();
3754
3804
  }
3755
3805
  function malformedPgn($this) {
3756
- return 'malformed pgn at line ' + $this.pp_1.np_1 + ' token ' + $this.pp_1.mp_1;
3806
+ return 'malformed pgn at line ' + $this.qp_1.op_1 + ' token ' + $this.qp_1.np_1;
3757
3807
  }
3758
3808
  function nextTokenOrFail($this, failMsg) {
3759
3809
  var tmp;
3760
- if ($this.sp_1.z()) {
3761
- tmp = $this.sp_1.a1();
3810
+ if ($this.tp_1.z()) {
3811
+ tmp = $this.tp_1.a1();
3762
3812
  } else {
3763
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(failMsg));
3813
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(failMsg));
3764
3814
  }
3765
3815
  return tmp;
3766
3816
  }
3767
3817
  function malformedTag($this) {
3768
- return 'malformed tag at line ' + $this.pp_1.np_1 + ' token ' + $this.pp_1.mp_1;
3818
+ return 'malformed tag at line ' + $this.qp_1.op_1 + ' token ' + $this.qp_1.np_1;
3769
3819
  }
3770
3820
  function parseTag($this) {
3771
- $this.pp_1 = nextTokenOrFail($this, malformedTag($this));
3772
- if (!$this.pp_1.lp_1.equals(TokenType_SYMBOL_getInstance())) {
3773
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedTag($this)));
3821
+ $this.qp_1 = nextTokenOrFail($this, malformedTag($this));
3822
+ if (!$this.qp_1.mp_1.equals(TokenType_SYMBOL_getInstance())) {
3823
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedTag($this)));
3774
3824
  }
3775
3825
  // Inline function 'kotlin.text.lowercase' call
3776
3826
  // Inline function 'kotlin.js.asDynamic' call
3777
- var tagName = $this.pp_1.mp_1.toLowerCase();
3827
+ var tagName = $this.qp_1.np_1.toLowerCase();
3778
3828
  if (tagName === 'eco') {
3779
3829
  tagName = 'ECO';
3780
3830
  }
3781
- $this.pp_1 = nextTokenOrFail($this, malformedTag($this));
3782
- if (!$this.pp_1.lp_1.equals(TokenType_STRING_getInstance())) {
3783
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedTag($this)));
3831
+ $this.qp_1 = nextTokenOrFail($this, malformedTag($this));
3832
+ if (!$this.qp_1.mp_1.equals(TokenType_STRING_getInstance())) {
3833
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedTag($this)));
3784
3834
  }
3785
- var tagValue = $this.pp_1.mp_1;
3786
- var tmp0 = $this.qp_1;
3835
+ var tagValue = $this.qp_1.np_1;
3836
+ var tmp0 = $this.rp_1;
3787
3837
  // Inline function 'kotlin.collections.set' call
3788
3838
  var key = tagName;
3789
3839
  tmp0.f5(key, tagValue);
3790
- $this.pp_1 = nextTokenOrFail($this, malformedTag($this));
3791
- if ($this.pp_1.lp_1.equals(TokenType_RBRACKET_getInstance())) {
3792
- $this.pp_1 = nextTokenOrFail($this, malformedTag($this));
3840
+ $this.qp_1 = nextTokenOrFail($this, malformedTag($this));
3841
+ if ($this.qp_1.mp_1.equals(TokenType_RBRACKET_getInstance())) {
3842
+ $this.qp_1 = nextTokenOrFail($this, malformedTag($this));
3793
3843
  return Unit_instance;
3794
3844
  } else {
3795
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedTag($this)));
3845
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedTag($this)));
3796
3846
  }
3797
3847
  }
3798
3848
  function malformedMoveText($this) {
3799
- return 'malformed move text at line ' + $this.pp_1.np_1 + ' token ' + $this.pp_1.toString();
3849
+ return 'malformed move text at line ' + $this.qp_1.op_1 + ' token ' + $this.qp_1.toString();
3800
3850
  }
3801
3851
  function parseMoves($this, node) {
3802
3852
  var move = null;
@@ -3805,12 +3855,12 @@ function parseMoves($this, node) {
3805
3855
  var endLineComment = null;
3806
3856
  // Inline function 'kotlin.collections.mutableListOf' call
3807
3857
  var suffixAnnotations = ArrayList.h1();
3808
- if ($this.pp_1.lp_1.equals(TokenType_LPAREN_getInstance())) {
3809
- $this.pp_1 = nextTokenOrFail($this, malformedMoveText($this));
3858
+ if ($this.qp_1.mp_1.equals(TokenType_LPAREN_getInstance())) {
3859
+ $this.qp_1 = nextTokenOrFail($this, malformedMoveText($this));
3810
3860
  var tmp0_elvis_lhs = node.aj();
3811
3861
  var tmp;
3812
3862
  if (tmp0_elvis_lhs == null) {
3813
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp('node ' + toString_0(node.rk()) + ' has no parent'));
3863
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp('node ' + toString_0(node.rk()) + ' has no parent'));
3814
3864
  } else {
3815
3865
  tmp = tmp0_elvis_lhs;
3816
3866
  }
@@ -3818,45 +3868,45 @@ function parseMoves($this, node) {
3818
3868
  }
3819
3869
  while (move == null) {
3820
3870
  var tokenCounter = 0;
3821
- switch ($this.pp_1.lp_1.m2_1) {
3871
+ switch ($this.qp_1.mp_1.m2_1) {
3822
3872
  case 10:
3823
3873
  break;
3824
3874
  case 4:
3825
3875
  break;
3826
3876
  case 11:
3827
- initialComment = $this.pp_1.mp_1;
3877
+ initialComment = $this.qp_1.np_1;
3828
3878
  break;
3829
3879
  case 9:
3830
- move = $this.pp_1.mp_1;
3880
+ move = $this.qp_1.np_1;
3831
3881
  break;
3832
3882
  default:
3833
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedMoveText($this)));
3883
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedMoveText($this)));
3834
3884
  }
3835
- $this.pp_1 = nextTokenOrFail($this, malformedMoveText($this));
3885
+ $this.qp_1 = nextTokenOrFail($this, malformedMoveText($this));
3836
3886
  tokenCounter = tokenCounter + 1 | 0;
3837
3887
  if (tokenCounter > 10) {
3838
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedMoveText($this)));
3888
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedMoveText($this)));
3839
3889
  }
3840
3890
  }
3841
- $l$loop_0: while (!$this.pp_1.lp_1.equals(TokenType_INTEGER_getInstance()) && !$this.pp_1.lp_1.equals(TokenType_SYMBOL_getInstance()) && !$this.pp_1.lp_1.equals(TokenType_RESULT_getInstance()) && !$this.pp_1.lp_1.equals(TokenType_STAR_getInstance())) {
3842
- switch ($this.pp_1.lp_1.m2_1) {
3891
+ $l$loop_0: while (!$this.qp_1.mp_1.equals(TokenType_INTEGER_getInstance()) && !$this.qp_1.mp_1.equals(TokenType_SYMBOL_getInstance()) && !$this.qp_1.mp_1.equals(TokenType_RESULT_getInstance()) && !$this.qp_1.mp_1.equals(TokenType_STAR_getInstance())) {
3892
+ switch ($this.qp_1.mp_1.m2_1) {
3843
3893
  case 11:
3844
- comment = $this.pp_1.mp_1;
3894
+ comment = $this.qp_1.np_1;
3845
3895
  break;
3846
3896
  case 12:
3847
- endLineComment = $this.pp_1.mp_1;
3897
+ endLineComment = $this.qp_1.np_1;
3848
3898
  break;
3849
3899
  case 5:
3850
- suffixAnnotations.k(toInt($this.pp_1.mp_1));
3900
+ suffixAnnotations.k(toInt($this.qp_1.np_1));
3851
3901
  break;
3852
3902
  case 2:
3853
3903
  break $l$loop_0;
3854
3904
  case 3:
3855
3905
  break $l$loop_0;
3856
3906
  default:
3857
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedMoveText($this)));
3907
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedMoveText($this)));
3858
3908
  }
3859
- $this.pp_1 = nextTokenOrFail($this, malformedMoveText($this));
3909
+ $this.qp_1 = nextTokenOrFail($this, malformedMoveText($this));
3860
3910
  }
3861
3911
  var tmp_0 = move;
3862
3912
  var tmp_1 = initialComment;
@@ -3872,7 +3922,7 @@ function parseMoves($this, node) {
3872
3922
  var tmp$ret$2 = tmp_4;
3873
3923
  var nextNode = node.wk(tmp_0, tmp_1, tmp_2, tmp_3, tmp$ret$2);
3874
3924
  var tmp_5;
3875
- switch ($this.pp_1.lp_1.m2_1) {
3925
+ switch ($this.qp_1.mp_1.m2_1) {
3876
3926
  case 10:
3877
3927
  tmp_5 = parseMoves($this, nextNode);
3878
3928
  break;
@@ -3880,12 +3930,12 @@ function parseMoves($this, node) {
3880
3930
  tmp_5 = parseMoves($this, nextNode);
3881
3931
  break;
3882
3932
  case 2:
3883
- $this.pp_1 = nextTokenOrFail($this, malformedMoveText($this));
3933
+ $this.qp_1 = nextTokenOrFail($this, malformedMoveText($this));
3884
3934
  parseMoves($this, node);
3885
3935
  tmp_5 = parseMoves($this, nextNode);
3886
3936
  break;
3887
3937
  case 3:
3888
- $this.pp_1 = nextTokenOrFail($this, malformedMoveText($this));
3938
+ $this.qp_1 = nextTokenOrFail($this, malformedMoveText($this));
3889
3939
  return nextNode;
3890
3940
  case 7:
3891
3941
  tmp_5 = nextNode;
@@ -3894,21 +3944,21 @@ function parseMoves($this, node) {
3894
3944
  tmp_5 = nextNode;
3895
3945
  break;
3896
3946
  default:
3897
- throw Companion_getInstance_3().gp_1.xl(ParserException.kp(malformedMoveText($this)));
3947
+ throw Companion_getInstance_3().hp_1.yl(ParserException.lp(malformedMoveText($this)));
3898
3948
  }
3899
3949
  return tmp_5;
3900
3950
  }
3901
3951
  function *_generator_invoke__zhh2q8_1($this, $this$sequence, $completion) {
3902
- var tmp = $this$sequence.wd($this.vp_1.en(), $completion);
3952
+ var tmp = $this$sequence.wd($this.wp_1.fn(), $completion);
3903
3953
  if (tmp === get_COROUTINE_SUSPENDED())
3904
3954
  tmp = yield tmp;
3905
- var tmp_0 = $this$sequence.wd($this.vp_1.wp(), $completion);
3955
+ var tmp_0 = $this$sequence.wd($this.wp_1.xp(), $completion);
3906
3956
  if (tmp_0 === get_COROUTINE_SUSPENDED())
3907
3957
  tmp_0 = yield tmp_0;
3908
- var tmp_1 = $this$sequence.wd($this.vp_1.xp(), $completion);
3958
+ var tmp_1 = $this$sequence.wd($this.wp_1.yp(), $completion);
3909
3959
  if (tmp_1 === get_COROUTINE_SUSPENDED())
3910
3960
  tmp_1 = yield tmp_1;
3911
- var tmp0_safe_receiver = $this.vp_1.yp();
3961
+ var tmp0_safe_receiver = $this.wp_1.zp();
3912
3962
  if (tmp0_safe_receiver == null)
3913
3963
  null;
3914
3964
  else {
@@ -3920,47 +3970,47 @@ function *_generator_invoke__zhh2q8_1($this, $this$sequence, $completion) {
3920
3970
  return Unit_instance;
3921
3971
  }
3922
3972
  function PawnMoves$regularMovesList$delegate$lambda$lambda(this$0) {
3923
- return (it) => this$0.qo_1(this$0.ko_1, countTrailingZeroBits(it));
3973
+ return (it) => this$0.ro_1(this$0.lo_1, countTrailingZeroBits(it));
3924
3974
  }
3925
3975
  function PawnMoves$regularMovesList$delegate$lambda(this$0) {
3926
- return () => bitboardToList(this$0.mo_1, PawnMoves$regularMovesList$delegate$lambda$lambda(this$0));
3976
+ return () => bitboardToList(this$0.no_1, PawnMoves$regularMovesList$delegate$lambda$lambda(this$0));
3927
3977
  }
3928
3978
  function PawnMoves$_get_regularMovesList_$ref_qve2sg() {
3929
- return (p0) => p0.en();
3979
+ return (p0) => p0.fn();
3930
3980
  }
3931
3981
  function PawnMoves$advanceEpMovesList$delegate$lambda$lambda(this$0) {
3932
- return (it) => this$0.qo_1(this$0.ko_1, countTrailingZeroBits(it));
3982
+ return (it) => this$0.ro_1(this$0.lo_1, countTrailingZeroBits(it));
3933
3983
  }
3934
3984
  function PawnMoves$advanceEpMovesList$delegate$lambda(this$0) {
3935
- return () => bitboardToList(this$0.no_1, PawnMoves$advanceEpMovesList$delegate$lambda$lambda(this$0));
3985
+ return () => bitboardToList(this$0.oo_1, PawnMoves$advanceEpMovesList$delegate$lambda$lambda(this$0));
3936
3986
  }
3937
3987
  function PawnMoves$_get_advanceEpMovesList_$ref_k5ega7() {
3938
- return (p0) => p0.wp();
3988
+ return (p0) => p0.xp();
3939
3989
  }
3940
3990
  function PawnMoves$promotionMovesList$delegate$lambda$lambda$lambda(this$0, $move) {
3941
- return (it) => this$0.ro_1(this$0.ko_1, countTrailingZeroBits($move), it.m2_1);
3991
+ return (it) => this$0.so_1(this$0.lo_1, countTrailingZeroBits($move), it.m2_1);
3942
3992
  }
3943
3993
  function PawnMoves$promotionMovesList$delegate$lambda$lambda(this$0) {
3944
3994
  return (move) => {
3945
- var tmp = this$0.jo_1 === Piece_WP_getInstance().m2_1 ? sequenceOf([Piece_WQ_getInstance(), Piece_WR_getInstance(), Piece_WB_getInstance(), Piece_WN_getInstance()]) : sequenceOf([Piece_BQ_getInstance(), Piece_BR_getInstance(), Piece_BB_getInstance(), Piece_BN_getInstance()]);
3995
+ var tmp = this$0.ko_1 === Piece_WP_getInstance().m2_1 ? sequenceOf([Piece_WQ_getInstance(), Piece_WR_getInstance(), Piece_WB_getInstance(), Piece_WN_getInstance()]) : sequenceOf([Piece_BQ_getInstance(), Piece_BR_getInstance(), Piece_BB_getInstance(), Piece_BN_getInstance()]);
3946
3996
  return toList(map(tmp, PawnMoves$promotionMovesList$delegate$lambda$lambda$lambda(this$0, move)));
3947
3997
  };
3948
3998
  }
3949
3999
  function PawnMoves$promotionMovesList$delegate$lambda(this$0) {
3950
- return () => bitboardToCollectedList(this$0.oo_1, PawnMoves$promotionMovesList$delegate$lambda$lambda(this$0));
4000
+ return () => bitboardToCollectedList(this$0.po_1, PawnMoves$promotionMovesList$delegate$lambda$lambda(this$0));
3951
4001
  }
3952
4002
  function PawnMoves$_get_promotionMovesList_$ref_pb8487() {
3953
- return (p0) => p0.xp();
4003
+ return (p0) => p0.yp();
3954
4004
  }
3955
4005
  function PawnMoves$epCaptureMove$delegate$lambda(this$0) {
3956
- return () => !(this$0.po_1 === 0n) ? moveOf(this$0.ko_1, countTrailingZeroBits(this$0.po_1)) : null;
4006
+ return () => !(this$0.qo_1 === 0n) ? moveOf(this$0.lo_1, countTrailingZeroBits(this$0.qo_1)) : null;
3957
4007
  }
3958
4008
  function PawnMoves$_get_epCaptureMove_$ref_4vz7gq() {
3959
- return (p0) => p0.yp();
4009
+ return (p0) => p0.zp();
3960
4010
  }
3961
4011
  function PawnMoves$allMovesList$delegate$lambda$slambda_0(this$0) {
3962
4012
  var i = new PawnMoves$allMovesList$delegate$lambda$slambda(this$0);
3963
- var l = ($this$sequence, $completion) => i.gn($this$sequence, $completion);
4013
+ var l = ($this$sequence, $completion) => i.hn($this$sequence, $completion);
3964
4014
  l.$arity = 1;
3965
4015
  return l;
3966
4016
  }
@@ -3968,7 +4018,7 @@ function PawnMoves$allMovesList$delegate$lambda(this$0) {
3968
4018
  return () => toList(sequence(PawnMoves$allMovesList$delegate$lambda$slambda_0(this$0)));
3969
4019
  }
3970
4020
  function PawnMoves$_get_allMovesList_$ref_s0vg9x() {
3971
- return (p0) => p0.hn();
4021
+ return (p0) => p0.in();
3972
4022
  }
3973
4023
  var Piece_EMPTY_instance;
3974
4024
  var Piece_WP_instance;
@@ -4115,46 +4165,46 @@ function _get_moves__e5my0h($this) {
4115
4165
  return tmp0.h2();
4116
4166
  }
4117
4167
  function Position$moves$delegate$lambda(this$0) {
4118
- return () => this$0.dq().ep();
4168
+ return () => this$0.eq().fp();
4119
4169
  }
4120
4170
  function Position$_get_moves_$ref_1wr6hp() {
4121
4171
  return (p0) => _get_moves__e5my0h(p0);
4122
4172
  }
4123
4173
  function Position$check$delegate$lambda(this$0) {
4124
- return () => inCheck(this$0.eq(), this$0.fj_1);
4174
+ return () => inCheck(this$0.fq(), this$0.fj_1);
4125
4175
  }
4126
4176
  function Position$_get_check_$ref_tp97h() {
4127
- return (p0) => p0.fq();
4177
+ return (p0) => p0.gq();
4128
4178
  }
4129
4179
  function Position$checkmate$delegate$lambda(this$0) {
4130
- return () => isCheckmate(this$0.eq(), this$0.fj_1, _get_moves__e5my0h(this$0));
4180
+ return () => isCheckmate(this$0.fq(), this$0.fj_1, _get_moves__e5my0h(this$0));
4131
4181
  }
4132
4182
  function Position$_get_checkmate_$ref_mwt4hk() {
4133
- return (p0) => p0.gq();
4183
+ return (p0) => p0.hq();
4134
4184
  }
4135
4185
  function Position$stalemate$delegate$lambda(this$0) {
4136
- return () => isStalemate(this$0.eq(), this$0.fj_1, _get_moves__e5my0h(this$0));
4186
+ return () => isStalemate(this$0.fq(), this$0.fj_1, _get_moves__e5my0h(this$0));
4137
4187
  }
4138
4188
  function Position$_get_stalemate_$ref_l6lqf() {
4139
- return (p0) => p0.hq();
4189
+ return (p0) => p0.iq();
4140
4190
  }
4141
4191
  function Position$lackOfMaterial$delegate$lambda(this$0) {
4142
- return () => isLackOfMaterial(this$0.eq());
4192
+ return () => isLackOfMaterial(this$0.fq());
4143
4193
  }
4144
4194
  function Position$_get_lackOfMaterial_$ref_whrjuu() {
4145
- return (p0) => p0.iq();
4195
+ return (p0) => p0.jq();
4146
4196
  }
4147
4197
  function Position$fiftyMoves$delegate$lambda(this$0) {
4148
4198
  return () => this$0.mj_1 >= 50;
4149
4199
  }
4150
4200
  function Position$_get_fiftyMoves_$ref_ima66z() {
4151
- return (p0) => p0.rm();
4201
+ return (p0) => p0.sm();
4152
4202
  }
4153
4203
  function Position$zobrist$delegate$lambda(this$0) {
4154
- return () => get_computeZobristHash()(this$0.eq(), this$0.fj_1, this$0.hj_1, this$0.ij_1, this$0.jj_1, this$0.kj_1, this$0.gj_1);
4204
+ return () => get_computeZobristHash()(this$0.fq(), this$0.fj_1, this$0.hj_1, this$0.ij_1, this$0.jj_1, this$0.kj_1, this$0.gj_1);
4155
4205
  }
4156
4206
  function Position$_get_zobrist_$ref_t8al0g() {
4157
- return (p0) => p0.jq();
4207
+ return (p0) => p0.kq();
4158
4208
  }
4159
4209
  function init_io_github_lunalobos_chess4kt_Position(_this__u8e3s4) {
4160
4210
  Companion_getInstance_5();
@@ -4174,13 +4224,13 @@ function init_io_github_lunalobos_chess4kt_Position(_this__u8e3s4) {
4174
4224
  tmp_5.tj_1 = lazy(Position$zobrist$delegate$lambda(_this__u8e3s4));
4175
4225
  }
4176
4226
  function RegularPieceMoves$allMovesList$delegate$lambda$lambda(this$0) {
4177
- return (it) => this$0.cp_1(this$0.zo_1, countTrailingZeroBits(it));
4227
+ return (it) => this$0.dp_1(this$0.ap_1, countTrailingZeroBits(it));
4178
4228
  }
4179
4229
  function RegularPieceMoves$allMovesList$delegate$lambda(this$0) {
4180
- return () => bitboardToList(this$0.bp_1, RegularPieceMoves$allMovesList$delegate$lambda$lambda(this$0));
4230
+ return () => bitboardToList(this$0.cp_1, RegularPieceMoves$allMovesList$delegate$lambda$lambda(this$0));
4181
4231
  }
4182
4232
  function RegularPieceMoves$_get_allMovesList_$ref_ts1d8v() {
4183
- return (p0) => p0.hn();
4233
+ return (p0) => p0.in();
4184
4234
  }
4185
4235
  var Side_WHITE_instance;
4186
4236
  var Side_BLACK_instance;
@@ -4843,36 +4893,36 @@ function addToken($this, type, value) {
4843
4893
  var tmp;
4844
4894
  // Inline function 'kotlin.text.isEmpty' call
4845
4895
  if (charSequenceLength(value) === 0) {
4846
- tmp = toString_1(charCodeAt($this.pq_1, $this.qq_1));
4896
+ tmp = toString_1(charCodeAt($this.qq_1, $this.rq_1));
4847
4897
  } else {
4848
4898
  tmp = value;
4849
4899
  }
4850
4900
  var tmp$ret$2 = tmp;
4851
- $this.sq_1.k(new Token(type, tmp$ret$2, $this.rq_1));
4852
- $this.qq_1 = $this.qq_1 + 1 | 0;
4901
+ $this.tq_1.k(new Token(type, tmp$ret$2, $this.sq_1));
4902
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4853
4903
  }
4854
4904
  function addToken$default($this, type, value, $super) {
4855
4905
  value = value === VOID ? '' : value;
4856
4906
  return addToken($this, type, value);
4857
4907
  }
4858
4908
  function consumeWhitespace($this) {
4859
- while ($this.qq_1 < $this.pq_1.length && isWhitespace(charCodeAt($this.pq_1, $this.qq_1))) {
4860
- if (charCodeAt($this.pq_1, $this.qq_1) === _Char___init__impl__6a9atx(10)) {
4861
- $this.rq_1 = $this.rq_1 + 1 | 0;
4909
+ while ($this.rq_1 < $this.qq_1.length && isWhitespace(charCodeAt($this.qq_1, $this.rq_1))) {
4910
+ if (charCodeAt($this.qq_1, $this.rq_1) === _Char___init__impl__6a9atx(10)) {
4911
+ $this.sq_1 = $this.sq_1 + 1 | 0;
4862
4912
  }
4863
- $this.qq_1 = $this.qq_1 + 1 | 0;
4913
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4864
4914
  }
4865
4915
  }
4866
4916
  function consumeString($this) {
4867
- $this.qq_1 = $this.qq_1 + 1 | 0;
4868
- var start = $this.qq_1;
4917
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4918
+ var start = $this.rq_1;
4869
4919
  var value = '';
4870
- while ($this.qq_1 < $this.pq_1.length) {
4871
- var char = charCodeAt($this.pq_1, $this.qq_1);
4920
+ while ($this.rq_1 < $this.qq_1.length) {
4921
+ var char = charCodeAt($this.qq_1, $this.rq_1);
4872
4922
  if (char === _Char___init__impl__6a9atx(34)) {
4873
- value = substring_0($this.pq_1, start, $this.qq_1);
4874
- $this.qq_1 = $this.qq_1 + 1 | 0;
4875
- $this.sq_1.k(new Token(TokenType_STRING_getInstance(), value, $this.rq_1));
4923
+ value = substring_0($this.qq_1, start, $this.rq_1);
4924
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4925
+ $this.tq_1.k(new Token(TokenType_STRING_getInstance(), value, $this.sq_1));
4876
4926
  return Unit_instance;
4877
4927
  }
4878
4928
  var tmp;
@@ -4884,76 +4934,76 @@ function consumeString($this) {
4884
4934
  }
4885
4935
  if (tmp) {
4886
4936
  if (char === _Char___init__impl__6a9atx(10)) {
4887
- $this.rq_1 = $this.rq_1 + 1 | 0;
4937
+ $this.sq_1 = $this.sq_1 + 1 | 0;
4888
4938
  }
4889
4939
  }
4890
- $this.qq_1 = $this.qq_1 + 1 | 0;
4940
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4891
4941
  }
4892
- throw ParserException.kp('Unclosed string literal.');
4942
+ throw ParserException.lp('Unclosed string literal.');
4893
4943
  }
4894
4944
  function consumeBraceComment($this) {
4895
- var start = $this.qq_1;
4896
- $this.qq_1 = $this.qq_1 + 1 | 0;
4897
- while ($this.qq_1 < $this.pq_1.length && !(charCodeAt($this.pq_1, $this.qq_1) === _Char___init__impl__6a9atx(125))) {
4898
- if (charCodeAt($this.pq_1, $this.qq_1) === _Char___init__impl__6a9atx(10)) {
4899
- $this.rq_1 = $this.rq_1 + 1 | 0;
4945
+ var start = $this.rq_1;
4946
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4947
+ while ($this.rq_1 < $this.qq_1.length && !(charCodeAt($this.qq_1, $this.rq_1) === _Char___init__impl__6a9atx(125))) {
4948
+ if (charCodeAt($this.qq_1, $this.rq_1) === _Char___init__impl__6a9atx(10)) {
4949
+ $this.sq_1 = $this.sq_1 + 1 | 0;
4900
4950
  }
4901
- $this.qq_1 = $this.qq_1 + 1 | 0;
4951
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4902
4952
  }
4903
- if ($this.qq_1 < $this.pq_1.length) {
4904
- $this.qq_1 = $this.qq_1 + 1 | 0;
4953
+ if ($this.rq_1 < $this.qq_1.length) {
4954
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4905
4955
  }
4906
4956
  var tmp = TokenType_COMMENT_getInstance();
4907
4957
  // Inline function 'kotlin.text.trim' call
4908
- var this_0 = substring_0($this.pq_1, start + 1 | 0, ($this.qq_1 - 1 | 0) >= (start + 1 | 0) ? $this.qq_1 - 1 | 0 : start + 1 | 0);
4958
+ var this_0 = substring_0($this.qq_1, start + 1 | 0, ($this.rq_1 - 1 | 0) >= (start + 1 | 0) ? $this.rq_1 - 1 | 0 : start + 1 | 0);
4909
4959
  var tmp$ret$0 = toString(trim(isCharSequence(this_0) ? this_0 : THROW_CCE()));
4910
- $this.sq_1.k(new Token(tmp, tmp$ret$0, $this.rq_1));
4960
+ $this.tq_1.k(new Token(tmp, tmp$ret$0, $this.sq_1));
4911
4961
  }
4912
4962
  function consumeSemicolonComment($this) {
4913
- var start = $this.qq_1;
4914
- while ($this.qq_1 < $this.pq_1.length && !(charCodeAt($this.pq_1, $this.qq_1) === _Char___init__impl__6a9atx(10)) && !(charCodeAt($this.pq_1, $this.qq_1) === _Char___init__impl__6a9atx(13))) {
4915
- $this.qq_1 = $this.qq_1 + 1 | 0;
4963
+ var start = $this.rq_1;
4964
+ while ($this.rq_1 < $this.qq_1.length && !(charCodeAt($this.qq_1, $this.rq_1) === _Char___init__impl__6a9atx(10)) && !(charCodeAt($this.qq_1, $this.rq_1) === _Char___init__impl__6a9atx(13))) {
4965
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4916
4966
  }
4917
4967
  var tmp = TokenType_END_LINE_COMMENT_getInstance();
4918
4968
  // Inline function 'kotlin.text.trim' call
4919
- var this_0 = substring_0($this.pq_1, start + 1 | 0, $this.qq_1 - 1 | 0);
4969
+ var this_0 = substring_0($this.qq_1, start + 1 | 0, $this.rq_1 - 1 | 0);
4920
4970
  var tmp$ret$0 = toString(trim(isCharSequence(this_0) ? this_0 : THROW_CCE()));
4921
- $this.sq_1.k(new Token(tmp, tmp$ret$0, $this.rq_1));
4971
+ $this.tq_1.k(new Token(tmp, tmp$ret$0, $this.sq_1));
4922
4972
  }
4923
4973
  function consumeNAG($this) {
4924
- $this.qq_1 = $this.qq_1 + 1 | 0;
4925
- var start = $this.qq_1;
4926
- while ($this.qq_1 < $this.pq_1.length && isDigit(charCodeAt($this.pq_1, $this.qq_1))) {
4927
- $this.qq_1 = $this.qq_1 + 1 | 0;
4974
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4975
+ var start = $this.rq_1;
4976
+ while ($this.rq_1 < $this.qq_1.length && isDigit(charCodeAt($this.qq_1, $this.rq_1))) {
4977
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4928
4978
  }
4929
- $this.sq_1.k(new Token(TokenType_NAG_getInstance(), substring_0($this.pq_1, start, $this.qq_1), $this.rq_1));
4979
+ $this.tq_1.k(new Token(TokenType_NAG_getInstance(), substring_0($this.qq_1, start, $this.rq_1), $this.sq_1));
4930
4980
  }
4931
4981
  function consumeNumberOrSymbol($this) {
4932
- var start = $this.qq_1;
4933
- var currentPos = $this.qq_1;
4934
- while (currentPos < $this.pq_1.length && isDigit(charCodeAt($this.pq_1, currentPos))) {
4982
+ var start = $this.rq_1;
4983
+ var currentPos = $this.rq_1;
4984
+ while (currentPos < $this.qq_1.length && isDigit(charCodeAt($this.qq_1, currentPos))) {
4935
4985
  currentPos = currentPos + 1 | 0;
4936
4986
  }
4937
- if (currentPos < $this.pq_1.length && charCodeAt($this.pq_1, currentPos) === _Char___init__impl__6a9atx(46)) {
4938
- $this.qq_1 = currentPos;
4939
- $this.sq_1.k(new Token(TokenType_INTEGER_getInstance(), substring_0($this.pq_1, start, $this.qq_1), $this.rq_1));
4987
+ if (currentPos < $this.qq_1.length && charCodeAt($this.qq_1, currentPos) === _Char___init__impl__6a9atx(46)) {
4988
+ $this.rq_1 = currentPos;
4989
+ $this.tq_1.k(new Token(TokenType_INTEGER_getInstance(), substring_0($this.qq_1, start, $this.rq_1), $this.sq_1));
4940
4990
  } else {
4941
- $this.qq_1 = start;
4991
+ $this.rq_1 = start;
4942
4992
  consumeSymbol($this);
4943
4993
  }
4944
4994
  }
4945
4995
  function consumeSymbol($this) {
4946
- var start = $this.qq_1;
4947
- $l$loop: while ($this.qq_1 < $this.pq_1.length) {
4948
- var char = charCodeAt($this.pq_1, $this.qq_1);
4996
+ var start = $this.rq_1;
4997
+ $l$loop: while ($this.rq_1 < $this.qq_1.length) {
4998
+ var char = charCodeAt($this.qq_1, $this.rq_1);
4949
4999
  var isSymbolContinuation = isLetterOrDigit(char) || char === _Char___init__impl__6a9atx(95) || char === _Char___init__impl__6a9atx(43) || char === _Char___init__impl__6a9atx(35) || char === _Char___init__impl__6a9atx(61) || char === _Char___init__impl__6a9atx(58) || char === _Char___init__impl__6a9atx(45) || char === _Char___init__impl__6a9atx(47);
4950
5000
  if (isSymbolContinuation) {
4951
- $this.qq_1 = $this.qq_1 + 1 | 0;
5001
+ $this.rq_1 = $this.rq_1 + 1 | 0;
4952
5002
  } else {
4953
5003
  break $l$loop;
4954
5004
  }
4955
5005
  }
4956
- var value = substring_0($this.pq_1, start, $this.qq_1);
5006
+ var value = substring_0($this.qq_1, start, $this.rq_1);
4957
5007
  var type;
4958
5008
  switch (value) {
4959
5009
  case '1-0':
@@ -4965,7 +5015,7 @@ function consumeSymbol($this) {
4965
5015
  type = TokenType_SYMBOL_getInstance();
4966
5016
  break;
4967
5017
  }
4968
- $this.sq_1.k(new Token(type, value, $this.rq_1));
5018
+ $this.tq_1.k(new Token(type, value, $this.sq_1));
4969
5019
  }
4970
5020
  function yieldBishopMoves(visibleSquaresBishop, moveFunction) {
4971
5021
  return yieldBishopMoves$lambda(visibleSquaresBishop, moveFunction);
@@ -5568,7 +5618,7 @@ function strictMatch(idSupplier) {
5568
5618
  _init_properties_factory_kt__5kmpyw();
5569
5619
  // Inline function 'kotlin.collections.mutableMapOf' call
5570
5620
  var tmp$ret$0 = LinkedHashMap.v8();
5571
- return Game.qm(tmp$ret$0, GameMode_MATCH_getInstance(), ThreeRepetitionsMode_STRICT_getInstance(), FiftyMovesRuleMode_STRICT_getInstance(), idSupplier);
5621
+ return Game.rm(tmp$ret$0, GameMode_MATCH_getInstance(), ThreeRepetitionsMode_STRICT_getInstance(), FiftyMovesRuleMode_STRICT_getInstance(), idSupplier);
5572
5622
  }
5573
5623
  function analysisGame(idSupplier) {
5574
5624
  var tmp;
@@ -5581,7 +5631,7 @@ function analysisGame(idSupplier) {
5581
5631
  _init_properties_factory_kt__5kmpyw();
5582
5632
  // Inline function 'kotlin.collections.mutableMapOf' call
5583
5633
  var tmp$ret$0 = LinkedHashMap.v8();
5584
- return Game.qm(tmp$ret$0, GameMode_ANALYSIS_getInstance(), ThreeRepetitionsMode_AWARE_getInstance(), FiftyMovesRuleMode_AWARE_getInstance(), idSupplier);
5634
+ return Game.rm(tmp$ret$0, GameMode_ANALYSIS_getInstance(), ThreeRepetitionsMode_AWARE_getInstance(), FiftyMovesRuleMode_AWARE_getInstance(), idSupplier);
5585
5635
  }
5586
5636
  function customGame(gameMode, threeRepetitionsMode, fiftyMovesRuleMode, initialFen, initialTags, idSupplier) {
5587
5637
  initialFen = initialFen === VOID ? null : initialFen;
@@ -5609,7 +5659,7 @@ function customGame(gameMode, threeRepetitionsMode, fiftyMovesRuleMode, initialF
5609
5659
  // Inline function 'kotlin.collections.set' call
5610
5660
  tags.f5('fen', initialFen);
5611
5661
  }
5612
- return Game.qm(tags, gameMode, threeRepetitionsMode, fiftyMovesRuleMode, idSupplier);
5662
+ return Game.rm(tags, gameMode, threeRepetitionsMode, fiftyMovesRuleMode, idSupplier);
5613
5663
  }
5614
5664
  function parseGames(pgnInput, idSupplier) {
5615
5665
  var tmp;
@@ -5621,9 +5671,9 @@ function parseGames(pgnInput, idSupplier) {
5621
5671
  idSupplier = tmp;
5622
5672
  _init_properties_factory_kt__5kmpyw();
5623
5673
  var tokenizer = new Tokenizer(pgnInput);
5624
- var tokens = tokenizer.tq();
5674
+ var tokens = tokenizer.uq();
5625
5675
  var parser = new Parser(tokens);
5626
- var games = parser.up(idSupplier);
5676
+ var games = parser.vp(idSupplier);
5627
5677
  return games;
5628
5678
  }
5629
5679
  function movesMap$lambda(it) {
@@ -5738,7 +5788,7 @@ function threats$lambda($visibleSquaresKing, $calculators, $visibleSquaresKnight
5738
5788
  }
5739
5789
  function eco$lambda(fen) {
5740
5790
  _init_properties_factory_kt__5kmpyw();
5741
- return Position.oq(fen);
5791
+ return Position.pq(fen);
5742
5792
  }
5743
5793
  function strictMatch$lambda() {
5744
5794
  _init_properties_factory_kt__5kmpyw();
@@ -5849,7 +5899,7 @@ function _init_properties_factory_kt__5kmpyw() {
5849
5899
  checkInfo = yieldCheckInfo(get_visibleSquares());
5850
5900
  checkMask = yieldCheckMask(get_visibleSquares());
5851
5901
  movesInfo = yieldMovesInfo(get_pawnMoves(), get_knightMoves(), get_bishopMoves(), get_rookMoves(), get_queenMoves(), get_kingMoves(), get_checkMask(), get_checkInfo());
5852
- startpos = Position.mq();
5902
+ startpos = Position.nq();
5853
5903
  eco = Eco.hi(eco$lambda);
5854
5904
  }
5855
5905
  }
@@ -5864,74 +5914,74 @@ function generateChildren(mi, pos) {
5864
5914
  }
5865
5915
  function pawnTuples(mi, position, children) {
5866
5916
  // Inline function 'kotlin.collections.forEach' call
5867
- var _iterator__ex2g4s = mi.ao_1.x();
5917
+ var _iterator__ex2g4s = mi.bo_1.x();
5868
5918
  while (_iterator__ex2g4s.z()) {
5869
5919
  var element = _iterator__ex2g4s.a1();
5870
- var tmp = element.en();
5920
+ var tmp = element.fn();
5871
5921
  var tmp_0 = pawnTuples$lambda;
5872
- generateTuples(tmp, element.jo_1, element.ko_1, element.lo_1, position, children, tmp_0, pawnTuples$lambda_0);
5873
- generatePromotionTuples(element.xp(), element.jo_1, element.ko_1, position, children);
5874
- var tmp_1 = element.wp();
5922
+ generateTuples(tmp, element.ko_1, element.lo_1, element.mo_1, position, children, tmp_0, pawnTuples$lambda_0);
5923
+ generatePromotionTuples(element.yp(), element.ko_1, element.lo_1, position, children);
5924
+ var tmp_1 = element.xp();
5875
5925
  var tmp_2 = pawnTuples$lambda_1;
5876
- generateTuples(tmp_1, element.jo_1, element.ko_1, element.lo_1, position, children, tmp_2, pawnTuples$lambda_2);
5877
- var tmp0_safe_receiver = element.yp();
5926
+ generateTuples(tmp_1, element.ko_1, element.lo_1, element.mo_1, position, children, tmp_2, pawnTuples$lambda_2);
5927
+ var tmp0_safe_receiver = element.zp();
5878
5928
  if (tmp0_safe_receiver == null)
5879
5929
  null;
5880
5930
  else {
5881
5931
  // Inline function 'kotlin.let' call
5882
- generateEnPassantCaptureTuple(tmp0_safe_receiver, element.jo_1, element.ko_1, position, children);
5932
+ generateEnPassantCaptureTuple(tmp0_safe_receiver, element.ko_1, element.lo_1, position, children);
5883
5933
  }
5884
5934
  }
5885
5935
  }
5886
5936
  function knightBishopAndQueenTuples(mi, position, children) {
5887
5937
  // Inline function 'kotlin.collections.forEach' call
5888
- var _iterator__ex2g4s = mi.bo_1.x();
5938
+ var _iterator__ex2g4s = mi.co_1.x();
5889
5939
  while (_iterator__ex2g4s.z()) {
5890
5940
  var element = _iterator__ex2g4s.a1();
5891
- var tmp = element.hn();
5941
+ var tmp = element.in();
5892
5942
  var tmp_0 = knightBishopAndQueenTuples$lambda;
5893
- generateTuples(tmp, element.yo_1, element.zo_1, element.ap_1, position, children, tmp_0, knightBishopAndQueenTuples$lambda_0);
5943
+ generateTuples(tmp, element.zo_1, element.ap_1, element.bp_1, position, children, tmp_0, knightBishopAndQueenTuples$lambda_0);
5894
5944
  }
5895
5945
  // Inline function 'kotlin.collections.forEach' call
5896
- var _iterator__ex2g4s_0 = mi.co_1.x();
5946
+ var _iterator__ex2g4s_0 = mi.do_1.x();
5897
5947
  while (_iterator__ex2g4s_0.z()) {
5898
5948
  var element_0 = _iterator__ex2g4s_0.a1();
5899
- var tmp_1 = element_0.hn();
5949
+ var tmp_1 = element_0.in();
5900
5950
  var tmp_2 = knightBishopAndQueenTuples$lambda_1;
5901
- generateTuples(tmp_1, element_0.yo_1, element_0.zo_1, element_0.ap_1, position, children, tmp_2, knightBishopAndQueenTuples$lambda_2);
5951
+ generateTuples(tmp_1, element_0.zo_1, element_0.ap_1, element_0.bp_1, position, children, tmp_2, knightBishopAndQueenTuples$lambda_2);
5902
5952
  }
5903
5953
  // Inline function 'kotlin.collections.forEach' call
5904
- var _iterator__ex2g4s_1 = mi.eo_1.x();
5954
+ var _iterator__ex2g4s_1 = mi.fo_1.x();
5905
5955
  while (_iterator__ex2g4s_1.z()) {
5906
5956
  var element_1 = _iterator__ex2g4s_1.a1();
5907
- var tmp_3 = element_1.hn();
5957
+ var tmp_3 = element_1.in();
5908
5958
  var tmp_4 = knightBishopAndQueenTuples$lambda_3;
5909
- generateTuples(tmp_3, element_1.yo_1, element_1.zo_1, element_1.ap_1, position, children, tmp_4, knightBishopAndQueenTuples$lambda_4);
5959
+ generateTuples(tmp_3, element_1.zo_1, element_1.ap_1, element_1.bp_1, position, children, tmp_4, knightBishopAndQueenTuples$lambda_4);
5910
5960
  }
5911
5961
  }
5912
5962
  function rookTuples(mi, position, children) {
5913
5963
  // Inline function 'kotlin.collections.forEach' call
5914
- var _iterator__ex2g4s = mi.do_1.x();
5964
+ var _iterator__ex2g4s = mi.eo_1.x();
5915
5965
  while (_iterator__ex2g4s.z()) {
5916
5966
  var element = _iterator__ex2g4s.a1();
5917
- var tmp = element.hn();
5967
+ var tmp = element.in();
5918
5968
  var tmp_0 = rookTuples$lambda;
5919
- generateTuples(tmp, element.yo_1, element.zo_1, element.ap_1, position, children, tmp_0, rookTuples$lambda_0);
5969
+ generateTuples(tmp, element.zo_1, element.ap_1, element.bp_1, position, children, tmp_0, rookTuples$lambda_0);
5920
5970
  }
5921
5971
  }
5922
5972
  function kingTuples(mi, position, children) {
5923
- var tmp = mi.fo_1.en();
5973
+ var tmp = mi.go_1.fn();
5924
5974
  var tmp_0 = kingTuples$lambda;
5925
- generateTuples(tmp, mi.fo_1.um_1, mi.fo_1.vm_1, mi.fo_1.wm_1, position, children, tmp_0, kingTuples$lambda_0);
5926
- generateCastleTuples(mi.fo_1.fn(), mi.fo_1.um_1, mi.fo_1.vm_1, position, children);
5975
+ generateTuples(tmp, mi.go_1.vm_1, mi.go_1.wm_1, mi.go_1.xm_1, position, children, tmp_0, kingTuples$lambda_0);
5976
+ generateCastleTuples(mi.go_1.gn(), mi.go_1.vm_1, mi.go_1.wm_1, position, children);
5927
5977
  }
5928
5978
  function generateTuples(moves, pieceType, square, enemies, position, children, epFunction, castleFunction) {
5929
5979
  // Inline function 'kotlin.collections.forEach' call
5930
5980
  var _iterator__ex2g4s = moves.x();
5931
5981
  while (_iterator__ex2g4s.z()) {
5932
5982
  var element = _iterator__ex2g4s.a1();
5933
- var move = element.on_1;
5934
- var bitboards = position.eq();
5983
+ var move = element.pn_1;
5984
+ var bitboards = position.fq();
5935
5985
  var inductionVariable = 0;
5936
5986
  if (inductionVariable <= 11)
5937
5987
  do {
@@ -5953,7 +6003,7 @@ function generateTuples(moves, pieceType, square, enemies, position, children, e
5953
6003
  var isCapture = isPresent(enemies & move);
5954
6004
  var isPawnMove = isPresent(move & bitboards[(Piece_BP_getInstance().m2_1 - aux | 0) - 1 | 0]);
5955
6005
  var hm = isCapture || isPawnMove ? 0 : position.mj_1 + 1 | 0;
5956
- var tuple = tupleOf(Position.nq(bitboards, wm, ep, wk, wq, bk, bq, mc, hm), element);
6006
+ var tuple = tupleOf(Position.oq(bitboards, wm, ep, wk, wq, bk, bq, mc, hm), element);
5957
6007
  children.k(tuple);
5958
6008
  }
5959
6009
  }
@@ -5962,9 +6012,9 @@ function generatePromotionTuples(moves, pieceType, square, position, children) {
5962
6012
  var _iterator__ex2g4s = moves.x();
5963
6013
  while (_iterator__ex2g4s.z()) {
5964
6014
  var element = _iterator__ex2g4s.a1();
5965
- var move = element.on_1;
5966
- var promotionPiece = element.qn_1;
5967
- var bitboards = position.eq();
6015
+ var move = element.pn_1;
6016
+ var promotionPiece = element.rn_1;
6017
+ var bitboards = position.fq();
5968
6018
  var inductionVariable = 0;
5969
6019
  if (inductionVariable <= 11)
5970
6020
  do {
@@ -6020,15 +6070,15 @@ function generatePromotionTuples(moves, pieceType, square, position, children) {
6020
6070
  }
6021
6071
  var hm = 0;
6022
6072
  var ep = -1;
6023
- var newPosition = Position.nq(bitboards, wm, ep, wk, wq, bk, bq, mc, hm);
6073
+ var newPosition = Position.oq(bitboards, wm, ep, wk, wq, bk, bq, mc, hm);
6024
6074
  children.k(tupleOf(newPosition, element));
6025
6075
  }
6026
6076
  }
6027
6077
  function generateEnPassantCaptureTuple(m, pieceType, originSquare, position, children) {
6028
- var move = m.on_1;
6078
+ var move = m.pn_1;
6029
6079
  var whiteMove = position.fj_1;
6030
6080
  var capture = shiftLeft(1n, countTrailingZeroBits(move) + (whiteMove ? -8 : 8) | 0);
6031
- var bitboards = position.eq();
6081
+ var bitboards = position.fq();
6032
6082
  var inductionVariable = 0;
6033
6083
  if (inductionVariable <= 11)
6034
6084
  do {
@@ -6042,16 +6092,16 @@ function generateEnPassantCaptureTuple(m, pieceType, originSquare, position, chi
6042
6092
  var hm = 0;
6043
6093
  var mc = position.lj_1 + (wm ? 1 : 0) | 0;
6044
6094
  var ep = -1;
6045
- var newPosition = Position.nq(bitboards, wm, ep, position.hj_1, position.ij_1, position.jj_1, position.kj_1, mc, hm);
6046
- children.k(Tuple.uq(newPosition, m));
6095
+ var newPosition = Position.oq(bitboards, wm, ep, position.hj_1, position.ij_1, position.jj_1, position.kj_1, mc, hm);
6096
+ children.k(Tuple.vq(newPosition, m));
6047
6097
  }
6048
6098
  function generateCastleTuples(moves, kingPiece, square, position, children) {
6049
6099
  // Inline function 'kotlin.collections.forEach' call
6050
6100
  var _iterator__ex2g4s = moves.x();
6051
6101
  while (_iterator__ex2g4s.z()) {
6052
6102
  var element = _iterator__ex2g4s.a1();
6053
- var move = element.on_1;
6054
- var bitboards = position.eq();
6103
+ var move = element.pn_1;
6104
+ var bitboards = position.fq();
6055
6105
  var indexedObject = get_indexes();
6056
6106
  var inductionVariable = 0;
6057
6107
  var last = indexedObject.length;
@@ -6091,7 +6141,7 @@ function generateCastleTuples(moves, kingPiece, square, position, children) {
6091
6141
  var hm = position.mj_1 + 1 | 0;
6092
6142
  var mc = position.lj_1 + (wm ? 1 : 0) | 0;
6093
6143
  var ep = -1;
6094
- var newPosition = Position.nq(bitboards, wm, ep, wk, wq, bk, bq, mc, hm);
6144
+ var newPosition = Position.oq(bitboards, wm, ep, wk, wq, bk, bq, mc, hm);
6095
6145
  children.k(tupleOf(newPosition, element));
6096
6146
  }
6097
6147
  }
@@ -8784,7 +8834,7 @@ function checkCollision(move, moves) {
8784
8834
  _init_properties_moveFactory_kt__2023o9();
8785
8835
  var m = moves[move.hashCode()];
8786
8836
  if (!(m == null) && !equals(m, move)) {
8787
- throw get_logger().ln(RuntimeException.l7('hash collision for ' + m.toString() + ' and ' + move.toString()));
8837
+ throw get_logger().mn(RuntimeException.l7('hash collision for ' + m.toString() + ' and ' + move.toString()));
8788
8838
  }
8789
8839
  }
8790
8840
  function hash(origin, target) {
@@ -8836,7 +8886,7 @@ function yieldMoves() {
8836
8886
  while (inductionVariable_0 < last_0) {
8837
8887
  var item_0 = white[inductionVariable_0];
8838
8888
  inductionVariable_0 = inductionVariable_0 + 1 | 0;
8839
- var tmp$ret$13 = Move.sn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([valueOf_5(element + '8')])), valueOf_5(element + '7').m2_1, item_0.m2_1);
8889
+ var tmp$ret$13 = Move.tn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([valueOf_5(element + '8')])), valueOf_5(element + '7').m2_1, item_0.m2_1);
8840
8890
  destination_1.k(tmp$ret$13);
8841
8891
  }
8842
8892
  var list = destination_1;
@@ -8876,7 +8926,7 @@ function yieldMoves() {
8876
8926
  while (inductionVariable_2 < last_2) {
8877
8927
  var item_2 = white[inductionVariable_2];
8878
8928
  inductionVariable_2 = inductionVariable_2 + 1 | 0;
8879
- var tmp$ret$26 = Move.sn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_1 + '8').m2_1 + 1 | 0)])), valueOf_5(element_1 + '7').m2_1, item_2.m2_1);
8929
+ var tmp$ret$26 = Move.tn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_1 + '8').m2_1 + 1 | 0)])), valueOf_5(element_1 + '7').m2_1, item_2.m2_1);
8880
8930
  destination_4.k(tmp$ret$26);
8881
8931
  }
8882
8932
  var list_0 = destination_4;
@@ -8916,7 +8966,7 @@ function yieldMoves() {
8916
8966
  while (inductionVariable_4 < last_4) {
8917
8967
  var item_4 = white[inductionVariable_4];
8918
8968
  inductionVariable_4 = inductionVariable_4 + 1 | 0;
8919
- var tmp$ret$39 = Move.sn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_3 + '8').m2_1 - 1 | 0)])), valueOf_5(element_3 + '7').m2_1, item_4.m2_1);
8969
+ var tmp$ret$39 = Move.tn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_3 + '8').m2_1 - 1 | 0)])), valueOf_5(element_3 + '7').m2_1, item_4.m2_1);
8920
8970
  destination_7.k(tmp$ret$39);
8921
8971
  }
8922
8972
  var list_1 = destination_7;
@@ -8959,7 +9009,7 @@ function yieldMoves() {
8959
9009
  while (inductionVariable_6 < last_6) {
8960
9010
  var item_6 = black[inductionVariable_6];
8961
9011
  inductionVariable_6 = inductionVariable_6 + 1 | 0;
8962
- var tmp$ret$55 = Move.sn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([valueOf_5(element_5 + '1')])), valueOf_5(element_5 + '2').m2_1, item_6.m2_1);
9012
+ var tmp$ret$55 = Move.tn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([valueOf_5(element_5 + '1')])), valueOf_5(element_5 + '2').m2_1, item_6.m2_1);
8963
9013
  destination_10.k(tmp$ret$55);
8964
9014
  }
8965
9015
  var list_2 = destination_10;
@@ -8999,7 +9049,7 @@ function yieldMoves() {
8999
9049
  while (inductionVariable_8 < last_8) {
9000
9050
  var item_8 = black[inductionVariable_8];
9001
9051
  inductionVariable_8 = inductionVariable_8 + 1 | 0;
9002
- var tmp$ret$68 = Move.sn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_7 + '1').m2_1 + 1 | 0)])), valueOf_5(element_7 + '2').m2_1, item_8.m2_1);
9052
+ var tmp$ret$68 = Move.tn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_7 + '1').m2_1 + 1 | 0)])), valueOf_5(element_7 + '2').m2_1, item_8.m2_1);
9003
9053
  destination_13.k(tmp$ret$68);
9004
9054
  }
9005
9055
  var list_3 = destination_13;
@@ -9039,7 +9089,7 @@ function yieldMoves() {
9039
9089
  while (inductionVariable_10 < last_10) {
9040
9090
  var item_10 = black[inductionVariable_10];
9041
9091
  inductionVariable_10 = inductionVariable_10 + 1 | 0;
9042
- var tmp$ret$81 = Move.sn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_9 + '1').m2_1 - 1 | 0)])), valueOf_5(element_9 + '2').m2_1, item_10.m2_1);
9092
+ var tmp$ret$81 = Move.tn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(valueOf_5(element_9 + '1').m2_1 - 1 | 0)])), valueOf_5(element_9 + '2').m2_1, item_10.m2_1);
9043
9093
  destination_16.k(tmp$ret$81);
9044
9094
  }
9045
9095
  var list_4 = destination_16;
@@ -9062,7 +9112,7 @@ function yieldMoves() {
9062
9112
  var j = inductionVariable_12;
9063
9113
  inductionVariable_12 = inductionVariable_12 + 1 | 0;
9064
9114
  if (!(j === i)) {
9065
- moveList.k(Move.sn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(i)])), Companion_instance_6.c1(j).m2_1));
9115
+ moveList.k(Move.tn(_Bitboard___get_value__impl__9h2kos(Companion_instance.kh([Companion_instance_6.c1(i)])), Companion_instance_6.c1(j).m2_1));
9066
9116
  }
9067
9117
  }
9068
9118
  while (inductionVariable_12 <= 63);
@@ -9102,7 +9152,7 @@ function yieldMoveFromOriginTarget$lambda($moves) {
9102
9152
  var tmp0_elvis_lhs = $moves[hash(origin, target)];
9103
9153
  var tmp;
9104
9154
  if (tmp0_elvis_lhs == null) {
9105
- throw get_logger().ln(MoveException.zn('move for origin=' + origin + ', target=' + target + ' not found'));
9155
+ throw get_logger().mn(MoveException.ao('move for origin=' + origin + ', target=' + target + ' not found'));
9106
9156
  } else {
9107
9157
  tmp = tmp0_elvis_lhs;
9108
9158
  }
@@ -9116,7 +9166,7 @@ function yieldMoveFromOriginTargetPromotion$lambda($moves) {
9116
9166
  var tmp0_elvis_lhs = $moves[hash(origin, target)];
9117
9167
  var tmp_0;
9118
9168
  if (tmp0_elvis_lhs == null) {
9119
- throw get_logger().ln(MoveException.zn('move for origin=' + origin + ', target=' + target + ' not found'));
9169
+ throw get_logger().mn(MoveException.ao('move for origin=' + origin + ', target=' + target + ' not found'));
9120
9170
  } else {
9121
9171
  tmp_0 = tmp0_elvis_lhs;
9122
9172
  }
@@ -9125,7 +9175,7 @@ function yieldMoveFromOriginTargetPromotion$lambda($moves) {
9125
9175
  var tmp1_elvis_lhs = $moves[hash_0(origin, target, promotionPiece)];
9126
9176
  var tmp_1;
9127
9177
  if (tmp1_elvis_lhs == null) {
9128
- throw get_logger().ln(MoveException.zn('move for origin=' + origin + ', target=' + target + ' not found, promotionPiece=' + promotionPiece));
9178
+ throw get_logger().mn(MoveException.ao('move for origin=' + origin + ', target=' + target + ' not found, promotionPiece=' + promotionPiece));
9129
9179
  } else {
9130
9180
  tmp_1 = tmp1_elvis_lhs;
9131
9181
  }
@@ -9139,7 +9189,7 @@ function yieldMoveFromOriginTargetObjects$lambda($moves) {
9139
9189
  var tmp0_elvis_lhs = $moves[hash(origin.m2_1, target.m2_1)];
9140
9190
  var tmp;
9141
9191
  if (tmp0_elvis_lhs == null) {
9142
- throw get_logger().ln(MoveException.zn('move for origin=' + origin.toString() + ', target=' + target.toString() + ' not found'));
9192
+ throw get_logger().mn(MoveException.ao('move for origin=' + origin.toString() + ', target=' + target.toString() + ' not found'));
9143
9193
  } else {
9144
9194
  tmp = tmp0_elvis_lhs;
9145
9195
  }
@@ -9151,7 +9201,7 @@ function yieldMoveFromOriginTargetPromotionObjects$lambda($moves) {
9151
9201
  var tmp0_elvis_lhs = $moves[hash_0(origin.m2_1, target.m2_1, promotionPiece.m2_1)];
9152
9202
  var tmp;
9153
9203
  if (tmp0_elvis_lhs == null) {
9154
- throw get_logger().ln(MoveException.zn('move for origin=' + origin.toString() + ', target=' + target.toString() + ', promotion=' + promotionPiece.toString() + ' not found'));
9204
+ throw get_logger().mn(MoveException.ao('move for origin=' + origin.toString() + ', target=' + target.toString() + ', promotion=' + promotionPiece.toString() + ' not found'));
9155
9205
  } else {
9156
9206
  tmp = tmp0_elvis_lhs;
9157
9207
  }
@@ -9163,7 +9213,7 @@ function yieldMoveFromString$lambda($map) {
9163
9213
  var tmp0_elvis_lhs = $map.j2(move);
9164
9214
  var tmp;
9165
9215
  if (tmp0_elvis_lhs == null) {
9166
- throw MoveException.zn(move + ' is not a valid move string');
9216
+ throw MoveException.ao(move + ' is not a valid move string');
9167
9217
  } else {
9168
9218
  tmp = tmp0_elvis_lhs;
9169
9219
  }
@@ -9381,7 +9431,7 @@ function isStalemate(bitboards, isWhiteMove, legalMoves) {
9381
9431
  return isInCheck === 0n && legalMoves === 0n;
9382
9432
  }
9383
9433
  function tupleOf(v1, v2) {
9384
- return Tuple.uq(v1, v2);
9434
+ return Tuple.vq(v1, v2);
9385
9435
  }
9386
9436
  function init_io_github_lunalobos_chess4kt_Tuple(_this__u8e3s4) {
9387
9437
  }
@@ -9425,16 +9475,41 @@ function get_VALID_FULL_MOVE_COUNTER_PATTERN() {
9425
9475
  return VALID_FULL_MOVE_COUNTER_PATTERN;
9426
9476
  }
9427
9477
  var VALID_FULL_MOVE_COUNTER_PATTERN;
9428
- function get_PIECES() {
9429
- _init_properties_util_kt__mcwhvi();
9430
- return PIECES;
9431
- }
9432
- var PIECES;
9433
9478
  function get_MOVE_PATTERN() {
9434
9479
  _init_properties_util_kt__mcwhvi();
9435
9480
  return MOVE_PATTERN;
9436
9481
  }
9437
9482
  var MOVE_PATTERN;
9483
+ function get_piecesEnglish() {
9484
+ _init_properties_util_kt__mcwhvi();
9485
+ return piecesEnglish;
9486
+ }
9487
+ var piecesEnglish;
9488
+ function get_piecesSpanish() {
9489
+ _init_properties_util_kt__mcwhvi();
9490
+ return piecesSpanish;
9491
+ }
9492
+ var piecesSpanish;
9493
+ function get_piecesGerman() {
9494
+ _init_properties_util_kt__mcwhvi();
9495
+ return piecesGerman;
9496
+ }
9497
+ var piecesGerman;
9498
+ function get_piecesFrench() {
9499
+ _init_properties_util_kt__mcwhvi();
9500
+ return piecesFrench;
9501
+ }
9502
+ var piecesFrench;
9503
+ function get_piecesItalian() {
9504
+ _init_properties_util_kt__mcwhvi();
9505
+ return piecesItalian;
9506
+ }
9507
+ var piecesItalian;
9508
+ function get_piecesDutch() {
9509
+ _init_properties_util_kt__mcwhvi();
9510
+ return piecesDutch;
9511
+ }
9512
+ var piecesDutch;
9438
9513
  function getColLetter(square) {
9439
9514
  _init_properties_util_kt__mcwhvi();
9440
9515
  var colNum = getCol(square);
@@ -9762,8 +9837,8 @@ function positionFromFen(fen) {
9762
9837
  if (!isValidFenFormat(fen)) {
9763
9838
  throw IllegalArgumentException.s('invalid fen ' + fen);
9764
9839
  }
9765
- var position = Position.oq(fen);
9766
- var bitboards = Position.oq(fen).eq();
9840
+ var position = Position.pq(fen);
9841
+ var bitboards = Position.pq(fen).fq();
9767
9842
  var validCheck = !inCheck(bitboards, !position.fj_1);
9768
9843
  var wpBitboards = bitboards[Piece_WP_getInstance().m2_1 - 1 | 0];
9769
9844
  var bpBitboards = bitboards[Piece_BP_getInstance().m2_1 - 1 | 0];
@@ -9876,11 +9951,11 @@ function get_enPassantSquare(_this__u8e3s4) {
9876
9951
  }
9877
9952
  function get_draw(_this__u8e3s4) {
9878
9953
  _init_properties_util_kt__mcwhvi();
9879
- return _this__u8e3s4.hq() || _this__u8e3s4.iq();
9954
+ return _this__u8e3s4.iq() || _this__u8e3s4.jq();
9880
9955
  }
9881
9956
  function get_gameOver(_this__u8e3s4) {
9882
9957
  _init_properties_util_kt__mcwhvi();
9883
- return _this__u8e3s4.gq() || _this__u8e3s4.hq() || _this__u8e3s4.iq();
9958
+ return _this__u8e3s4.hq() || _this__u8e3s4.iq() || _this__u8e3s4.jq();
9884
9959
  }
9885
9960
  function get_sideToMove(_this__u8e3s4) {
9886
9961
  _init_properties_util_kt__mcwhvi();
@@ -9888,7 +9963,7 @@ function get_sideToMove(_this__u8e3s4) {
9888
9963
  }
9889
9964
  function get_children(_this__u8e3s4) {
9890
9965
  _init_properties_util_kt__mcwhvi();
9891
- return generateChildren(_this__u8e3s4.dq(), _this__u8e3s4);
9966
+ return generateChildren(_this__u8e3s4.eq(), _this__u8e3s4);
9892
9967
  }
9893
9968
  function move(_this__u8e3s4, move) {
9894
9969
  _init_properties_util_kt__mcwhvi();
@@ -9911,7 +9986,7 @@ function move(_this__u8e3s4, move) {
9911
9986
  var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.pk_1;
9912
9987
  var tmp;
9913
9988
  if (tmp1_elvis_lhs == null) {
9914
- throw MoveException.zn('illegal move ' + move.toString());
9989
+ throw MoveException.ao('illegal move ' + move.toString());
9915
9990
  } else {
9916
9991
  tmp = tmp1_elvis_lhs;
9917
9992
  }
@@ -9947,7 +10022,7 @@ function move_0(_this__u8e3s4, move, notation) {
9947
10022
  var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.pk_1;
9948
10023
  var tmp_0;
9949
10024
  if (tmp1_elvis_lhs == null) {
9950
- throw MoveException.zn('illegal move ' + move);
10025
+ throw MoveException.ao('illegal move ' + move);
9951
10026
  } else {
9952
10027
  tmp_0 = tmp1_elvis_lhs;
9953
10028
  }
@@ -9979,7 +10054,7 @@ function move_0(_this__u8e3s4, move, notation) {
9979
10054
  var tmp2_elvis_lhs = tmp0_safe_receiver_0 == null ? null : tmp0_safe_receiver_0.pk_1;
9980
10055
  var tmp_1;
9981
10056
  if (tmp2_elvis_lhs == null) {
9982
- throw MoveException.zn('illegal move ' + move);
10057
+ throw MoveException.ao('illegal move ' + move);
9983
10058
  } else {
9984
10059
  tmp_1 = tmp2_elvis_lhs;
9985
10060
  }
@@ -9994,7 +10069,7 @@ function move_0(_this__u8e3s4, move, notation) {
9994
10069
  }
9995
10070
  function isLegal(_this__u8e3s4, move) {
9996
10071
  _init_properties_util_kt__mcwhvi();
9997
- var m = get_moveFromOriginTargetPromotion()(move.pn_1, move.rn_1, move.qn_1);
10072
+ var m = get_moveFromOriginTargetPromotion()(move.qn_1, move.sn_1, move.rn_1);
9998
10073
  var tmp0 = get_children(_this__u8e3s4);
9999
10074
  var tmp$ret$0;
10000
10075
  $l$block_0: {
@@ -10021,107 +10096,6 @@ function isLegal(_this__u8e3s4, move) {
10021
10096
  }
10022
10097
  return tmp$ret$0;
10023
10098
  }
10024
- function toSan(position, move_0) {
10025
- _init_properties_util_kt__mcwhvi();
10026
- // Inline function 'kotlin.require' call
10027
- if (!isLegal(position, move_0)) {
10028
- var message = 'illegal move ' + move_0.toString() + ' for position ' + position.lq();
10029
- throw IllegalArgumentException.s(toString(message));
10030
- }
10031
- var sbSAN = StringBuilder.u();
10032
- var piece = get_entries_0().c1(position.kq()[move_0.pn_1]);
10033
- sbSAN.j8(get_PIECES()[piece.m2_1]);
10034
- var isPawn = piece.equals(Piece_WP_getInstance()) || piece.equals(Piece_BP_getInstance());
10035
- var tmp = asSequence(get_children(position));
10036
- var tmp_0 = map(tmp, toSan$lambda);
10037
- var tmp_1 = filter(tmp_0, toSan$lambda_0(move_0));
10038
- var tmp_2 = filter(tmp_1, toSan$lambda_1(position, move_0));
10039
- var moves = toList(filter(tmp_2, toSan$lambda_2(move_0)));
10040
- var tmp$ret$2;
10041
- $l$block_0: {
10042
- // Inline function 'kotlin.collections.any' call
10043
- var tmp_3;
10044
- if (isInterface(moves, Collection)) {
10045
- tmp_3 = moves.c2();
10046
- } else {
10047
- tmp_3 = false;
10048
- }
10049
- if (tmp_3) {
10050
- tmp$ret$2 = false;
10051
- break $l$block_0;
10052
- }
10053
- var _iterator__ex2g4s = moves.x();
10054
- while (_iterator__ex2g4s.z()) {
10055
- var element = _iterator__ex2g4s.a1();
10056
- if (getCol(element.pn_1) === getCol(move_0.pn_1)) {
10057
- tmp$ret$2 = true;
10058
- break $l$block_0;
10059
- }
10060
- }
10061
- tmp$ret$2 = false;
10062
- }
10063
- var sameColumn = tmp$ret$2;
10064
- var tmp$ret$4;
10065
- $l$block_2: {
10066
- // Inline function 'kotlin.collections.any' call
10067
- var tmp_4;
10068
- if (isInterface(moves, Collection)) {
10069
- tmp_4 = moves.c2();
10070
- } else {
10071
- tmp_4 = false;
10072
- }
10073
- if (tmp_4) {
10074
- tmp$ret$4 = false;
10075
- break $l$block_2;
10076
- }
10077
- var _iterator__ex2g4s_0 = moves.x();
10078
- while (_iterator__ex2g4s_0.z()) {
10079
- var element_0 = _iterator__ex2g4s_0.a1();
10080
- if (getRow(element_0.pn_1) === getRow(move_0.pn_1)) {
10081
- tmp$ret$4 = true;
10082
- break $l$block_2;
10083
- }
10084
- }
10085
- tmp$ret$4 = false;
10086
- }
10087
- var sameRow = tmp$ret$4;
10088
- if (sameRow && !sameColumn && !isPawn) {
10089
- sbSAN.j8(getColLetter(move_0.pn_1));
10090
- }
10091
- if (!sameRow && sameColumn) {
10092
- sbSAN.za(getRow(move_0.pn_1) + 1 | 0);
10093
- }
10094
- if (sameRow && sameColumn) {
10095
- sbSAN.j8(getColLetter(move_0.pn_1)).za(getRow(move_0.pn_1) + 1 | 0);
10096
- }
10097
- if (!sameRow && !sameColumn && !moves.c2() && !isPawn) {
10098
- sbSAN.j8(getColLetter(move_0.pn_1));
10099
- }
10100
- var capture = !(position.kq()[move_0.rn_1] === Piece_EMPTY_getInstance().m2_1);
10101
- if (capture) {
10102
- if (isPawn) {
10103
- sbSAN.j8(getColLetter(move_0.pn_1));
10104
- }
10105
- sbSAN.j8('x');
10106
- }
10107
- sbSAN.j8(getColLetter(move_0.rn_1)).za(getRow(move_0.rn_1) + 1 | 0);
10108
- var isPromotion_0 = !(move_0.qn_1 === -1) && isPromotion(move_0.rn_1) === 1n;
10109
- if (isPromotion_0) {
10110
- sbSAN.j8('=').j8(get_PIECES()[move_0.qn_1]);
10111
- }
10112
- var isCastle = !!(piece === Piece_WK_getInstance() | piece === Piece_BK_getInstance()) && listOf(['e1g1', 'e1c1', 'e8g8', 'e8c8']).d2(move_0.toString());
10113
- if (isCastle) {
10114
- sbSAN = StringBuilder.u();
10115
- sbSAN.j8(!!(startsWith(move_0.toString(), 'g1', 2) | startsWith(move_0.toString(), 'g8', 2)) ? 'O-O' : 'O-O-O');
10116
- }
10117
- var p = move(position, move_0);
10118
- if (p.gq()) {
10119
- sbSAN.j8('#');
10120
- } else if (p.fq()) {
10121
- sbSAN.j8('+');
10122
- }
10123
- return sbSAN.toString();
10124
- }
10125
10099
  function genericHashCode(a) {
10126
10100
  _init_properties_util_kt__mcwhvi();
10127
10101
  if (a == null)
@@ -10186,7 +10160,7 @@ function sanToMove(position, sanMove) {
10186
10160
  var tmp3_elvis_lhs = tmp_0;
10187
10161
  var tmp_1;
10188
10162
  if (tmp3_elvis_lhs == null) {
10189
- throw MoveException.zn('Invalid castling move: ' + sanMove);
10163
+ throw MoveException.ao('Invalid castling move: ' + sanMove);
10190
10164
  } else {
10191
10165
  tmp_1 = tmp3_elvis_lhs;
10192
10166
  }
@@ -10205,7 +10179,7 @@ function sanToMove(position, sanMove) {
10205
10179
  var tmp7_elvis_lhs = tmp6_safe_receiver == null ? null : tmp6_safe_receiver.zb_1;
10206
10180
  var tmp_2;
10207
10181
  if (tmp7_elvis_lhs == null) {
10208
- throw MoveException.zn('Missing target column in SAN move: ' + sanMove);
10182
+ throw MoveException.ao('Missing target column in SAN move: ' + sanMove);
10209
10183
  } else {
10210
10184
  tmp_2 = tmp7_elvis_lhs;
10211
10185
  }
@@ -10214,7 +10188,7 @@ function sanToMove(position, sanMove) {
10214
10188
  var tmp9_elvis_lhs = tmp8_safe_receiver == null ? null : tmp8_safe_receiver.zb_1;
10215
10189
  var tmp_3;
10216
10190
  if (tmp9_elvis_lhs == null) {
10217
- throw MoveException.zn('Missing target row in SAN move: ' + sanMove);
10191
+ throw MoveException.ao('Missing target row in SAN move: ' + sanMove);
10218
10192
  } else {
10219
10193
  tmp_3 = tmp9_elvis_lhs;
10220
10194
  }
@@ -10255,7 +10229,7 @@ function sanToMove(position, sanMove) {
10255
10229
  var xDestiny = getColIndex(targetCol);
10256
10230
  var yDestiny = toInt(targetRow) - 1 | 0;
10257
10231
  var destinySquare = getSquareIndex(xDestiny, yDestiny);
10258
- var tmp_6 = asSequence(position.dq().fp());
10232
+ var tmp_6 = asSequence(position.eq().gp());
10259
10233
  var tmp_7 = filter(tmp_6, sanToMove$lambda(destinySquare));
10260
10234
  var tmp_8 = filter(tmp_7, sanToMove$lambda_0(position, piece));
10261
10235
  var tmp0 = filter(tmp_8, sanToMove$lambda_1(origin_1));
@@ -10266,8 +10240,8 @@ function sanToMove(position, sanMove) {
10266
10240
  while (_iterator__ex2g4s.z()) {
10267
10241
  var element = _iterator__ex2g4s.a1();
10268
10242
  var tmp_9;
10269
- if (!(element.qn_1 === -1)) {
10270
- var promotedPieceChar = substring_0(get_entries_0().c1(element.qn_1).toString(), 1, 2);
10243
+ if (!(element.rn_1 === -1)) {
10244
+ var promotedPieceChar = substring_0(get_entries_0().c1(element.rn_1).toString(), 1, 2);
10271
10245
  tmp_9 = promotedPieceChar === promotionPieceSAN;
10272
10246
  } else {
10273
10247
  // Inline function 'kotlin.text.isEmpty' call
@@ -10283,7 +10257,7 @@ function sanToMove(position, sanMove) {
10283
10257
  var tmp12_elvis_lhs = tmp$ret$13;
10284
10258
  var tmp_10;
10285
10259
  if (tmp12_elvis_lhs == null) {
10286
- throw MoveException.zn("The move '" + sanMove + "' is not a legal move in the current position " + position.lq());
10260
+ throw MoveException.ao("The move '" + sanMove + "' is not a legal move in the current position " + position.mq());
10287
10261
  } else {
10288
10262
  tmp_10 = tmp12_elvis_lhs;
10289
10263
  }
@@ -10336,35 +10310,137 @@ function deleteBefore(_this__u8e3s4, node) {
10336
10310
  var oldParent = tmp;
10337
10311
  // Inline function 'kotlin.apply' call
10338
10312
  var this_0 = new RootNode(_this__u8e3s4, oldParent.uj());
10339
- this_0.fl_1.k(node);
10313
+ this_0.gl_1.k(node);
10340
10314
  var newParent = this_0;
10341
10315
  node.uk(newParent);
10342
- _this__u8e3s4.fm(newParent);
10316
+ _this__u8e3s4.gm(newParent);
10343
10317
  var last_0 = last(asSequence_1(_this__u8e3s4.x()));
10344
- _this__u8e3s4.ul(last_0);
10318
+ _this__u8e3s4.vl(last_0);
10345
10319
  var tmp0 = _this__u8e3s4.xj_1;
10346
10320
  // Inline function 'kotlin.collections.set' call
10347
- var value = newParent.dl_1.lq();
10321
+ var value = newParent.el_1.mq();
10348
10322
  tmp0.f5('fen', value);
10349
10323
  return node;
10350
10324
  }
10351
10325
  function whiteLacksOfMaterial(_this__u8e3s4) {
10352
10326
  _init_properties_util_kt__mcwhvi();
10353
- return isWhiteLackOfMaterial(_this__u8e3s4.eq());
10327
+ return isWhiteLackOfMaterial(_this__u8e3s4.fq());
10354
10328
  }
10355
10329
  function blackLacksOfMaterial(_this__u8e3s4) {
10356
10330
  _init_properties_util_kt__mcwhvi();
10357
- return isBlackLackOfMaterial(_this__u8e3s4.eq());
10331
+ return isBlackLackOfMaterial(_this__u8e3s4.fq());
10332
+ }
10333
+ function toSan_0(position, move_0, pieces) {
10334
+ pieces = pieces === VOID ? get_piecesEnglish() : pieces;
10335
+ _init_properties_util_kt__mcwhvi();
10336
+ // Inline function 'kotlin.require' call
10337
+ if (!isLegal(position, move_0)) {
10338
+ var message = 'illegal move ' + move_0.toString() + ' for position ' + position.mq();
10339
+ throw IllegalArgumentException.s(toString(message));
10340
+ }
10341
+ var sbSAN = StringBuilder.u();
10342
+ var piece = get_entries_0().c1(position.lq()[move_0.qn_1]);
10343
+ sbSAN.j8(pieces[piece.m2_1]);
10344
+ var isPawn = piece.equals(Piece_WP_getInstance()) || piece.equals(Piece_BP_getInstance());
10345
+ var tmp = asSequence(get_children(position));
10346
+ var tmp_0 = map(tmp, toSan$lambda);
10347
+ var tmp_1 = filter(tmp_0, toSan$lambda_0(move_0));
10348
+ var tmp_2 = filter(tmp_1, toSan$lambda_1(position, move_0));
10349
+ var moves = toList(filter(tmp_2, toSan$lambda_2(move_0)));
10350
+ var tmp$ret$2;
10351
+ $l$block_0: {
10352
+ // Inline function 'kotlin.collections.any' call
10353
+ var tmp_3;
10354
+ if (isInterface(moves, Collection)) {
10355
+ tmp_3 = moves.c2();
10356
+ } else {
10357
+ tmp_3 = false;
10358
+ }
10359
+ if (tmp_3) {
10360
+ tmp$ret$2 = false;
10361
+ break $l$block_0;
10362
+ }
10363
+ var _iterator__ex2g4s = moves.x();
10364
+ while (_iterator__ex2g4s.z()) {
10365
+ var element = _iterator__ex2g4s.a1();
10366
+ if (getCol(element.qn_1) === getCol(move_0.qn_1)) {
10367
+ tmp$ret$2 = true;
10368
+ break $l$block_0;
10369
+ }
10370
+ }
10371
+ tmp$ret$2 = false;
10372
+ }
10373
+ var sameColumn = tmp$ret$2;
10374
+ var tmp$ret$4;
10375
+ $l$block_2: {
10376
+ // Inline function 'kotlin.collections.any' call
10377
+ var tmp_4;
10378
+ if (isInterface(moves, Collection)) {
10379
+ tmp_4 = moves.c2();
10380
+ } else {
10381
+ tmp_4 = false;
10382
+ }
10383
+ if (tmp_4) {
10384
+ tmp$ret$4 = false;
10385
+ break $l$block_2;
10386
+ }
10387
+ var _iterator__ex2g4s_0 = moves.x();
10388
+ while (_iterator__ex2g4s_0.z()) {
10389
+ var element_0 = _iterator__ex2g4s_0.a1();
10390
+ if (getRow(element_0.qn_1) === getRow(move_0.qn_1)) {
10391
+ tmp$ret$4 = true;
10392
+ break $l$block_2;
10393
+ }
10394
+ }
10395
+ tmp$ret$4 = false;
10396
+ }
10397
+ var sameRow = tmp$ret$4;
10398
+ if (sameRow && !sameColumn && !isPawn) {
10399
+ sbSAN.j8(getColLetter(move_0.qn_1));
10400
+ }
10401
+ if (!sameRow && sameColumn) {
10402
+ sbSAN.za(getRow(move_0.qn_1) + 1 | 0);
10403
+ }
10404
+ if (sameRow && sameColumn) {
10405
+ sbSAN.j8(getColLetter(move_0.qn_1)).za(getRow(move_0.qn_1) + 1 | 0);
10406
+ }
10407
+ if (!sameRow && !sameColumn && !moves.c2() && !isPawn) {
10408
+ sbSAN.j8(getColLetter(move_0.qn_1));
10409
+ }
10410
+ var capture = !(position.lq()[move_0.sn_1] === Piece_EMPTY_getInstance().m2_1);
10411
+ if (capture) {
10412
+ if (isPawn) {
10413
+ sbSAN.j8(getColLetter(move_0.qn_1));
10414
+ }
10415
+ sbSAN.j8('x');
10416
+ }
10417
+ sbSAN.j8(getColLetter(move_0.sn_1)).za(getRow(move_0.sn_1) + 1 | 0);
10418
+ var isPromotion_0 = !(move_0.rn_1 === -1) && isPromotion(move_0.sn_1) === 1n;
10419
+ if (isPromotion_0) {
10420
+ sbSAN.j8('=').j8(pieces[move_0.rn_1]);
10421
+ }
10422
+ var isCastle = !!(piece.equals(Piece_WK_getInstance()) | piece.equals(Piece_BK_getInstance())) && listOf(['e1g1', 'e1c1', 'e8g8', 'e8c8']).d2(move_0.toString());
10423
+ if (isCastle) {
10424
+ sbSAN = StringBuilder.u();
10425
+ sbSAN.j8(!!(startsWith(move_0.toString(), 'g1', 2) | startsWith(move_0.toString(), 'g8', 2)) ? 'O-O' : 'O-O-O');
10426
+ }
10427
+ var p = move(position, move_0);
10428
+ if (p.hq()) {
10429
+ sbSAN.j8('#');
10430
+ } else if (p.gq()) {
10431
+ sbSAN.j8('+');
10432
+ }
10433
+ return sbSAN.toString();
10358
10434
  }
10359
10435
  function toSquares$lambda(it) {
10360
10436
  _init_properties_util_kt__mcwhvi();
10361
10437
  return Companion_instance_6.c1(countTrailingZeroBits(it));
10362
10438
  }
10363
10439
  function *_generator_invoke__zhh2q8_2($this, $this$sequence, $completion) {
10364
- var copy = $this.vq_1;
10440
+ var copy = $this.wq_1;
10365
10441
  while (!(copy === 0n)) {
10366
10442
  var lowestOneBit = copy & negate(copy);
10367
- var tmp = $this$sequence.ud($this.wq_1(lowestOneBit), $completion);
10443
+ var tmp = $this$sequence.ud($this.xq_1(lowestOneBit), $completion);
10368
10444
  if (tmp === get_COROUTINE_SUSPENDED())
10369
10445
  tmp = yield tmp;
10370
10446
  copy = copy & ~lowestOneBit;
@@ -10373,29 +10449,16 @@ function *_generator_invoke__zhh2q8_2($this, $this$sequence, $completion) {
10373
10449
  }
10374
10450
  function bitboardToSequence$slambda_0($bitboard, $entitiesFactory) {
10375
10451
  var i = new bitboardToSequence$slambda($bitboard, $entitiesFactory);
10376
- var l = ($this$sequence, $completion) => i.xq($this$sequence, $completion);
10452
+ var l = ($this$sequence, $completion) => i.yq($this$sequence, $completion);
10377
10453
  l.$arity = 1;
10378
10454
  return l;
10379
10455
  }
10380
- function toSan$lambda(it) {
10381
- _init_properties_util_kt__mcwhvi();
10382
- return it.qk_1;
10383
- }
10384
- function toSan$lambda_0($move) {
10385
- return (m) => m.rn_1 === $move.rn_1;
10386
- }
10387
- function toSan$lambda_1($position, $move) {
10388
- return (m) => get_entries_0().c1($position.kq()[m.pn_1]) === get_entries_0().c1($position.kq()[$move.pn_1]);
10389
- }
10390
- function toSan$lambda_2($move) {
10391
- return (m) => !(m.pn_1 === $move.pn_1);
10392
- }
10393
10456
  function sanToMove$lambda($destinySquare) {
10394
- return (m) => m.rn_1 === $destinySquare;
10457
+ return (m) => m.sn_1 === $destinySquare;
10395
10458
  }
10396
10459
  function sanToMove$lambda_0($position, $piece) {
10397
10460
  return (m) => {
10398
- var movePiece = get_entries_0().c1($position.kq()[m.pn_1]);
10461
+ var movePiece = get_entries_0().c1($position.lq()[m.qn_1]);
10399
10462
  return movePiece.equals($piece);
10400
10463
  };
10401
10464
  }
@@ -10407,10 +10470,10 @@ function sanToMove$lambda_1($origin) {
10407
10470
  var tmp_0;
10408
10471
  if (isDigit(first($origin))) {
10409
10472
  var row = toInt($origin) - 1 | 0;
10410
- tmp_0 = getRow(m.pn_1) === row;
10473
+ tmp_0 = getRow(m.qn_1) === row;
10411
10474
  } else {
10412
10475
  var col = getColIndex($origin);
10413
- tmp_0 = getCol(m.pn_1) === col;
10476
+ tmp_0 = getCol(m.qn_1) === col;
10414
10477
  }
10415
10478
 
10416
10479
  tmp = tmp_0;
@@ -10425,6 +10488,19 @@ function sanToMove$lambda_1($origin) {
10425
10488
  return tmp;
10426
10489
  };
10427
10490
  }
10491
+ function toSan$lambda(it) {
10492
+ _init_properties_util_kt__mcwhvi();
10493
+ return it.qk_1;
10494
+ }
10495
+ function toSan$lambda_0($move) {
10496
+ return (m) => m.sn_1 === $move.sn_1;
10497
+ }
10498
+ function toSan$lambda_1($position, $move) {
10499
+ return (m) => get_entries_0().c1($position.lq()[m.qn_1]) === get_entries_0().c1($position.lq()[$move.qn_1]);
10500
+ }
10501
+ function toSan$lambda_2($move) {
10502
+ return (m) => !(m.qn_1 === $move.qn_1);
10503
+ }
10428
10504
  var properties_initialized_util_kt_qfsh5w;
10429
10505
  function _init_properties_util_kt__mcwhvi() {
10430
10506
  if (!properties_initialized_util_kt_qfsh5w) {
@@ -10440,11 +10516,31 @@ function _init_properties_util_kt__mcwhvi() {
10440
10516
  VALID_EN_PASSANT_PATTERN = Regex.nb('^[-]{1}$|^[abcdefgh][36]$');
10441
10517
  VALID_HALF_MOVE_CLOCK_PATTERN = Regex.nb('^[0123456789]+$');
10442
10518
  VALID_FULL_MOVE_COUNTER_PATTERN = Regex.nb('^[1-9][0-9]*$');
10519
+ MOVE_PATTERN = Regex.nb('(?<move>(?<regular>(?<piece>[KQBNR])?(?<originCol>[a-h])?(?<originRow>[1-8])?x?(?<targetCol>[a-h])(?<targetRow>[1-8])=?(?<promotion>[QBNR])?)|(?<castle>O-O(-O)?))(?<check>[+#])?');
10443
10520
  // Inline function 'kotlin.arrayOf' call
10444
10521
  // Inline function 'kotlin.js.unsafeCast' call
10445
10522
  // Inline function 'kotlin.js.asDynamic' call
10446
- PIECES = ['', '', 'N', 'B', 'R', 'Q', 'K', '', 'N', 'B', 'R', 'Q', 'K'];
10447
- MOVE_PATTERN = Regex.nb('(?<move>(?<regular>(?<piece>[KQBNR])?(?<originCol>[a-h])?(?<originRow>[1-8])?x?(?<targetCol>[a-h])(?<targetRow>[1-8])=?(?<promotion>[QBNR])?)|(?<castle>O-O(-O)?))(?<check>[+#])?');
10523
+ piecesEnglish = ['', '', 'N', 'B', 'R', 'Q', 'K', '', 'N', 'B', 'R', 'Q', 'K'];
10524
+ // Inline function 'kotlin.arrayOf' call
10525
+ // Inline function 'kotlin.js.unsafeCast' call
10526
+ // Inline function 'kotlin.js.asDynamic' call
10527
+ piecesSpanish = ['', '', 'C', 'A', 'T', 'D', 'R', '', 'C', 'A', 'T', 'D', 'R'];
10528
+ // Inline function 'kotlin.arrayOf' call
10529
+ // Inline function 'kotlin.js.unsafeCast' call
10530
+ // Inline function 'kotlin.js.asDynamic' call
10531
+ piecesGerman = ['', '', 'S', 'L', 'T', 'D', 'K', '', 'S', 'L', 'T', 'D', 'K'];
10532
+ // Inline function 'kotlin.arrayOf' call
10533
+ // Inline function 'kotlin.js.unsafeCast' call
10534
+ // Inline function 'kotlin.js.asDynamic' call
10535
+ piecesFrench = ['', '', 'C', 'F', 'T', 'D', 'R', '', 'C', 'F', 'T', 'D', 'R'];
10536
+ // Inline function 'kotlin.arrayOf' call
10537
+ // Inline function 'kotlin.js.unsafeCast' call
10538
+ // Inline function 'kotlin.js.asDynamic' call
10539
+ piecesItalian = ['', '', 'C', 'A', 'T', 'D', 'R', '', 'C', 'A', 'T', 'D', 'R'];
10540
+ // Inline function 'kotlin.arrayOf' call
10541
+ // Inline function 'kotlin.js.unsafeCast' call
10542
+ // Inline function 'kotlin.js.asDynamic' call
10543
+ piecesDutch = ['', '', 'P', 'L', 'T', 'D', 'K', '', 'P', 'L', 'T', 'D', 'K'];
10448
10544
  }
10449
10545
  }
10450
10546
  function yieldComputeVisible() {
@@ -10743,7 +10839,7 @@ function yieldComputeZobristHash() {
10743
10839
  }
10744
10840
  while (inductionVariable_2 < 64);
10745
10841
  var t2 = System_instance.rg();
10746
- logger.mn(t1, t2);
10842
+ logger.nn(t1, t2);
10747
10843
  return yieldComputeZobristHash$lambda(zobristTable, zobristTurn, zobristCastle, zobristEnPassant);
10748
10844
  }
10749
10845
  function yieldComputeZobristHash$lambda($zobristTable, $zobristTurn, $zobristCastle, $zobristEnPassant) {
@@ -10923,19 +11019,19 @@ var properties_initialized_Piece_kt_ae3dia;
10923
11019
  function _init_properties_Piece_kt__xog22k() {
10924
11020
  if (!properties_initialized_Piece_kt_ae3dia) {
10925
11021
  properties_initialized_Piece_kt_ae3dia = true;
10926
- EMPTY_0 = Companion_getInstance_9().bs_1.c1(0);
10927
- WP_0 = Companion_getInstance_9().bs_1.c1(1);
10928
- WN_0 = Companion_getInstance_9().bs_1.c1(2);
10929
- WB_0 = Companion_getInstance_9().bs_1.c1(3);
10930
- WR_0 = Companion_getInstance_9().bs_1.c1(4);
10931
- WQ_0 = Companion_getInstance_9().bs_1.c1(5);
10932
- WK_0 = Companion_getInstance_9().bs_1.c1(6);
10933
- BP_0 = Companion_getInstance_9().bs_1.c1(7);
10934
- BN_0 = Companion_getInstance_9().bs_1.c1(8);
10935
- BB_0 = Companion_getInstance_9().bs_1.c1(9);
10936
- BR_0 = Companion_getInstance_9().bs_1.c1(10);
10937
- BQ_0 = Companion_getInstance_9().bs_1.c1(11);
10938
- BK_0 = Companion_getInstance_9().bs_1.c1(12);
11022
+ EMPTY_0 = Companion_getInstance_9().cs_1.c1(0);
11023
+ WP_0 = Companion_getInstance_9().cs_1.c1(1);
11024
+ WN_0 = Companion_getInstance_9().cs_1.c1(2);
11025
+ WB_0 = Companion_getInstance_9().cs_1.c1(3);
11026
+ WR_0 = Companion_getInstance_9().cs_1.c1(4);
11027
+ WQ_0 = Companion_getInstance_9().cs_1.c1(5);
11028
+ WK_0 = Companion_getInstance_9().cs_1.c1(6);
11029
+ BP_0 = Companion_getInstance_9().cs_1.c1(7);
11030
+ BN_0 = Companion_getInstance_9().cs_1.c1(8);
11031
+ BB_0 = Companion_getInstance_9().cs_1.c1(9);
11032
+ BR_0 = Companion_getInstance_9().cs_1.c1(10);
11033
+ BQ_0 = Companion_getInstance_9().cs_1.c1(11);
11034
+ BK_0 = Companion_getInstance_9().cs_1.c1(12);
10939
11035
  }
10940
11036
  }
10941
11037
  function get_WHITE() {
@@ -10958,8 +11054,8 @@ var properties_initialized_Side_kt_xjv14p;
10958
11054
  function _init_properties_Side_kt__trrix5() {
10959
11055
  if (!properties_initialized_Side_kt_xjv14p) {
10960
11056
  properties_initialized_Side_kt_xjv14p = true;
10961
- WHITE_0 = Companion_getInstance_10().ts_1.c1(0);
10962
- BLACK_0 = Companion_getInstance_10().ts_1.c1(1);
11057
+ WHITE_0 = Companion_getInstance_10().us_1.c1(0);
11058
+ BLACK_0 = Companion_getInstance_10().us_1.c1(1);
10963
11059
  }
10964
11060
  }
10965
11061
  function get_A1() {
@@ -11292,70 +11388,70 @@ var properties_initialized_Square_kt_d57phb;
11292
11388
  function _init_properties_Square_kt__qeygot() {
11293
11389
  if (!properties_initialized_Square_kt_d57phb) {
11294
11390
  properties_initialized_Square_kt_d57phb = true;
11295
- A1_0 = Companion_getInstance_11().vs_1.c1(0);
11296
- B1_0 = Companion_getInstance_11().vs_1.c1(1);
11297
- C1_0 = Companion_getInstance_11().vs_1.c1(2);
11298
- D1_0 = Companion_getInstance_11().vs_1.c1(3);
11299
- E1_0 = Companion_getInstance_11().vs_1.c1(4);
11300
- F1_0 = Companion_getInstance_11().vs_1.c1(5);
11301
- G1_0 = Companion_getInstance_11().vs_1.c1(6);
11302
- H1_0 = Companion_getInstance_11().vs_1.c1(7);
11303
- A2_0 = Companion_getInstance_11().vs_1.c1(8);
11304
- B2_0 = Companion_getInstance_11().vs_1.c1(9);
11305
- C2_0 = Companion_getInstance_11().vs_1.c1(10);
11306
- D2_0 = Companion_getInstance_11().vs_1.c1(11);
11307
- E2_0 = Companion_getInstance_11().vs_1.c1(12);
11308
- F2_0 = Companion_getInstance_11().vs_1.c1(13);
11309
- G2_0 = Companion_getInstance_11().vs_1.c1(14);
11310
- H2_0 = Companion_getInstance_11().vs_1.c1(15);
11311
- A3_0 = Companion_getInstance_11().vs_1.c1(16);
11312
- B3_0 = Companion_getInstance_11().vs_1.c1(17);
11313
- C3_0 = Companion_getInstance_11().vs_1.c1(18);
11314
- D3_0 = Companion_getInstance_11().vs_1.c1(19);
11315
- E3_0 = Companion_getInstance_11().vs_1.c1(20);
11316
- F3_0 = Companion_getInstance_11().vs_1.c1(21);
11317
- G3_0 = Companion_getInstance_11().vs_1.c1(22);
11318
- H3_0 = Companion_getInstance_11().vs_1.c1(23);
11319
- A4_0 = Companion_getInstance_11().vs_1.c1(24);
11320
- B4_0 = Companion_getInstance_11().vs_1.c1(25);
11321
- C4_0 = Companion_getInstance_11().vs_1.c1(26);
11322
- D4_0 = Companion_getInstance_11().vs_1.c1(27);
11323
- E4_0 = Companion_getInstance_11().vs_1.c1(28);
11324
- F4_0 = Companion_getInstance_11().vs_1.c1(29);
11325
- G4_0 = Companion_getInstance_11().vs_1.c1(30);
11326
- H4_0 = Companion_getInstance_11().vs_1.c1(31);
11327
- A5_0 = Companion_getInstance_11().vs_1.c1(32);
11328
- B5_0 = Companion_getInstance_11().vs_1.c1(33);
11329
- C5_0 = Companion_getInstance_11().vs_1.c1(34);
11330
- D5_0 = Companion_getInstance_11().vs_1.c1(35);
11331
- E5_0 = Companion_getInstance_11().vs_1.c1(36);
11332
- F5_0 = Companion_getInstance_11().vs_1.c1(37);
11333
- G5_0 = Companion_getInstance_11().vs_1.c1(38);
11334
- H5_0 = Companion_getInstance_11().vs_1.c1(39);
11335
- A6_0 = Companion_getInstance_11().vs_1.c1(40);
11336
- B6_0 = Companion_getInstance_11().vs_1.c1(41);
11337
- C6_0 = Companion_getInstance_11().vs_1.c1(42);
11338
- D6_0 = Companion_getInstance_11().vs_1.c1(43);
11339
- E6_0 = Companion_getInstance_11().vs_1.c1(44);
11340
- F6_0 = Companion_getInstance_11().vs_1.c1(45);
11341
- G6_0 = Companion_getInstance_11().vs_1.c1(46);
11342
- H6_0 = Companion_getInstance_11().vs_1.c1(47);
11343
- A7_0 = Companion_getInstance_11().vs_1.c1(48);
11344
- B7_0 = Companion_getInstance_11().vs_1.c1(49);
11345
- C7_0 = Companion_getInstance_11().vs_1.c1(50);
11346
- D7_0 = Companion_getInstance_11().vs_1.c1(51);
11347
- E7_0 = Companion_getInstance_11().vs_1.c1(52);
11348
- F7_0 = Companion_getInstance_11().vs_1.c1(53);
11349
- G7_0 = Companion_getInstance_11().vs_1.c1(54);
11350
- H7_0 = Companion_getInstance_11().vs_1.c1(55);
11351
- A8_0 = Companion_getInstance_11().vs_1.c1(56);
11352
- B8_0 = Companion_getInstance_11().vs_1.c1(57);
11353
- C8_0 = Companion_getInstance_11().vs_1.c1(58);
11354
- D8_0 = Companion_getInstance_11().vs_1.c1(59);
11355
- E8_0 = Companion_getInstance_11().vs_1.c1(60);
11356
- F8_0 = Companion_getInstance_11().vs_1.c1(61);
11357
- G8_0 = Companion_getInstance_11().vs_1.c1(62);
11358
- H8_0 = Companion_getInstance_11().vs_1.c1(63);
11391
+ A1_0 = Companion_getInstance_11().ws_1.c1(0);
11392
+ B1_0 = Companion_getInstance_11().ws_1.c1(1);
11393
+ C1_0 = Companion_getInstance_11().ws_1.c1(2);
11394
+ D1_0 = Companion_getInstance_11().ws_1.c1(3);
11395
+ E1_0 = Companion_getInstance_11().ws_1.c1(4);
11396
+ F1_0 = Companion_getInstance_11().ws_1.c1(5);
11397
+ G1_0 = Companion_getInstance_11().ws_1.c1(6);
11398
+ H1_0 = Companion_getInstance_11().ws_1.c1(7);
11399
+ A2_0 = Companion_getInstance_11().ws_1.c1(8);
11400
+ B2_0 = Companion_getInstance_11().ws_1.c1(9);
11401
+ C2_0 = Companion_getInstance_11().ws_1.c1(10);
11402
+ D2_0 = Companion_getInstance_11().ws_1.c1(11);
11403
+ E2_0 = Companion_getInstance_11().ws_1.c1(12);
11404
+ F2_0 = Companion_getInstance_11().ws_1.c1(13);
11405
+ G2_0 = Companion_getInstance_11().ws_1.c1(14);
11406
+ H2_0 = Companion_getInstance_11().ws_1.c1(15);
11407
+ A3_0 = Companion_getInstance_11().ws_1.c1(16);
11408
+ B3_0 = Companion_getInstance_11().ws_1.c1(17);
11409
+ C3_0 = Companion_getInstance_11().ws_1.c1(18);
11410
+ D3_0 = Companion_getInstance_11().ws_1.c1(19);
11411
+ E3_0 = Companion_getInstance_11().ws_1.c1(20);
11412
+ F3_0 = Companion_getInstance_11().ws_1.c1(21);
11413
+ G3_0 = Companion_getInstance_11().ws_1.c1(22);
11414
+ H3_0 = Companion_getInstance_11().ws_1.c1(23);
11415
+ A4_0 = Companion_getInstance_11().ws_1.c1(24);
11416
+ B4_0 = Companion_getInstance_11().ws_1.c1(25);
11417
+ C4_0 = Companion_getInstance_11().ws_1.c1(26);
11418
+ D4_0 = Companion_getInstance_11().ws_1.c1(27);
11419
+ E4_0 = Companion_getInstance_11().ws_1.c1(28);
11420
+ F4_0 = Companion_getInstance_11().ws_1.c1(29);
11421
+ G4_0 = Companion_getInstance_11().ws_1.c1(30);
11422
+ H4_0 = Companion_getInstance_11().ws_1.c1(31);
11423
+ A5_0 = Companion_getInstance_11().ws_1.c1(32);
11424
+ B5_0 = Companion_getInstance_11().ws_1.c1(33);
11425
+ C5_0 = Companion_getInstance_11().ws_1.c1(34);
11426
+ D5_0 = Companion_getInstance_11().ws_1.c1(35);
11427
+ E5_0 = Companion_getInstance_11().ws_1.c1(36);
11428
+ F5_0 = Companion_getInstance_11().ws_1.c1(37);
11429
+ G5_0 = Companion_getInstance_11().ws_1.c1(38);
11430
+ H5_0 = Companion_getInstance_11().ws_1.c1(39);
11431
+ A6_0 = Companion_getInstance_11().ws_1.c1(40);
11432
+ B6_0 = Companion_getInstance_11().ws_1.c1(41);
11433
+ C6_0 = Companion_getInstance_11().ws_1.c1(42);
11434
+ D6_0 = Companion_getInstance_11().ws_1.c1(43);
11435
+ E6_0 = Companion_getInstance_11().ws_1.c1(44);
11436
+ F6_0 = Companion_getInstance_11().ws_1.c1(45);
11437
+ G6_0 = Companion_getInstance_11().ws_1.c1(46);
11438
+ H6_0 = Companion_getInstance_11().ws_1.c1(47);
11439
+ A7_0 = Companion_getInstance_11().ws_1.c1(48);
11440
+ B7_0 = Companion_getInstance_11().ws_1.c1(49);
11441
+ C7_0 = Companion_getInstance_11().ws_1.c1(50);
11442
+ D7_0 = Companion_getInstance_11().ws_1.c1(51);
11443
+ E7_0 = Companion_getInstance_11().ws_1.c1(52);
11444
+ F7_0 = Companion_getInstance_11().ws_1.c1(53);
11445
+ G7_0 = Companion_getInstance_11().ws_1.c1(54);
11446
+ H7_0 = Companion_getInstance_11().ws_1.c1(55);
11447
+ A8_0 = Companion_getInstance_11().ws_1.c1(56);
11448
+ B8_0 = Companion_getInstance_11().ws_1.c1(57);
11449
+ C8_0 = Companion_getInstance_11().ws_1.c1(58);
11450
+ D8_0 = Companion_getInstance_11().ws_1.c1(59);
11451
+ E8_0 = Companion_getInstance_11().ws_1.c1(60);
11452
+ F8_0 = Companion_getInstance_11().ws_1.c1(61);
11453
+ G8_0 = Companion_getInstance_11().ws_1.c1(62);
11454
+ H8_0 = Companion_getInstance_11().ws_1.c1(63);
11359
11455
  }
11360
11456
  }
11361
11457
  var Companion_instance_12;
@@ -11473,12 +11569,14 @@ protoOf(RootNode).xk = promoteChild;
11473
11569
  protoOf(RootNode).yk = promoteNode;
11474
11570
  protoOf(RootNode).zk = removeChild;
11475
11571
  protoOf(RootNode).al = hasChildren;
11572
+ protoOf(RootNode).dl = toSan;
11476
11573
  initMetadataForClass(RootNode, 'RootNode', VOID, VOID, [Node]);
11477
11574
  protoOf(MoveNode).wk = appendMove$default;
11478
11575
  protoOf(MoveNode).xk = promoteChild;
11479
11576
  protoOf(MoveNode).yk = promoteNode;
11480
11577
  protoOf(MoveNode).zk = removeChild;
11481
11578
  protoOf(MoveNode).al = hasChildren;
11579
+ protoOf(MoveNode).dl = toSan;
11482
11580
  initMetadataForClass(MoveNode, 'MoveNode', VOID, VOID, [Node]);
11483
11581
  initMetadataForClass(GameMode, 'GameMode');
11484
11582
  initMetadataForClass(ThreeRepetitionsMode, 'ThreeRepetitionsMode');