mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-29 07:37:57 +02:00
This is done automatically with `gulp lint --fix` and the following manual changes: ```diff diff --git a/src/core/cmap.js b/src/core/cmap.js index 850275a19..8794726dd 100644 --- a/src/core/cmap.js +++ b/src/core/cmap.js @@ -519,8 +519,8 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { readHexNumber(num, size) { let last; - let stack = this.tmpBuf, - sp = 0; + const stack = this.tmpBuf; + let sp = 0; do { const b = this.readByte(); if (b < 0) { @@ -603,7 +603,6 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { const ucs2DataSize = 1; const subitemsCount = stream.readNumber(); - var i; switch (type) { case 0: // codespacerange stream.readHex(start, dataSize); @@ -614,7 +613,7 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { hexToInt(start, dataSize), hexToInt(end, dataSize) ); - for (i = 1; i < subitemsCount; i++) { + for (let i = 1; i < subitemsCount; i++) { incHex(end, dataSize); stream.readHexNumber(start, dataSize); addHex(start, end, dataSize); @@ -633,7 +632,7 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { addHex(end, start, dataSize); stream.readNumber(); // code // undefined range, skipping - for (i = 1; i < subitemsCount; i++) { + for (let i = 1; i < subitemsCount; i++) { incHex(end, dataSize); stream.readHexNumber(start, dataSize); addHex(start, end, dataSize); @@ -647,7 +646,7 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { stream.readHex(char, dataSize); code = stream.readNumber(); cMap.mapOne(hexToInt(char, dataSize), code); - for (i = 1; i < subitemsCount; i++) { + for (let i = 1; i < subitemsCount; i++) { incHex(char, dataSize); if (!sequence) { stream.readHexNumber(tmp, dataSize); @@ -667,7 +666,7 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { hexToInt(end, dataSize), code ); - for (i = 1; i < subitemsCount; i++) { + for (let i = 1; i < subitemsCount; i++) { incHex(end, dataSize); if (!sequence) { stream.readHexNumber(start, dataSize); @@ -692,7 +691,7 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { hexToInt(char, ucs2DataSize), hexToStr(charCode, dataSize) ); - for (i = 1; i < subitemsCount; i++) { + for (let i = 1; i < subitemsCount; i++) { incHex(char, ucs2DataSize); if (!sequence) { stream.readHexNumber(tmp, ucs2DataSize); @@ -717,7 +716,7 @@ const BinaryCMapReader = (function BinaryCMapReaderClosure() { hexToInt(end, ucs2DataSize), hexToStr(charCode, dataSize) ); - for (i = 1; i < subitemsCount; i++) { + for (let i = 1; i < subitemsCount; i++) { incHex(end, ucs2DataSize); if (!sequence) { stream.readHexNumber(start, ucs2DataSize); ``` |
||
---|---|---|
.. | ||
xfa | ||
.eslintrc | ||
annotation.js | ||
arithmetic_decoder.js | ||
bidi.js | ||
catalog.js | ||
ccitt.js | ||
ccitt_stream.js | ||
cff_parser.js | ||
charsets.js | ||
chunked_stream.js | ||
cmap.js | ||
colorspace.js | ||
core_utils.js | ||
crypto.js | ||
default_appearance.js | ||
document.js | ||
encodings.js | ||
evaluator.js | ||
file_spec.js | ||
font_renderer.js | ||
fonts.js | ||
function.js | ||
glyphlist.js | ||
image.js | ||
image_utils.js | ||
jbig2.js | ||
jbig2_stream.js | ||
jpeg_stream.js | ||
jpg.js | ||
jpx.js | ||
jpx_stream.js | ||
metadata_parser.js | ||
metrics.js | ||
murmurhash3.js | ||
name_number_tree.js | ||
object_loader.js | ||
operator_list.js | ||
parser.js | ||
pattern.js | ||
pdf_manager.js | ||
primitives.js | ||
ps_parser.js | ||
standard_fonts.js | ||
stream.js | ||
struct_tree.js | ||
type1_parser.js | ||
unicode.js | ||
worker.js | ||
worker_stream.js | ||
writer.js | ||
xml_parser.js | ||
xref.js |