Skip to content

Commit

Permalink
Auto-generated commit
Browse files Browse the repository at this point in the history
  • Loading branch information
stdlib-bot committed Oct 1, 2022
1 parent e5a38b0 commit cbe1e1c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/.keepalive
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2022-09-01T01:33:59.477Z
2022-10-01T02:01:02.309Z
14 changes: 7 additions & 7 deletions docs/types/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ import ndarray = require( './index' );
}
}

// The function does not compile if provided a first argument which is not a recognized data type...
// The compiler throws an error if the function is provided a first argument which is not a recognized data type...
{
const buffer = [ 1, 2, 3, 4 ];
const shape = [ 2, 2 ];
Expand All @@ -62,7 +62,7 @@ import ndarray = require( './index' );
ndarray( undefined, buffer, shape, strides, offset, order ); // $ExpectError
}

// The function does not compile if provided a second argument which is not an array-like object or buffer...
// The compiler throws an error if the function is provided a second argument which is not an array-like object or buffer...
{
const shape = [ 2, 2 ];
const strides = [ 2, 1 ];
Expand All @@ -75,7 +75,7 @@ import ndarray = require( './index' );
ndarray( 'float64', undefined, shape, strides, offset, order ); // $ExpectError
}

// The function does not compile if provided a third argument which is not an array-like object containing numbers...
// The compiler throws an error if the function is provided a third argument which is not an array-like object containing numbers...
{
const buffer = [ 1, 2, 3, 4 ];
const strides = [ 2, 1 ];
Expand All @@ -91,7 +91,7 @@ import ndarray = require( './index' );
ndarray( 'float64', buffer, ( x: number ): number => x, strides, offset, order ); // $ExpectError
}

// The function does not compile if provided a fourth argument which is not an array-like object containing numbers...
// The compiler throws an error if the function is provided a fourth argument which is not an array-like object containing numbers...
{
const buffer = [ 1, 2, 3, 4 ];
const shape = [ 2, 2 ];
Expand All @@ -107,7 +107,7 @@ import ndarray = require( './index' );
ndarray( 'float32', buffer, shape, ( x: number ): number => x, offset, order ); // $ExpectError
}

// The function does not compile if provided a fifth argument which is not a number...
// The compiler throws an error if the function is provided a fifth argument which is not a number...
{
const buffer = [ 1, 2, 3, 4 ];
const shape = [ 2, 2 ];
Expand All @@ -123,7 +123,7 @@ import ndarray = require( './index' );
ndarray( 'int32', buffer, shape, strides, ( x: number ): number => x, order ); // $ExpectError
}

// The function does not compile if provided a sixth argument which is not a known array order...
// The compiler throws an error if the function is provided a sixth argument which is not a known array order...
{
const buffer = [ 1, 2, 3, 4 ];
const shape = [ 2, 2 ];
Expand Down Expand Up @@ -187,7 +187,7 @@ import ndarray = require( './index' );
ndarray( 'float64', buffer, shape, strides, offset, order, { 'readonly': ( x: number ): number => x } ); // $ExpectError
}

// The function does not compile if provided and invalid number of arguments...
// The compiler throws an error if the function is provided and invalid number of arguments...
{
const buffer = [ 1, 2, 3, 4 ];
const shape = [ 2, 2 ];
Expand Down

0 comments on commit cbe1e1c

Please sign in to comment.