From f7eba0fcb788ced49f091b1d992057b7d579e64d Mon Sep 17 00:00:00 2001 From: gururaj1512 Date: Tue, 21 Jan 2025 14:48:13 +0000 Subject: [PATCH 1/5] refactor: doctest for blas/base/ccopy --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: na - task: lint_repl_help status: passed - task: lint_javascript_src status: passed - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- type: pre_push_report description: Results of running various checks prior to pushing changes. report: - task: run_javascript_examples status: na - task: run_c_examples status: na - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: na - task: run_c_benchmarks status: na - task: run_cpp_benchmarks status: na - task: run_fortran_benchmarks status: na - task: run_javascript_benchmarks status: na - task: run_julia_benchmarks status: na - task: run_python_benchmarks status: na - task: run_r_benchmarks status: na - task: run_javascript_tests status: na --- --- .../@stdlib/blas/base/ccopy/README.md | 60 ++----------------- .../@stdlib/blas/base/ccopy/docs/repl.txt | 42 ++++--------- .../blas/base/ccopy/docs/types/index.d.ts | 56 +++-------------- .../@stdlib/blas/base/ccopy/lib/ccopy.js | 14 +---- .../blas/base/ccopy/lib/ccopy.native.js | 14 +---- .../@stdlib/blas/base/ccopy/lib/index.js | 28 ++------- .../@stdlib/blas/base/ccopy/lib/ndarray.js | 17 ++---- .../blas/base/ccopy/lib/ndarray.native.js | 17 ++---- 8 files changed, 41 insertions(+), 207 deletions(-) diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/README.md b/lib/node_modules/@stdlib/blas/base/ccopy/README.md index e65ef9c5c068..848a75ff4b3f 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/README.md +++ b/lib/node_modules/@stdlib/blas/base/ccopy/README.md @@ -36,22 +36,12 @@ Copies values from `x` into `y`. ```javascript var Complex64Array = require( '@stdlib/array/complex64' ); -var realf = require( '@stdlib/complex/float32/real' ); -var imagf = require( '@stdlib/complex/float32/imag' ); var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); ccopy( x.length, x, 1, y, 1 ); - -var z = y.get( 0 ); -// returns - -var re = realf( z ); -// returns 1.0 - -var im = imagf( z ); -// returns 2.0 +// y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ``` The function has the following parameters: @@ -66,22 +56,12 @@ The `N` and stride parameters determine how values from `x` are copied into `y`. ```javascript var Complex64Array = require( '@stdlib/array/complex64' ); -var realf = require( '@stdlib/complex/float32/real' ); -var imagf = require( '@stdlib/complex/float32/imag' ); var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] ); var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); ccopy( 2, x, -2, y, 1 ); - -var z = y.get( 0 ); -// returns - -var re = realf( z ); -// returns 5.0 - -var im = imagf( z ); -// returns 6.0 +// y => [ 5.0, 6.0, 1.0, 2.0, 0.0, 0.0, 0.0, 0.0 ] ``` Note that indexing is relative to the first index. To introduce an offset, use [`typed array`][mdn-typed-array] views. @@ -90,8 +70,6 @@ Note that indexing is relative to the first index. To introduce an offset, use [ ```javascript var Complex64Array = require( '@stdlib/array/complex64' ); -var realf = require( '@stdlib/complex/float32/real' ); -var imagf = require( '@stdlib/complex/float32/imag' ); // Initial arrays... var x0 = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] ); @@ -103,15 +81,7 @@ var y1 = new Complex64Array( y0.buffer, y0.BYTES_PER_ELEMENT*2 ); // start at 3r // Copy in reverse order every other value from `x1` into `y1`... ccopy( 2, x1, -2, y1, 1 ); - -var z = y0.get( 2 ); -// returns - -var re = realf( z ); -// returns 7.0 - -var im = imagf( z ); -// returns 8.0 +// y0 => [ 0.0, 0.0, 0.0, 0.0, 7.0, 8.0, 3.0, 4.0 ] ``` #### ccopy.ndarray( N, x, strideX, offsetX, y, strideY, offsetY ) @@ -120,22 +90,12 @@ Copies values from `x` into `y` using alternative indexing semantics. ```javascript var Complex64Array = require( '@stdlib/array/complex64' ); -var realf = require( '@stdlib/complex/float32/real' ); -var imagf = require( '@stdlib/complex/float32/imag' ); var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); - -var z = y.get( 0 ); -// returns - -var re = realf( z ); -// returns 1.0 - -var im = imagf( z ); -// returns 2.0 +// y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ``` The function has the following additional parameters: @@ -147,22 +107,12 @@ While [`typed array`][mdn-typed-array] views mandate a view offset based on the ```javascript var Complex64Array = require( '@stdlib/array/complex64' ); -var realf = require( '@stdlib/complex/float32/real' ); -var imagf = require( '@stdlib/complex/float32/imag' ); var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] ); var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); ccopy.ndarray( 2, x, 2, 1, y, -1, y.length-1 ); - -var z = y.get( y.length-1 ); -// returns - -var re = realf( z ); -// returns 3.0 - -var im = imagf( z ); -// returns 4.0 +// y => [ 0.0, 0.0, 0.0, 0.0, 7.0, 8.0, 3.0, 4.0 ] ``` diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/docs/repl.txt b/lib/node_modules/@stdlib/blas/base/ccopy/docs/repl.txt index f847df3f5002..fee9a2a2d08a 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/docs/repl.txt +++ b/lib/node_modules/@stdlib/blas/base/ccopy/docs/repl.txt @@ -38,34 +38,24 @@ // Standard usage: > var x = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0 ] ); > var y = new {{alias:@stdlib/array/complex64}}( [ 6.0, 7.0, 8.0, 9.0 ] ); - > {{alias}}( x.length, x, 1, y, 1 ); - > var z = y.get( 0 ); - > var re = {{alias:@stdlib/complex/float32/real}}( z ) - 1.0 - > var im = {{alias:@stdlib/complex/float32/imag}}( z ) - 2.0 + > {{alias}}( x.length, x, 1, y, 1 ) + [ 1.0, 2.0, 3.0, 4.0 ] // Advanced indexing: > x = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] ); > y = new {{alias:@stdlib/array/complex64}}( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); - > {{alias}}( 2, x, -2, y, 1 ); - > z = y.get( 0 ); - > re = {{alias:@stdlib/complex/float32/real}}( z ) - 5.0 - > im = {{alias:@stdlib/complex/float32/imag}}( z ) - 6.0 + > {{alias}}( 2, x, -2, y, 1 ) + [ 5.0, 6.0, 1.0, 2.0, 0.0, 0.0, 0.0, 0.0 ] // Using typed array views: > var x0 = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] ); > var y0 = new {{alias:@stdlib/array/complex64}}( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); > var x1 = new {{alias:@stdlib/array/complex64}}( x0.buffer, x0.BYTES_PER_ELEMENT*1 ); > var y1 = new {{alias:@stdlib/array/complex64}}( y0.buffer, y0.BYTES_PER_ELEMENT*2 ); - > {{alias}}( 2, x1, -2, y1, 1 ); - > z = y0.get( 2 ); - > re = {{alias:@stdlib/complex/float32/real}}( z ) - 7.0 - > im = {{alias:@stdlib/complex/float32/imag}}( z ) - 8.0 + > {{alias}}( 2, x1, -2, y1, 1 ) + [ 7.0, 8.0, 3.0, 4.0 ] + > y0 + [ 0.0, 0.0, 0.0, 0.0, 7.0, 8.0, 3.0, 4.0 ] {{alias}}.ndarray( N, x, strideX, offsetX, y, strideY, offsetY ) @@ -110,22 +100,14 @@ // Standard usage: > var x = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0 ] ); > var y = new {{alias:@stdlib/array/complex64}}( [ 6.0, 7.0, 8.0, 9.0 ] ); - > {{alias}}.ndarray( x.length, x, 1, 0, y, 1, 0 ); - > var z = y.get( 0 ); - > var re = {{alias:@stdlib/complex/float32/real}}( z ) - 1.0 - > var im = {{alias:@stdlib/complex/float32/imag}}( z ) - 2.0 + > {{alias}}.ndarray( x.length, x, 1, 0, y, 1, 0 ) + [ 1.0, 2.0, 3.0, 4.0 ] // Advanced indexing: > x = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] ); > y = new {{alias:@stdlib/array/complex64}}( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); - > {{alias}}.ndarray( 2, x, 2, 1, y, -1, y.length-1 ); - > z = y.get( y.length-1 ); - > re = {{alias:@stdlib/complex/float32/real}}( z ) - 3.0 - > im = {{alias:@stdlib/complex/float32/imag}}( z ) - 4.0 + > {{alias}}.ndarray( 2, x, 2, 1, y, -1, y.length-1 ) + [ 0.0, 0.0, 0.0, 0.0, 7.0, 8.0, 3.0, 4.0 ] See Also -------- diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/docs/types/index.d.ts b/lib/node_modules/@stdlib/blas/base/ccopy/docs/types/index.d.ts index 1e0ef99fa8ce..0efde304e3ee 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/blas/base/ccopy/docs/types/index.d.ts @@ -38,22 +38,12 @@ interface Routine { * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); - * var realf = require( '@stdlib/complex/float32/real' ); - * var imagf = require( '@stdlib/complex/float32/imag' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); - * var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); + * var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy( x.length, x, 1, y, 1 ); - * - * var z = y.get( 0 ); - * // returns - * - * var re = realf( z ); - * // returns 1.0 - * - * var im = imagf( z ); - * // returns 2.0 + * // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ ( N: number, x: Complex64Array, strideX: number, y: Complex64Array, strideY: number ): Complex64Array; @@ -71,22 +61,12 @@ interface Routine { * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); - * var realf = require( '@stdlib/complex/float32/real' ); - * var imagf = require( '@stdlib/complex/float32/imag' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); - * var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); + * var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); - * - * var z = y.get( 0 ); - * // returns - * - * var re = realf( z ); - * // returns 1.0 - * - * var im = imagf( z ); - * // returns 2.0 + * // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ ndarray( N: number, x: Complex64Array, strideX: number, offsetX: number, y: Complex64Array, strideY: number, offsetY: number ): Complex64Array; } @@ -103,41 +83,21 @@ interface Routine { * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy( x.length, x, 1, y, 1 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ declare var ccopy: Routine; diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.js index ca32ce9c9d46..e24a6b5a94c9 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.js @@ -38,22 +38,12 @@ var ndarray = require( './ndarray.js' ); * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy( x.length, x, 1, y, 1 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ function ccopy( N, x, strideX, y, strideY ) { var ox = stride2offset( N, strideX ); diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.native.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.native.js index bb54361a8e67..aac2e5bdd440 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.native.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ccopy.native.js @@ -38,22 +38,12 @@ var addon = require( './../src/addon.node' ); * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy( x.length, x, 1, y, 1 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ function ccopy( N, x, strideX, y, strideY ) { var viewX = reinterpret( x, 0 ); diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/index.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/index.js index 797a309b2df6..b01cc550d10b 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/index.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/index.js @@ -25,43 +25,23 @@ * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); * var ccopy = require( '@stdlib/blas/base/ccopy' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy( x.length, x, 1, y, 1 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); * var ccopy = require( '@stdlib/blas/base/ccopy' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * * ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ // MODULES // diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js index 7eba9b373669..f00e3bcf3677 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js @@ -39,22 +39,13 @@ var reinterpret = require( '@stdlib/strided/base/reinterpret-complex64' ); * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); +* var ccopy = require( '@stdlib/blas/base/ccopy' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * -* ccopy( x.length, x, 1, 0, y, 1, 0 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ function ccopy( N, x, strideX, offsetX, y, strideY, offsetY ) { var viewX; diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js index b82c32b746ff..cb1a01ac0f73 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js @@ -40,22 +40,13 @@ var addon = require( './../src/addon.node' ); * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var realf = require( '@stdlib/complex/float32/real' ); -* var imagf = require( '@stdlib/complex/float32/imag' ); +* var ccopy = require( '@stdlib/blas/base/ccopy' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); -* var y = new Complex64Array( [ 7.0, 8.0, 9.0, 10.0, 11.0, 12.0 ] ); +* var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * -* ccopy( x.length, x, 1, 0, y, 1, 0 ); -* -* var z = y.get( 0 ); -* // returns -* -* var re = realf( z ); -* // returns 1.0 -* -* var im = imagf( z ); -* // returns 2.0 +* ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); +* // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ function ccopy( N, x, strideX, offsetX, y, strideY, offsetY ) { var viewX = reinterpret( x, 0 ); From 0a764444a4151466d9de21595a6f3e583a6e01b0 Mon Sep 17 00:00:00 2001 From: Athan Date: Tue, 21 Jan 2025 12:14:29 -0800 Subject: [PATCH 2/5] docs: fix example Signed-off-by: Athan --- lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js index f00e3bcf3677..79c8decde793 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js @@ -44,7 +44,7 @@ var reinterpret = require( '@stdlib/strided/base/reinterpret-complex64' ); * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); * var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * -* ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); +* ccopy( x.length, x, 1, 0, y, 1, 0 ); * // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ function ccopy( N, x, strideX, offsetX, y, strideY, offsetY ) { From 0dc712772bcebef97f02f0346b2db6c235c92d5d Mon Sep 17 00:00:00 2001 From: Athan Date: Tue, 21 Jan 2025 12:15:04 -0800 Subject: [PATCH 3/5] docs: remove import Signed-off-by: Athan --- lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js index 79c8decde793..f9dc3448d596 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.js @@ -39,7 +39,6 @@ var reinterpret = require( '@stdlib/strided/base/reinterpret-complex64' ); * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var ccopy = require( '@stdlib/blas/base/ccopy' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); * var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); From bc2491585d9feb599b8a97d2ae203eeecadeaf90 Mon Sep 17 00:00:00 2001 From: Athan Date: Tue, 21 Jan 2025 12:16:02 -0800 Subject: [PATCH 4/5] Apply suggestions from code review Signed-off-by: Athan --- lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js index cb1a01ac0f73..2d11de701ec5 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js @@ -40,12 +40,10 @@ var addon = require( './../src/addon.node' ); * * @example * var Complex64Array = require( '@stdlib/array/complex64' ); -* var ccopy = require( '@stdlib/blas/base/ccopy' ); * * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); * var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * -* ccopy.ndarray( x.length, x, 1, 0, y, 1, 0 ); * // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ function ccopy( N, x, strideX, offsetX, y, strideY, offsetY ) { From 9cdb0d0664e81bffc417048221ea032318b0da49 Mon Sep 17 00:00:00 2001 From: Athan Date: Tue, 21 Jan 2025 12:16:58 -0800 Subject: [PATCH 5/5] docs: fix regression Signed-off-by: Athan --- lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js index 2d11de701ec5..ce1076221660 100644 --- a/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js +++ b/lib/node_modules/@stdlib/blas/base/ccopy/lib/ndarray.native.js @@ -44,6 +44,7 @@ var addon = require( './../src/addon.node' ); * var x = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] ); * var y = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] ); * +* ccopy( x.length, x, 1, 0, y, 1, 0 ); * // y => [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] */ function ccopy( N, x, strideX, offsetX, y, strideY, offsetY ) {