From 17167718d2929f96db68fdb39f88699bb25e3015 Mon Sep 17 00:00:00 2001 From: Shubham Date: Wed, 24 Dec 2025 14:22:36 +0530 Subject: [PATCH 1/2] chore: fix JavaScript lint errors (issue stdlib-js#9334) --- .../_tools/lint/header-filenames/lib/index.js | 2 +- .../tools/array-like-function/examples/index.js | 14 ++++++++------ .../constants/float32/ninf/examples/index.js | 2 +- .../math/strided/special/atan-by/test/test.main.js | 6 ++++-- 4 files changed, 14 insertions(+), 10 deletions(-) diff --git a/lib/node_modules/@stdlib/_tools/lint/header-filenames/lib/index.js b/lib/node_modules/@stdlib/_tools/lint/header-filenames/lib/index.js index b46219ed849e..a4ec78523b34 100644 --- a/lib/node_modules/@stdlib/_tools/lint/header-filenames/lib/index.js +++ b/lib/node_modules/@stdlib/_tools/lint/header-filenames/lib/index.js @@ -39,7 +39,7 @@ * var lint = require( '@stdlib/_tools/lint/header-filenames' ); * * var errs = lint.sync(); -* // returns [...] +* // returns [] */ // MODULES // diff --git a/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js b/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js index b3bc2d89f8d7..0c59d61cd88f 100644 --- a/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js +++ b/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js @@ -27,16 +27,18 @@ var bool; var f; var i; -arr1 = new Array( 25 ); -for ( i = 0; i < arr1.length; i++ ) { - arr1[ i ] = i; +arr1 = []; +for (i = 0; i < 25; i++) { + arr1.push(i); } -arr2 = new Array( 25 ); -for ( i = 0; i < arr2.length; i++ ) { - arr2[ i ] = 2 * i; + +arr2 = []; +for (i = 0; i < 25; i++) { + arr2.push(i); } + f = arraylikefcn( isEven ); bool = f( arr1 ); diff --git a/lib/node_modules/@stdlib/constants/float32/ninf/examples/index.js b/lib/node_modules/@stdlib/constants/float32/ninf/examples/index.js index 3c99460eeb50..083bfcb48d94 100644 --- a/lib/node_modules/@stdlib/constants/float32/ninf/examples/index.js +++ b/lib/node_modules/@stdlib/constants/float32/ninf/examples/index.js @@ -21,4 +21,4 @@ var FLOAT32_NINF = require( './../lib' ); console.log( FLOAT32_NINF ); -// => -infinity +// => -Infinity diff --git a/lib/node_modules/@stdlib/math/strided/special/atan-by/test/test.main.js b/lib/node_modules/@stdlib/math/strided/special/atan-by/test/test.main.js index 7907d9455995..434c15763b69 100644 --- a/lib/node_modules/@stdlib/math/strided/special/atan-by/test/test.main.js +++ b/lib/node_modules/@stdlib/math/strided/special/atan-by/test/test.main.js @@ -74,7 +74,8 @@ tape( 'the function computes the arctangent via a callback function', function t atanBy( x.length, x, 1, y, 1, accessor ); t.deepEqual( y, expected, 'deep equal' ); - x = new Array( 5 ); // sparse array + x = []; + x.length = 5; //sparse array y = [ 0.0, 0.0, 0.0, 0.0, 0.0 ]; expected = [ 0.0, 0.0, 0.0, 0.0, 0.0 ]; @@ -82,7 +83,8 @@ tape( 'the function computes the arctangent via a callback function', function t atanBy( x.length, x, 1, y, 1, accessor ); t.deepEqual( y, expected, 'deep equal' ); - x = new Array( 5 ); // sparse array + x = []; + x.length = 5; //sparse array x[ 2 ] = rand(); y = [ 0.0, 0.0, 0.0, 0.0, 0.0 ]; From 816de3b9b68ccd2fdd6ac003e2a8945da9e9b61b Mon Sep 17 00:00:00 2001 From: Shubham Date: Wed, 24 Dec 2025 14:34:50 +0530 Subject: [PATCH 2/2] chore: fix JavaScript lint errors (issue stdlib-js#9334) Signed-off-by: Shubham --- .../assert/tools/array-like-function/examples/index.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js b/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js index 0c59d61cd88f..71aa34999dd4 100644 --- a/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js +++ b/lib/node_modules/@stdlib/assert/tools/array-like-function/examples/index.js @@ -29,16 +29,14 @@ var i; arr1 = []; for (i = 0; i < 25; i++) { - arr1.push(i); + arr1.push(i); } - arr2 = []; for (i = 0; i < 25; i++) { - arr2.push(i); + arr2.push(i); } - f = arraylikefcn( isEven ); bool = f( arr1 );