This is an automated email from the ASF dual-hosted git repository.

kou pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git


The following commit(s) were added to refs/heads/master by this push:
     new 205e6da  ARROW-7470: [JS] fix typos
205e6da is described below

commit 205e6da57671da3107eaedfef1a6470f2947820a
Author: Kazuaki Ishizaki <[email protected]>
AuthorDate: Fri Dec 27 08:48:57 2019 +0900

    ARROW-7470: [JS] fix typos
    
    This PR fixes typos in files under `js` directory
    
    Closes #6098 from kiszk/ARROW-7470 and squashes the following commits:
    
    2d734dada <Kazuaki Ishizaki> address review comment
    912c4e554 <Kazuaki Ishizaki> fix typos
    
    Authored-by: Kazuaki Ishizaki <[email protected]>
    Signed-off-by: Sutou Kouhei <[email protected]>
---
 js/bin/json-to-arrow.js              |  2 +-
 js/gulp/closure-task.js              |  4 +--
 js/src/compute/predicate.ts          |  4 +--
 js/src/util/bn.ts                    |  2 +-
 js/src/util/vector.ts                | 52 ++++++++++++++++++------------------
 js/tsconfig/tsconfig.bin.cjs.json    |  3 +--
 js/tsconfig/tsconfig.es2015.cjs.json |  2 +-
 js/tsconfig/tsconfig.es2015.cls.json |  2 +-
 js/tsconfig/tsconfig.es2015.esm.json |  2 +-
 js/tsconfig/tsconfig.es5.cjs.json    |  2 +-
 js/tsconfig/tsconfig.es5.cls.json    |  2 +-
 js/tsconfig/tsconfig.es5.esm.json    |  2 +-
 js/tsconfig/tsconfig.esnext.cjs.json |  2 +-
 js/tsconfig/tsconfig.esnext.cls.json |  2 +-
 js/tsconfig/tsconfig.esnext.esm.json |  2 +-
 15 files changed, 42 insertions(+), 43 deletions(-)

