Skip to content

Commit 116111e

Browse files
committed
Use typeof in benchmarks checks
1 parent 46574a7 commit 116111e

File tree

168 files changed

+247
-247
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+247
-247
lines changed

lib/node_modules/@stdlib/assert/deep-equal/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ bench( pkg, function benchmark( b ) {
8585
x = values[ xi ];
8686
y = values[ yi ];
8787
out = deepEqual( x, y );
88-
if ( !isBoolean( out ) ) {
88+
if ( typeof out !== 'boolean' ) {
8989
b.fail( 'should return a boolean' );
9090
}
9191
}

lib/node_modules/@stdlib/assert/has-arrow-function-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasArrowFunctionSupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-async-await-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasAsyncAwaitSupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-async-iterator-symbol-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasAsyncIteratorSymbolSupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-bigint-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasBigIntSupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-bigint64array-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasBigInt64ArraySupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-biguint64array-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasBigUint64ArraySupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-class-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasClassSupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-dataview-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasDataViewSupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

lib/node_modules/@stdlib/assert/has-float32array-support/benchmark/benchmark.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ bench( pkg, function benchmark( b ) {
3636
for ( i = 0; i < b.iterations; i++ ) {
3737
// Note: the following *could* be optimized away via loop-invariant code motion. If so, the entire loop will disappear.
3838
bool = hasFloat32ArraySupport();
39-
if ( !isBoolean( bool ) ) {
39+
if ( typeof bool !== 'boolean' ) {
4040
b.fail( 'should return a boolean' );
4141
}
4242
}

0 commit comments

Comments
 (0)