@@ -925,10 +925,9 @@ class VlqHexDecoder {
925
925
}
926
926
// call after consuming `{`
927
927
decodeList ( ) {
928
- const cb = "}" . charCodeAt ( 0 ) ;
929
928
let c = this . string . charCodeAt ( this . offset ) ;
930
929
const ret = [ ] ;
931
- while ( c !== cb ) {
930
+ while ( c !== 125 ) { // 125 = "}"
932
931
ret . push ( this . decode ( ) ) ;
933
932
c = this . string . charCodeAt ( this . offset ) ;
934
933
}
@@ -937,14 +936,13 @@ class VlqHexDecoder {
937
936
}
938
937
// consumes and returns a list or integer
939
938
decode ( ) {
940
- const [ ob , la ] = [ "{" , "`" ] . map ( c => c . charCodeAt ( 0 ) ) ;
941
939
let n = 0 ;
942
940
let c = this . string . charCodeAt ( this . offset ) ;
943
- if ( c === ob ) {
941
+ if ( c === 123 ) { // 123 = "{"
944
942
this . offset += 1 ;
945
943
return this . decodeList ( ) ;
946
944
}
947
- while ( c < la ) {
945
+ while ( c < 96 ) { // 96 = "`"
948
946
n = ( n << 4 ) | ( c & 0xF ) ;
949
947
this . offset += 1 ;
950
948
c = this . string . charCodeAt ( this . offset ) ;
@@ -957,15 +955,14 @@ class VlqHexDecoder {
957
955
}
958
956
next ( ) {
959
957
const c = this . string . charCodeAt ( this . offset ) ;
960
- const [ zero , ua , la ] = [ "0" , "@" , "`" ] . map ( c => c . charCodeAt ( 0 ) ) ;
961
958
// sixteen characters after "0" are backref
962
- if ( c >= zero && c < ua ) {
959
+ if ( c >= 48 && c < 64 ) { // 48 = "0", 64 = "@"
963
960
this . offset += 1 ;
964
- return this . backrefQueue [ c - zero ] ;
961
+ return this . backrefQueue [ c - 48 ] ;
965
962
}
966
963
// special exception: 0 doesn't use backref encoding
967
964
// it's already one character, and it's always nullish
968
- if ( c === la ) {
965
+ if ( c === 96 ) { // 96 = "`"
969
966
this . offset += 1 ;
970
967
return this . cons ( 0 ) ;
971
968
}
@@ -1519,7 +1516,6 @@ class DocSearch {
1519
1516
} ;
1520
1517
1521
1518
const searchIndex = [ ] ;
1522
- const charA = "A" . charCodeAt ( 0 ) ;
1523
1519
let currentIndex = 0 ;
1524
1520
let id = 0 ;
1525
1521
@@ -1685,7 +1681,7 @@ class DocSearch {
1685
1681
// object defined above.
1686
1682
const row = {
1687
1683
crate,
1688
- ty : itemTypes . charCodeAt ( i ) - charA ,
1684
+ ty : itemTypes . charCodeAt ( i ) - 65 , // 65 = "A"
1689
1685
name : itemNames [ i ] ,
1690
1686
path,
1691
1687
descShard,
0 commit comments