diff --git a/js/bin/json-to-arrow.js b/js/bin/json-to-arrow.js
index 7a98d56..fdd8a6f 100755
--- a/js/bin/json-to-arrow.js
+++ b/js/bin/json-to-arrow.js
@@ -85,7 +85,7 @@ function print_usage() {
     console.log(require('command-line-usage')([
         {
             header: 'json-to-arrow',
-            content: 'Script for converting an JSON Arrow file to a binary 
Arrow file'
+            content: 'Script for converting a JSON Arrow file to a binary 
Arrow file'
         },
         {
             header: 'Synopsis',
diff --git a/js/gulp/closure-task.js b/js/gulp/closure-task.js
index 163f23b..fff7f9c 100644
--- a/js/gulp/closure-task.js
+++ b/js/gulp/closure-task.js
@@ -58,7 +58,7 @@ const closureTask = ((cache) => memoizeTask(cache, async 
function closure(target
 
     await Promise.all([
         fs.promises.writeFile(externs, generateExternsFile(exportedImports)),
-        fs.promises.writeFile(entry_point, 
generateUMDExportAssignnent(srcAbsolute, exportedImports))
+        fs.promises.writeFile(entry_point, 
generateUMDExportAssignment(srcAbsolute, exportedImports))
     ]);
 
     return await Promise.all([
@@ -112,7 +112,7 @@ const createClosureArgs = (entry_point, externs) => ({
 }(this, (function (exports) {%output%}.bind(this))));`
 });
 
-function generateUMDExportAssignnent(src, exportedImports) {
+function generateUMDExportAssignment(src, exportedImports) {
     return [
         ...exportedImports.map(({ publicModulePath }, i) => {
             const p = publicModulePath.slice(src.length + 1);
diff --git a/js/src/compute/predicate.ts b/js/src/compute/predicate.ts
index ec947d2..fe0cd8e 100644
--- a/js/src/compute/predicate.ts
+++ b/js/src/compute/predicate.ts
@@ -127,7 +127,7 @@ export abstract class CombinationPredicate extends 
Predicate {
         this.children = children;
     }
 }
-// add children to protoype so it doesn't get mangled in es2015/umd
+// add children to prototype so it doesn't get mangled in es2015/umd
 (<any> CombinationPredicate.prototype).children = Object.freeze([]); // freeze 
for safety
 
 /** @ignore */
@@ -208,7 +208,7 @@ export class Equals extends ComparisonPredicate {
     }
 
     protected _bindLitCol(batch: RecordBatch, lit: Literal, col: Col) {
-        // Equals is comutative
+        // Equals is commutative
         return this._bindColLit(batch, col, lit);
     }
 }
diff --git a/js/src/util/bn.ts b/js/src/util/bn.ts
index 0970ea4..46b394e 100644
--- a/js/src/util/bn.ts
+++ b/js/src/util/bn.ts
@@ -175,7 +175,7 @@ export interface BN<T extends BigNumArray> extends 
TypedArrayLike<T> {
     toString(): string;
     /**
      * Down-convert the bytes to a 53-bit precision integer. Invoked by JS for
-     * arithmatic operators, like `+`. Easy (and unsafe) way to convert BN to
+     * arithmetic operators, like `+`. Easy (and unsafe) way to convert BN to
      * number via `+bn_inst`
      */
     valueOf(): number;
diff --git a/js/src/util/vector.ts b/js/src/util/vector.ts
index 56cd2e3..4a46593 100644
--- a/js/src/util/vector.ts
+++ b/js/src/util/vector.ts
@@ -97,28 +97,28 @@ export function createElementComparator(search: any) {
 
 /** @ignore */
 function createArrayLikeComparator(lhs: ArrayLike<any>) {
-    const comparitors = [] as ((x: any) => boolean)[];
+    const comparators = [] as ((x: any) => boolean)[];
     for (let i = -1, n = lhs.length; ++i < n;) {
-        comparitors[i] = createElementComparator(lhs[i]);
+        comparators[i] = createElementComparator(lhs[i]);
     }
-    return createSubElementsComparator(comparitors);
+    return createSubElementsComparator(comparators);
 }
 
 /** @ignore */
 function creatMapComparator(lhs: Map<any, any>) {
     let i = -1;
-    const comparitors = [] as ((x: any) => boolean)[];
-    lhs.forEach((v) => comparitors[++i] = createElementComparator(v));
-    return createSubElementsComparator(comparitors);
+    const comparators = [] as ((x: any) => boolean)[];
+    lhs.forEach((v) => comparators[++i] = createElementComparator(v));
+    return createSubElementsComparator(comparators);
 }
 
 /** @ignore */
 function createVectorComparator(lhs: Vector<any>) {
-    const comparitors = [] as ((x: any) => boolean)[];
+    const comparators = [] as ((x: any) => boolean)[];
     for (let i = -1, n = lhs.length; ++i < n;) {
-        comparitors[i] = createElementComparator(lhs.get(i));
+        comparators[i] = createElementComparator(lhs.get(i));
     }
-    return createSubElementsComparator(comparitors);
+    return createSubElementsComparator(comparators);
 }
 
 /** @ignore */
@@ -126,65 +126,65 @@ function createObjectComparator(lhs: any) {
     const keys = Object.keys(lhs);
     // Only compare non-empty Objects
     if (keys.length === 0) { return () => false; }
-    const comparitors = [] as ((x: any) => boolean)[];
+    const comparators = [] as ((x: any) => boolean)[];
     for (let i = -1, n = keys.length; ++i < n;) {
-        comparitors[i] = createElementComparator(lhs[keys[i]]);
+        comparators[i] = createElementComparator(lhs[keys[i]]);
     }
-    return createSubElementsComparator(comparitors, keys);
+    return createSubElementsComparator(comparators, keys);
 }
 
-function createSubElementsComparator(comparitors: ((x: any) => boolean)[], 
keys?: Iterable<string>) {
+function createSubElementsComparator(comparators: ((x: any) => boolean)[], 
keys?: Iterable<string>) {
     return (rhs: any) => {
         if (!rhs || typeof rhs !== 'object') {
             return false;
         }
         switch (rhs.constructor) {
-            case Array: return compareArray(comparitors, rhs);
+            case Array: return compareArray(comparators, rhs);
             case Map:
             case MapRow:
             case StructRow:
-                return compareObject(comparitors, rhs, rhs.keys());
+                return compareObject(comparators, rhs, rhs.keys());
             case Object:
             case undefined: // support `Object.create(null)` objects
-                return compareObject(comparitors, rhs, keys || 
Object.keys(rhs));
+                return compareObject(comparators, rhs, keys || 
Object.keys(rhs));
         }
-        return rhs instanceof Vector ? compareVector(comparitors, rhs) : false;
+        return rhs instanceof Vector ? compareVector(comparators, rhs) : false;
     };
 }
 
-function compareArray(comparitors: ((x: any) => boolean)[], arr: any[]) {
-    const n = comparitors.length;
+function compareArray(comparators: ((x: any) => boolean)[], arr: any[]) {
+    const n = comparators.length;
     if (arr.length !== n) { return false; }
     for (let i = -1; ++i < n;) {
-        if (!(comparitors[i](arr[i]))) { return false; }
+        if (!(comparators[i](arr[i]))) { return false; }
     }
     return true;
 }
 
-function compareVector(comparitors: ((x: any) => boolean)[], vec: Vector) {
-    const n = comparitors.length;
+function compareVector(comparators: ((x: any) => boolean)[], vec: Vector) {
+    const n = comparators.length;
     if (vec.length !== n) { return false; }
     for (let i = -1; ++i < n;) {
-        if (!(comparitors[i](vec.get(i)))) { return false; }
+        if (!(comparators[i](vec.get(i)))) { return false; }
     }
     return true;
 }
 
-function compareObject(comparitors: ((x: any) => boolean)[], obj: Map<any, 
any>, keys: Iterable<string>) {
+function compareObject(comparators: ((x: any) => boolean)[], obj: Map<any, 
any>, keys: Iterable<string>) {
 
     const lKeyItr = keys[Symbol.iterator]();
     const rKeyItr = obj instanceof Map ? obj.keys() : 
Object.keys(obj)[Symbol.iterator]();
     const rValItr = obj instanceof Map ? obj.values() : 
Object.values(obj)[Symbol.iterator]();
 
     let i = 0;
-    let n = comparitors.length;
+    let n = comparators.length;
     let rVal = rValItr.next();
     let lKey = lKeyItr.next();
     let rKey = rKeyItr.next();
 
     for (; i < n && !lKey.done && !rKey.done && !rVal.done;
          ++i, lKey = lKeyItr.next(), rKey = rKeyItr.next(), rVal = 
rValItr.next()) {
-        if (lKey.value !== rKey.value || !comparitors[i](rVal.value)) {
+        if (lKey.value !== rKey.value || !comparators[i](rVal.value)) {
             break;
         }
     }
diff --git a/js/tsconfig/tsconfig.bin.cjs.json 
b/js/tsconfig/tsconfig.bin.cjs.json
index 4ac3e4c..d164b1a 100644
--- a/js/tsconfig/tsconfig.bin.cjs.json
+++ b/js/tsconfig/tsconfig.bin.cjs.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ES5 CommonJS bin files
+//Compiler configuration to build the ES5 CommonJS bin files
 {
     "extends": "./tsconfig.base.json",
     "exclude": ["../node_modules"],
@@ -9,4 +9,3 @@
       "declaration": false
     }
   }
-  
\ No newline at end of file
diff --git a/js/tsconfig/tsconfig.es2015.cjs.json 
b/js/tsconfig/tsconfig.es2015.cjs.json
index 7e92d5d..14a8a01 100644
--- a/js/tsconfig/tsconfig.es2015.cjs.json
+++ b/js/tsconfig/tsconfig.es2015.cjs.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ES2015 CommonJS target
+//Compiler configuration to build the ES2015 CommonJS target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.es2015.cls.json 
b/js/tsconfig/tsconfig.es2015.cls.json
index fccacb3..2714e11 100644
--- a/js/tsconfig/tsconfig.es2015.cls.json
+++ b/js/tsconfig/tsconfig.es2015.cls.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ES2015 Closure Compiler target
+//Compiler configuration to build the ES2015 Closure Compiler target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.es2015.esm.json 
b/js/tsconfig/tsconfig.es2015.esm.json
index a8b3454..024fc5f 100644
--- a/js/tsconfig/tsconfig.es2015.esm.json
+++ b/js/tsconfig/tsconfig.es2015.esm.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ES2015 ESModules target
+//Compiler configuration to build the ES2015 ESModules target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.es5.cjs.json 
b/js/tsconfig/tsconfig.es5.cjs.json
index cab55c1..bf42ff5 100644
--- a/js/tsconfig/tsconfig.es5.cjs.json
+++ b/js/tsconfig/tsconfig.es5.cjs.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ES5 CommonJS target
+//Compiler configuration to build the ES5 CommonJS target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.es5.cls.json 
b/js/tsconfig/tsconfig.es5.cls.json
index b425289..782d84a 100644
--- a/js/tsconfig/tsconfig.es5.cls.json
+++ b/js/tsconfig/tsconfig.es5.cls.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ES5 Closure Compiler target
+//Compiler configuration to build the ES5 Closure Compiler target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.es5.esm.json 
b/js/tsconfig/tsconfig.es5.esm.json
index 7780883..dadbe65 100644
--- a/js/tsconfig/tsconfig.es5.esm.json
+++ b/js/tsconfig/tsconfig.es5.esm.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ES5 ESModules target
+//Compiler configuration to build the ES5 ESModules target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.esnext.cjs.json 
b/js/tsconfig/tsconfig.esnext.cjs.json
index 06b2ee5..e64b777 100644
--- a/js/tsconfig/tsconfig.esnext.cjs.json
+++ b/js/tsconfig/tsconfig.esnext.cjs.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ESNext CommonJS target
+//Compiler configuration to build the ESNext CommonJS target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.esnext.cls.json 
b/js/tsconfig/tsconfig.esnext.cls.json
index 03206c9..a93f244 100644
--- a/js/tsconfig/tsconfig.esnext.cls.json
+++ b/js/tsconfig/tsconfig.esnext.cls.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ESNext Closure Compiler target
+//Compiler configuration to build the ESNext Closure Compiler target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {
diff --git a/js/tsconfig/tsconfig.esnext.esm.json 
b/js/tsconfig/tsconfig.esnext.esm.json
index c614f2e..bc33d12 100644
--- a/js/tsconfig/tsconfig.esnext.esm.json
+++ b/js/tsconfig/tsconfig.esnext.esm.json
@@ -1,4 +1,4 @@
-//Compiler configuaration to build the ESNext ESModules target
+//Compiler configuration to build the ESNext ESModules target
 {
   "extends": "./tsconfig.base.json",
   "compilerOptions": {

Reply via email to