diff --git a/.editorconfig b/.editorconfig deleted file mode 100644 index dab5d2a..0000000 --- a/.editorconfig +++ /dev/null @@ -1,180 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2017 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# EditorConfig configuration file (see <http://editorconfig.org/>). - -# Indicate that this file is a root-level configuration file: -root = true - -# Set properties for all files: -[*] -end_of_line = lf -charset = utf-8 -trim_trailing_whitespace = true -insert_final_newline = true - -# Set properties for JavaScript files: -[*.{js,js.txt}] -indent_style = tab - -# Set properties for JavaScript ES module files: -[*.{mjs,mjs.txt}] -indent_style = tab - -# Set properties for JavaScript CommonJS files: -[*.{cjs,cjs.txt}] -indent_style = tab - -# Set properties for JSON files: -[*.{json,json.txt}] -indent_style = space -indent_size = 2 - -# Set properties for `cli_opts.json` files: -[cli_opts.json] -indent_style = tab - -# Set properties for TypeScript files: -[*.ts] -indent_style = tab - -# Set properties for Python files: -[*.{py,py.txt}] -indent_style = space -indent_size = 4 - -# Set properties for Julia files: -[*.{jl,jl.txt}] -indent_style = tab - -# Set properties for R files: -[*.{R,R.txt}] -indent_style = tab - -# Set properties for C files: -[*.{c,c.txt}] -indent_style = tab - -# Set properties for C header files: -[*.{h,h.txt}] -indent_style = tab - -# Set properties for C++ files: -[*.{cpp,cpp.txt}] -indent_style = tab - -# Set properties for C++ header files: -[*.{hpp,hpp.txt}] -indent_style = tab - -# Set properties for Fortran files: -[*.{f,f.txt}] -indent_style = space -indent_size = 2 - -# Set properties for shell files: -[*.{sh,sh.txt}] -indent_style = tab - -# Set properties for AWK files: -[*.{awk,awk.txt}] -indent_style = tab - -# Set properties for HTML files: -[*.{html,html.txt}] -indent_style = tab -tab_width = 2 - -# Set properties for XML files: -[*.{xml,xml.txt}] -indent_style = tab -tab_width = 2 - -# Set properties for CSS files: -[*.{css,css.txt}] -indent_style = tab - -# Set properties for Makefiles: -[Makefile] -indent_style = tab - -[*.{mk,mk.txt}] -indent_style = tab - -# Set properties for Markdown files: -[*.{md,md.txt}] -indent_style = space -indent_size = 4 -trim_trailing_whitespace = true # Note: this disables using two spaces to force a hard line break, which is permitted in Markdown. As we don't typically follow that practice (TMK), we should be safe to automatically trim. - -# Set properties for `usage.txt` files: -[usage.txt] -indent_style = space -indent_size = 2 - -# Set properties for `repl.txt` files: -[repl.txt] -indent_style = space -indent_size = 4 - -# Set properties for `package.json` files: -[package.{json,json.txt}] -indent_style = space -indent_size = 2 - -# Set properties for `datapackage.json` files: -[datapackage.json] -indent_style = space -indent_size = 2 - -# Set properties for `manifest.json` files: -[manifest.json] -indent_style = space -indent_size = 2 - -# Set properties for `tsconfig.json` files: -[tsconfig.json] -indent_style = space -indent_size = 2 - -# Set properties for LaTeX files: -[*.{tex,tex.txt}] -indent_style = tab - -# Set properties for LaTeX Bibliography files: -[*.{bib,bib.txt}] -indent_style = tab - -# Set properties for YAML files: -[*.{yml,yml.txt}] -indent_style = space -indent_size = 2 - -# Set properties for GYP files: -[binding.gyp] -indent_style = space -indent_size = 2 - -[*.gypi] -indent_style = space -indent_size = 2 - -# Set properties for citation files: -[*.{cff,cff.txt}] -indent_style = space -indent_size = 2 diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index 5f30286..0000000 --- a/.eslintrc.js +++ /dev/null @@ -1 +0,0 @@ -/* For the `eslint` rules of this project, consult the main repository at https://github.com/stdlib-js/stdlib */ diff --git a/.gitattributes b/.gitattributes deleted file mode 100644 index 1c88e69..0000000 --- a/.gitattributes +++ /dev/null @@ -1,66 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2017 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Configuration file which assigns attributes to pathnames. -# -# [1]: https://git-scm.com/docs/gitattributes - -# Automatically normalize the line endings of any committed text files: -* text=auto - -# Override line endings for certain files on checkout: -*.crlf.csv text eol=crlf - -# Denote that certain files are binary and should not be modified: -*.png binary -*.jpg binary -*.jpeg binary -*.gif binary -*.ico binary -*.gz binary -*.zip binary -*.7z binary -*.mp3 binary -*.mp4 binary -*.mov binary - -# Override what is considered "vendored" by GitHub's linguist: -/lib/node_modules/** -linguist-vendored -linguist-generated - -# Configure directories which should *not* be included in GitHub language statistics: -/deps/** linguist-vendored -/dist/** linguist-generated -/workshops/** linguist-vendored - -benchmark/** linguist-vendored -docs/* linguist-documentation -etc/** linguist-vendored -examples/** linguist-documentation -scripts/** linguist-vendored -test/** linguist-vendored -tools/** linguist-vendored - -# Configure files which should *not* be included in GitHub language statistics: -Makefile linguist-vendored -*.mk linguist-vendored -*.jl linguist-vendored -*.py linguist-vendored -*.R linguist-vendored - -# Configure files which should be included in GitHub language statistics: -docs/types/*.d.ts -linguist-documentation diff --git a/.github/.keepalive b/.github/.keepalive deleted file mode 100644 index 1b055ac..0000000 --- a/.github/.keepalive +++ /dev/null @@ -1 +0,0 @@ -2025-03-10T01:10:43.661Z diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md deleted file mode 100644 index cafa019..0000000 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ /dev/null @@ -1,7 +0,0 @@ -<!-- ----------^ Click "Preview"! --> - -We are excited about your pull request, but unfortunately we are not accepting pull requests against this repository, as all development happens on the [main project repository](https://github.com/stdlib-js/stdlib). We kindly request that you submit this pull request against the [respective directory](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/array/base/group-entries) of the main repository where we’ll review and provide feedback. - -If this is your first stdlib contribution, be sure to read the [contributing guide](https://github.com/stdlib-js/stdlib/blob/develop/CONTRIBUTING.md) which provides guidelines and instructions for submitting contributions. You may also consult the [development guide](https://github.com/stdlib-js/stdlib/blob/develop/docs/contributing/development.md) for help on developing stdlib. - -We look forward to receiving your contribution! :smiley: \ No newline at end of file diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml deleted file mode 100644 index e4f10fe..0000000 --- a/.github/workflows/benchmark.yml +++ /dev/null @@ -1,64 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: benchmark - -# Workflow triggers: -on: - # Allow the workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - - # Define a job to run benchmarks: - benchmark: - - # Define a display name: - name: 'Run benchmarks' - - # Define the type of virtual host machine: - runs-on: 'ubuntu-latest' - - # Define the sequence of job steps... - steps: - - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production and development dependencies' - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Run benchmarks: - - name: 'Run benchmarks' - run: | - npm run benchmark diff --git a/.github/workflows/cancel.yml b/.github/workflows/cancel.yml deleted file mode 100644 index b5291db..0000000 --- a/.github/workflows/cancel.yml +++ /dev/null @@ -1,57 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: cancel - -# Workflow triggers: -on: - # Allow the workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - - # Define a job to cancel existing workflow runs: - cancel: - - # Define a display name: - name: 'Cancel workflow runs' - - # Define the type of virtual host machine: - runs-on: 'ubuntu-latest' - - # Time limit: - timeout-minutes: 3 - - # Define the sequence of job steps... - steps: - - # Cancel existing workflow runs: - - name: 'Cancel existing workflow runs' - # Pin action to full length commit SHA - uses: styfle/cancel-workflow-action@85880fa0301c86cca9da44039ee3bb12d3bedbfa # v0.12.1 - with: - workflow_id: >- - benchmark.yml, - examples.yml, - test.yml, - test_coverage.yml, - test_install.yml, - publish.yml - access_token: ${{ github.token }} diff --git a/.github/workflows/close_pull_requests.yml b/.github/workflows/close_pull_requests.yml deleted file mode 100644 index 6a720bc..0000000 --- a/.github/workflows/close_pull_requests.yml +++ /dev/null @@ -1,54 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: close_pull_requests - -# Workflow triggers: -on: - pull_request_target: - types: [opened] - -# Workflow jobs: -jobs: - - # Define job to close all pull requests: - run: - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define the sequence of job steps... - steps: - - # Close pull request - - name: 'Close pull request' - # Pin action to full length commit SHA corresponding to v3.1.2 - uses: superbrothers/close-pull-request@9c18513d320d7b2c7185fb93396d0c664d5d8448 - with: - comment: | - Thank you for submitting a pull request. :raised_hands: - - We greatly appreciate your willingness to submit a contribution. However, we are not accepting pull requests against this repository, as all development happens on the [main project repository](https://github.com/stdlib-js/stdlib). - - We kindly request that you submit this pull request against the [respective directory](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/array/base/group-entries) of the main repository where we’ll review and provide feedback. If this is your first stdlib contribution, be sure to read the [contributing guide](https://github.com/stdlib-js/stdlib/blob/develop/CONTRIBUTING.md) which provides guidelines and instructions for submitting contributions. - - Thank you again, and we look forward to receiving your contribution! :smiley: - - Best, - The stdlib team \ No newline at end of file diff --git a/.github/workflows/examples.yml b/.github/workflows/examples.yml deleted file mode 100644 index 2984901..0000000 --- a/.github/workflows/examples.yml +++ /dev/null @@ -1,64 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: examples - -# Workflow triggers: -on: - # Allow the workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - - # Define a job to run the package examples... - examples: - - # Define display name: - name: 'Run examples' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define the sequence of job steps... - steps: - - # Checkout repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production and development dependencies' - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Run examples: - - name: 'Run examples' - run: | - npm run examples diff --git a/.github/workflows/npm_downloads.yml b/.github/workflows/npm_downloads.yml deleted file mode 100644 index 3f9c7c5..0000000 --- a/.github/workflows/npm_downloads.yml +++ /dev/null @@ -1,112 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2022 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: npm_downloads - -# Workflow triggers: -on: - # Run this workflow weekly: - schedule: - # cron: '<minutes> <hours> <day_of_month> <month> <day_of_week>' - - cron: '53 17 * * 2' - - # Allow the workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - - # Define a job for retrieving npm download counts... - npm_downloads: - - # Define display name: - name: 'Retrieve npm download counts' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define the sequence of job steps... - steps: - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - timeout-minutes: 10 - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Resolve package name: - - name: 'Resolve package name' - id: package_name - run: | - name=`node -e 'console.log(require("./package.json").name)' | tr -d '\n'` - echo "package_name=$name" >> $GITHUB_OUTPUT - timeout-minutes: 5 - - # Fetch download data: - - name: 'Fetch data' - id: download_data - run: | - url="https://api.npmjs.org/downloads/range/$(date --date='1 year ago' '+%Y-%m-%d'):$(date '+%Y-%m-%d')/${{ steps.package_name.outputs.package_name }}" - echo "$url" - data=$(curl "$url") - mkdir ./tmp - echo "$data" > ./tmp/npm_downloads.json - echo "data=$data" >> $GITHUB_OUTPUT - timeout-minutes: 5 - - # Print summary of download data: - - name: 'Print summary' - run: | - echo "| Date | Downloads |" >> $GITHUB_STEP_SUMMARY - echo "|------|------------|" >> $GITHUB_STEP_SUMMARY - cat ./tmp/npm_downloads.json | jq -r ".downloads | .[-14:] | to_entries | map(\"| \(.value.day) | \(.value.downloads) |\") |.[]" >> $GITHUB_STEP_SUMMARY - - # Upload the download data: - - name: 'Upload data' - # Pin action to full length commit SHA - uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1 - with: - # Define a name for the uploaded artifact (ensuring a unique name for each job): - name: npm_downloads - - # Specify the path to the file to upload: - path: ./tmp/npm_downloads.json - - # Specify the number of days to retain the artifact (default is 90 days): - retention-days: 90 - timeout-minutes: 10 - if: success() - - # Send data to events server: - - name: 'Post data' - # Pin action to full length commit SHA - uses: distributhor/workflow-webhook@48a40b380ce4593b6a6676528cd005986ae56629 # v3.0.3 - env: - webhook_url: ${{ secrets.STDLIB_NPM_DOWNLOADS_URL }} - webhook_secret: ${{ secrets.STDLIB_WEBHOOK_SECRET }} - data: '{ "downloads": ${{ steps.download_data.outputs.data }} }' - timeout-minutes: 5 - if: success() diff --git a/.github/workflows/productionize.yml b/.github/workflows/productionize.yml deleted file mode 100644 index f4575e9..0000000 --- a/.github/workflows/productionize.yml +++ /dev/null @@ -1,794 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2022 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: productionize - -# Workflow triggers: -on: - # Run workflow when a new commit is pushed to the main branch: - push: - branches: - - main - - # Allow the workflow to be manually run: - workflow_dispatch: - inputs: - require-passing-tests: - description: 'Require passing tests for creating bundles' - type: boolean - default: true - - # Run workflow upon completion of `publish` workflow run: - workflow_run: - workflows: ["publish"] - types: [completed] - - -# Concurrency group to prevent multiple concurrent executions: -concurrency: - group: productionize - cancel-in-progress: true - -# Workflow jobs: -jobs: - - # Define a job to create a production build... - productionize: - - # Define display name: - name: 'Productionize' - - # Define the type of virtual host machine: - runs-on: 'ubuntu-latest' - - # Define the sequence of job steps... - steps: - # Checkout main branch of repository: - - name: 'Checkout main branch' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - with: - ref: main - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Create production branch: - - name: 'Create production branch' - run: | - git checkout -b production - - # Transform error messages: - - name: 'Transform error messages' - id: transform-error-messages - uses: stdlib-js/transform-errors-action@main - - # Change `@stdlib/string-format` to `@stdlib/error-tools-fmtprodmsg` in package.json if the former is a dependency, otherwise insert it as a dependency: - - name: 'Update dependencies in package.json' - run: | - PKG_VERSION=$(npm view @stdlib/error-tools-fmtprodmsg version) - if grep -q '"@stdlib/string-format"' package.json; then - sed -i "s/\"@stdlib\/string-format\": \"^.*\"/\"@stdlib\/error-tools-fmtprodmsg\": \"^$PKG_VERSION\"/g" package.json - else - node -e "var pkg = require( './package.json' ); pkg.dependencies[ '@stdlib/error-tools-fmtprodmsg' ] = '^$PKG_VERSION'; require( 'fs' ).writeFileSync( 'package.json', JSON.stringify( pkg, null, 2 ) );" - fi - - # Configure Git: - - name: 'Configure Git' - run: | - git config --local user.email "noreply@stdlib.io" - git config --local user.name "stdlib-bot" - - # Commit changes: - - name: 'Commit changes' - run: | - git add -A - git commit -m "Transform error messages" - - # Push changes: - - name: 'Push changes' - run: | - SLUG=${{ github.repository }} - echo "Pushing changes to $SLUG..." - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" production --force - - # Define a job for running tests of the productionized code... - test: - - # Define a display name: - name: 'Run Tests' - - # Define the type of virtual host machine: - runs-on: 'ubuntu-latest' - - # Indicate that this job depends on the prior job finishing: - needs: productionize - - # Run this job regardless of the outcome of the prior job: - if: always() - - # Define the sequence of job steps... - steps: - - # Checkout the repository: - - name: 'Checkout repository' - if: ${{ github.event.inputs.require-passing-tests == 'true' }} - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - with: - # Use the `production` branch: - ref: production - - # Install Node.js: - - name: 'Install Node.js' - if: ${{ github.event.inputs.require-passing-tests == 'true' }} - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production and development dependencies' - if: ${{ github.event.inputs.require-passing-tests == 'true' }} - id: install - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Build native add-on if present: - - name: 'Build native add-on (if present)' - if: ${{ github.event.inputs.require-passing-tests == 'true' }} - run: | - if [ -f "binding.gyp" ]; then - npm install node-gyp --no-save && ./node_modules/.bin/node-gyp rebuild - fi - - # Run tests: - - name: 'Run tests' - if: ${{ github.event.inputs.require-passing-tests == 'true' }} - id: tests - run: | - npm test || npm test || npm test - - # Define job to create a bundle for use in Deno... - deno: - - # Define display name: - name: 'Create Deno bundle' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Indicate that this job depends on the test job finishing: - needs: test - - # Define the sequence of job steps... - steps: - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Configure Git: - - name: 'Configure Git' - run: | - git config --local user.email "noreply@stdlib.io" - git config --local user.name "stdlib-bot" - - # Check if remote `deno` branch exists: - - name: 'Check if remote `deno` branch exists' - id: deno-branch-exists - continue-on-error: true - run: | - git fetch --all - git ls-remote --exit-code --heads origin deno - if [ $? -eq 0 ]; then - echo "remote-exists=true" >> $GITHUB_OUTPUT - else - echo "remote-exists=false" >> $GITHUB_OUTPUT - fi - - # If `deno` exists, delete everything in branch and merge `production` into it - - name: 'If `deno` exists, delete everything in branch and merge `production` into it' - if: steps.deno-branch-exists.outputs.remote-exists - run: | - git checkout -b deno origin/deno - - find . -type 'f' | grep -v -e ".git/" -e "package.json" -e "README.md" -e "LICENSE" -e "CONTRIBUTORS" -e "NOTICE" | xargs -r rm - find . -mindepth 1 -type 'd' | grep -v -e ".git" | xargs -r rm -rf - - git add -A - git commit -m "Remove files" --allow-empty - - git config merge.theirs.name 'simulate `-s theirs`' - git config merge.theirs.driver 'cat %B > %A' - GIT_CONFIG_PARAMETERS="'merge.default=theirs'" git merge origin/production --allow-unrelated-histories - - # Copy files from `production` branch if necessary: - git checkout origin/production -- . - if [ -n "$(git status --porcelain)" ]; then - git add -A - git commit -m "Auto-generated commit" - fi - - # If `deno` does not exist, create `deno` branch: - - name: 'If `deno` does not exist, create `deno` branch' - if: ${{ steps.deno-branch-exists.outputs.remote-exists == false }} - run: | - git checkout production - git checkout -b deno - - # Copy files to deno directory: - - name: 'Copy files to deno directory' - run: | - mkdir -p deno - cp README.md LICENSE CONTRIBUTORS NOTICE ./deno - - # Copy TypeScript definitions to deno directory: - if [ -d index.d.ts ]; then - cp index.d.ts ./deno/index.d.ts - fi - if [ -e ./docs/types/index.d.ts ]; then - cp ./docs/types/index.d.ts ./deno/mod.d.ts - fi - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: Install production and development dependencies - id: install - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Bundle package for use in Deno: - - name: 'Bundle package for Deno' - id: deno-bundle - uses: stdlib-js/bundle-action@main - with: - target: 'deno' - - # Rewrite file contents: - - name: 'Rewrite file contents' - run: | - # Replace links to other packages with links to the deno branch: - find ./deno -type f -name '*.md' -print0 | xargs -0 sed -Ei "/\/tree\/main/b; /^\[@stdlib[^:]+: https:\/\/github.com\/stdlib-js\// s/(.*)/\\1\/tree\/deno/"; - - # Replace reference to `@stdlib/types` with CDN link: - find ./deno -type f -name '*.ts' -print0 | xargs -0 -r sed -Ei "s/\/\/\/ <reference types=\"@stdlib\/types\"\/>/\/\/\/ <reference types=\"https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js\/types@main\/index.d.ts\"\/>/g" - - # Change wording of project description to avoid reference to JavaScript and Node.js: - find ./deno -type f -name '*.md' -print0 | xargs -0 sed -Ei "s/a standard library for JavaScript and Node.js, /a standard library /g" - - # Rewrite all `require()`s to use jsDelivr links: - find ./deno -type f -name '*.md' -print0 | xargs -0 sed -Ei "/require\( '@stdlib\// { - s/(var|let|const)\s+([a-z0-9_]+)\s+=\s*require\( '([^']+)' \);/import \2 from \'\3\';/i - s/@stdlib/https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js/ - s/';/@deno\/mod.js';/ - }" - - # Rewrite first `import` to show importing of named exports if available: - exports=$(cat lib/index.js | \ - grep -E 'setReadOnly\(.*,.*,.*\)' | \ - sed -E 's/setReadOnly\((.*),(.*),(.*)\);/\2/' | \ - sed -E "s/'//g" | \ - sort) - if [ -n "$exports" ]; then - find ./deno -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/\`\`\`javascript\nimport\s+([a-zA-Z0-9_]+)\s+from\s*'([^']+)';\n\`\`\`/\`\`\`javascript\nimport \1 from '\2';\n\`\`\`\n\nYou can also import the following named exports from the package:\n\n\`\`\`javascript\nimport { $(echo $exports | sed -E 's/ /, /g') } from '\2';\n\`\`\`/" - fi - - # Remove `installation`, `cli`, and `c` sections: - find ./deno -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<section class=\"installation\">[^<]+<\/section>//g;" - find ./deno -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"cli\">[\s\S]+<\!\-\- \/.cli \-\->//g" - find ./deno -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"c\">[\s\S]+<\!\-\- \/.c \-\->//g" - - # Create package.json file for deno branch: - jq --indent 2 '{"name": .name, "version": .version, "description": .description, "license": .license, "type": "module", "main": "./mod.js", "homepage": .homepage, "repository": .repository, "bugs": .bugs, "keywords": .keywords, "funding": .funding}' package.json > ./deno/package.json - - # Delete everything in current directory aside from deno folder: - - name: 'Delete everything in current directory aside from deno folder' - run: | - find . -type 'f' | grep -v -e "deno" -e ".git/" | xargs -r rm - find . -mindepth 1 -type 'd' | grep -v -e "deno" -e ".git" | xargs -r rm -rf - - # Move deno directory to root: - - name: 'Move deno directory to root' - run: | - mv ./deno/* . - rmdir ./deno - - # Commit changes: - - name: 'Commit changes' - run: | - git add -A - git commit -m "Auto-generated commit" - - # Push changes to `deno` branch: - - name: 'Push changes to `deno` branch' - run: | - SLUG=${{ github.repository }} - echo "Pushing changes to $SLUG..." - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" deno - - # Send status to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() - - # Define job to create a UMD bundle... - umd: - - # Define display name: - name: 'Create UMD bundle' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Indicate that this job depends on the test job finishing: - needs: test - - # Define the sequence of job steps... - steps: - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Configure Git: - - name: 'Configure Git' - run: | - git config --local user.email "noreply@stdlib.io" - git config --local user.name "stdlib-bot" - - # Check if remote `umd` branch exists: - - name: 'Check if remote `umd` branch exists' - id: umd-branch-exists - continue-on-error: true - run: | - git fetch --all - git ls-remote --exit-code --heads origin umd - if [ $? -eq 0 ]; then - echo "remote-exists=true" >> $GITHUB_OUTPUT - else - echo "remote-exists=false" >> $GITHUB_OUTPUT - fi - - # If `umd` exists, delete everything in branch and merge `production` into it - - name: 'If `umd` exists, delete everything in branch and merge `production` into it' - if: steps.umd-branch-exists.outputs.remote-exists - run: | - git checkout -b umd origin/umd - - find . -type 'f' | grep -v -e ".git/" -e "package.json" -e "README.md" -e "LICENSE" -e "CONTRIBUTORS" -e "NOTICE" | xargs -r rm - find . -mindepth 1 -type 'd' | grep -v -e ".git" | xargs -r rm -rf - - git add -A - git commit -m "Remove files" --allow-empty - - git config merge.theirs.name 'simulate `-s theirs`' - git config merge.theirs.driver 'cat %B > %A' - GIT_CONFIG_PARAMETERS="'merge.default=theirs'" git merge origin/production --allow-unrelated-histories - - # Copy files from `production` branch if necessary: - git checkout origin/production -- . - if [ -n "$(git status --porcelain)" ]; then - git add -A - git commit -m "Auto-generated commit" - fi - - # If `umd` does not exist, create `umd` branch: - - name: 'If `umd` does not exist, create `umd` branch' - if: ${{ steps.umd-branch-exists.outputs.remote-exists == false }} - run: | - git checkout production - git checkout -b umd - - # Copy files to umd directory: - - name: 'Copy files to umd directory' - run: | - mkdir -p umd - cp README.md LICENSE CONTRIBUTORS NOTICE ./umd - - # Install Node.js - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production and development dependencies' - id: install - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Extract alias: - - name: 'Extract alias' - id: extract-alias - run: | - alias=$(grep -E 'require\(' README.md | head -n 1 | sed -E 's/^var ([a-zA-Z0-9_]+) = .+/\1/') - echo "alias=${alias}" >> $GITHUB_OUTPUT - - # Create Universal Module Definition (UMD) Node.js bundle: - - name: 'Create Universal Module Definition (UMD) Node.js bundle' - id: umd-bundle-node - uses: stdlib-js/bundle-action@main - with: - target: 'umd-node' - alias: ${{ steps.extract-alias.outputs.alias }} - - # Create Universal Module Definition (UMD) browser bundle: - - name: 'Create Universal Module Definition (UMD) browser bundle' - id: umd-bundle-browser - uses: stdlib-js/bundle-action@main - with: - target: 'umd-browser' - alias: ${{ steps.extract-alias.outputs.alias }} - - # Rewrite file contents: - - name: 'Rewrite file contents' - run: | - - # Replace links to other packages with links to the umd branch: - find ./umd -type f -name '*.md' -print0 | xargs -0 sed -Ei "/\/tree\/main/b; /^\[@stdlib[^:]+: https:\/\/github.com\/stdlib-js\// s/(.*)/\\1\/tree\/umd/"; - - # Remove `installation`, `cli`, and `c` sections: - find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<section class=\"installation\">[^<]+<\/section>//g;" - find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"cli\">[\s\S]+<\!\-\- \/.cli \-\->//g" - find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"c\">[\s\S]+<\!\-\- \/.c \-\->//g" - - # Rewrite first `require()` to show consumption of the UMD bundle in Observable and via a `script` tag: - find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/\`\`\`javascript\n(var|let|const)\s+([a-zA-Z0-9_]+)\s+=\s*require\( '\@stdlib\/([^']+)' \);\n\`\`\`/To use in Observable,\n\n\`\`\`javascript\n\2 = require\( 'https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js\/\3\@umd\/browser.js' \)\n\`\`\`\n\nTo vendor stdlib functionality and avoid installing dependency trees for Node.js, you can use the UMD server build:\n\n\`\`\`javascript\nvar \2 = require\( 'path\/to\/vendor\/umd\/\3\/index.js' \)\n\`\`\`\n\nTo include the bundle in a webpage,\n\n\`\`\`html\n<script type=\"text\/javascript\" src=\"https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js\/\3\@umd\/browser.js\"><\/script>\n\`\`\`\n\nIf no recognized module system is present, access bundle contents via the global scope:\n\n\`\`\`html\n<script type=\"text\/javascript\">\n window.\2;\n<\/script>\n\`\`\`/" - - # Rewrite examples section to be a HTML file: - find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/\#\# Examples([\s\S]*)\`\`\`javascript([\s\S]+?)\`\`\`/\#\# Examples\1\`\`\`html\n<\!DOCTYPE html>\n<html lang=\"en\">\n<body>\n<script type=\"text\/javascript\">\2\n<\/script>\n<\/body>\n<\/html>\n\`\`\`/" - - # Rewrite all `require()`s in the examples section as `script` tags loading the respective UMD bundle: - find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "1 while s/<script type=\"text\/javascript\">\n(var|let|const)\s+([a-zA-Z0-9_]+)\s+=\s*require\( '\@stdlib\/([^']+)' \);?/<script type=\"text\/javascript\" src=\"https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js\/\3\@umd\/browser.js\"><\/script>\n<script type=\"text\/javascript\">/g" - - # Wrap contents of `<script type="text/javascript">` tag contents in an IIFE: - find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<script type=\"text\/javascript\">([\s\S]+?)<\/script>/<script type=\"text\/javascript\">\n\(function \(\) {\1}\)\(\);\n<\/script>/g" - - # Create package.json file for umd branch: - jq --indent 2 '{"name": .name, "version": .version, "description": .description, "license": .license, "main": "./index.js", "homepage": .homepage, "repository": .repository, "bugs": .bugs, "keywords": .keywords, "funding": .funding}' package.json > ./umd/package.json - - # Delete everything in current directory aside from umd folder: - - name: 'Delete everything in current directory aside from umd folder' - run: | - find . -type 'f' | grep -v -e "umd" -e ".git/" | xargs -r rm - find . -mindepth 1 -type 'd' | grep -v -e "umd" -e ".git" | xargs -r rm -rf - - # Move umd directory to root: - - name: 'Move umd directory to root' - run: | - mv ./umd/* . - rmdir ./umd - - # Commit changes: - - name: 'Commit changes' - run: | - git add -A - git commit -m "Auto-generated commit" - - # Push changes to `umd` branch: - - name: 'Push changes to `umd` branch' - run: | - SLUG=${{ github.repository }} - echo "Pushing changes to $SLUG..." - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" umd - - # Send status to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() - - # Define job to create ES module build... - esm: - - # Define display name: - name: 'Create ES module build' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Indicate that this job depends on the test job finishing: - needs: test - - # Define the sequence of job steps... - steps: - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Configure Git: - - name: 'Configure Git' - run: | - git config --local user.email "noreply@stdlib.io" - git config --local user.name "stdlib-bot" - - # Check if remote `esm` branch exists: - - name: 'Check if remote `esm` branch exists' - id: esm-branch-exists - continue-on-error: true - run: | - git fetch --all - git ls-remote --exit-code --heads origin esm - if [ $? -eq 0 ]; then - echo "remote-exists=true" >> $GITHUB_OUTPUT - else - echo "remote-exists=false" >> $GITHUB_OUTPUT - fi - - # If `esm` exists, delete everything in branch and merge `production` into it - - name: 'If `esm` exists, delete everything in branch and merge `production` into it' - if: steps.esm-branch-exists.outputs.remote-exists - run: | - git checkout -b esm origin/esm - - find . -type 'f' | grep -v -e ".git/" -e "package.json" -e "README.md" -e "LICENSE" -e "CONTRIBUTORS" -e "NOTICE" | xargs -r rm - find . -mindepth 1 -type 'd' | grep -v -e ".git" | xargs -r rm -rf - - git add -A - git commit -m "Remove files" --allow-empty - - git config merge.theirs.name 'simulate `-s theirs`' - git config merge.theirs.driver 'cat %B > %A' - GIT_CONFIG_PARAMETERS="'merge.default=theirs'" git merge origin/production --allow-unrelated-histories - - # Copy files from `production` branch if necessary: - git checkout origin/production -- . - if [ -n "$(git status --porcelain)" ]; then - git add -A - git commit -m "Auto-generated commit" - fi - - # If `esm` does not exist, create `esm` branch: - - name: 'If `esm` does not exist, create `esm` branch' - if: ${{ steps.esm-branch-exists.outputs.remote-exists == false }} - run: | - git checkout production - git checkout -b esm - - # Copy files to esm directory: - - name: 'Copy files to esm directory' - run: | - mkdir -p esm - cp README.md LICENSE CONTRIBUTORS NOTICE ./esm - - # Copy TypeScript definitions to esm directory: - if [ -e ./docs/types/index.d.ts ]; then - cp ./docs/types/index.d.ts ./esm/index.d.ts - fi - if [ -d index.d.ts ]; then - cp index.d.ts ./esm/index.d.ts - fi - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production and development dependencies' - id: install - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Create ES Module (ESM) bundle: - - name: 'Create ES Module (ESM) bundle' - id: esm-bundle - uses: stdlib-js/bundle-action@main - with: - target: 'esm' - - # Rewrite file contents: - - name: 'Rewrite file contents' - run: | - - # Replace links to other packages with links to the esm branch: - find ./esm -type f -name '*.md' -print0 | xargs -0 sed -Ei "/\/tree\/main/b; /^\[@stdlib[^:]+: https:\/\/github.com\/stdlib-js\// s/(.*)/\\1\/tree\/esm/"; - - # Replace reference to `@stdlib/types` with esm link: - find ./esm -type f -name '*.ts' -print0 | xargs -0 -r sed -Ei "s/\/\/\/ <reference types=\"@stdlib\/types\"\/>/\/\/\/ <reference types=\"https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js\/types@esm\/index.d.ts\"\/>/g" - - # Change wording of project description to avoid reference to JavaScript and Node.js: - find ./esm -type f -name '*.md' -print0 | xargs -0 sed -Ei "s/a standard library for JavaScript and Node.js, /a standard library /g" - - # Rewrite all `require()`s to use jsDelivr links: - find ./esm -type f -name '*.md' -print0 | xargs -0 sed -Ei "/require\( '@stdlib\// { - s/(var|let|const)\s+([a-z0-9_]+)\s+=\s*require\( '([^']+)' \);/import \2 from \'\3\';/i - s/@stdlib/https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js/ - s/';/@esm\/index.mjs';/ - }" - - # Rewrite first `import` to show importing of named exports if available: - exports=$(cat lib/index.js | \ - grep -E 'setReadOnly\(.*,.*,.*\)' | \ - sed -E 's/setReadOnly\((.*),(.*),(.*)\);/\2/' | \ - sed -E "s/'//g" | \ - sort) - if [ -n "$exports" ]; then - find ./esm -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/\`\`\`javascript\nimport\s+([a-zA-Z0-9_]+)\s+from\s*'([^']+)';\n\`\`\`/\`\`\`javascript\nimport \1 from '\2';\n\`\`\`\n\nYou can also import the following named exports from the package:\n\n\`\`\`javascript\nimport { $(echo $exports | sed -E 's/ /, /g') } from '\2';\n\`\`\`/" - fi - - # Remove `installation`, `cli`, and `c` sections: - find ./esm -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<section class=\"installation\">[^<]+<\/section>//g;" - find ./esm -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"cli\">[\s\S]+<\!\-\- \/.cli \-\->//g" - find ./esm -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"c\">[\s\S]+<\!\-\- \/.c \-\->//g" - - # Rewrite examples section to be a HTML file: - find ./esm -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/\#\# Examples([\s\S]*)\`\`\`javascript([\s\S]+?)\`\`\`/\#\# Examples\1\`\`\`html\n<\!DOCTYPE html>\n<html lang=\"en\">\n<body>\n<script type=\"module\">\n\2\n<\/script>\n<\/body>\n<\/html>\n\`\`\`/g" - - # Create package.json file for esm branch: - jq --indent 2 '{"name": .name, "version": .version, "description": .description, "license": .license, "type": "module", "main": "./index.mjs", "homepage": .homepage, "repository": .repository, "bugs": .bugs, "keywords": .keywords, "funding": .funding}' package.json > ./esm/package.json - - # Delete everything in current directory aside from esm folder: - - name: 'Delete everything in current directory aside from esm folder' - run: | - find . -type 'f' | grep -v -e "esm" -e ".git/" | xargs -r rm - find . -mindepth 1 -type 'd' | grep -v -e "esm" -e ".git" | xargs -r rm -rf - - # Move esm directory to root: - - name: 'Move esm directory to root' - run: | - mv ./esm/* . - rmdir ./esm - - # Commit changes: - - name: 'Commit changes' - run: | - git add -A - git commit -m "Auto-generated commit" - - # Push changes to `esm` branch: - - name: 'Push changes to `esm` branch' - run: | - SLUG=${{ github.repository }} - echo "Pushing changes to $SLUG..." - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" esm - - # Send status to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() - - # Define job that succeeds if all bundles were successfully built: - create-tag-bundles: - - # Define display name: - name: 'Create tag bundles' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Indicate that this job depends on the bundle jobs finishing: - needs: [ deno, umd, esm ] - - # Define the steps to be executed: - steps: - - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - with: - fetch-depth: 2 - - # Check if workflow run was triggered by a patch, minor, or major version bump: - - name: 'Check if workflow run was triggered by a patch, minor, or major version bump' - id: check-if-bump - continue-on-error: true - run: | - VERSION_CHANGE_PKG_JSON=$(git diff HEAD~1 HEAD package.json | grep '"version":') - if [ -z "$VERSION_CHANGE_PKG_JSON" ]; then - echo "This workflow was not triggered by a version bump." - echo "bump=false" >> $GITHUB_OUTPUT - else - echo "This workflow was triggered by a version bump." - echo "bump=true" >> $GITHUB_OUTPUT - fi - - # Configure Git: - - name: 'Configure Git' - if: steps.check-if-bump.outputs.bump - run: | - git config --local user.email "noreply@stdlib.io" - git config --local user.name "stdlib-bot" - git fetch --all - - # Create bundle tags: - - name: 'Create bundle tags' - if: steps.check-if-bump.outputs.bump - run: | - SLUG=${{ github.repository }} - ESCAPED=$(echo $SLUG | sed -E 's/\//\\\//g') - VERSION="v$(jq --raw-output '.version' package.json)" - - git checkout -b deno origin/deno - sed -i -E "s/$ESCAPED@deno/$ESCAPED@$VERSION-deno/g" README.md - git add README.md - git commit -m "Update README.md for Deno bundle $VERSION" - git tag -a $VERSION-deno -m "$VERSION-deno" - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" $VERSION-deno - sed -i -E "s/$ESCAPED@$VERSION-deno/$ESCAPED@deno/g" README.md - - perl -0777 -i -pe "s/\`\`\`javascript\nimport\s+([a-zA-Z0-9_]+)\s+from\s*'([^']+)';\n\`\`\`/\`\`\`javascript\nimport \1 from '\2';\n\`\`\`\n\The previous example will load the latest bundled code from the deno branch. Alternatively, you may load a specific version by loading the file from one of the \[tagged bundles\]\(https:\/\/github.com\/$ESCAPED\/tags\). For example,\n\n\`\`\`javascript\nimport \1 from 'https:\/\/cdn\.jsdelivr\.net\/gh\/$ESCAPED\@$VERSION-deno\/mod\.js';\n\`\`\`/" README.md - - git add README.md - git commit -m "Auto-generated commit" - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" deno - - git checkout -b umd origin/umd - sed -i -E "s/$ESCAPED@umd/$ESCAPED@$VERSION-umd/g" README.md - git add README.md - git commit -m "Update README.md for UMD bundle $VERSION" - git tag -a $VERSION-umd -m "$VERSION-umd" - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" $VERSION-umd - sed -i -E "s/$ESCAPED@$VERSION-umd/$ESCAPED@umd/g" README.md - - perl -0777 -i -pe "s/\`\`\`javascript\n([a-zA-Z0-9_]+)\s+=\s*require\(\s*'([^']+)'\s*\)\n\`\`\`/\`\`\`javascript\n\1 = require\( '\2' \)\n\`\`\`\n\The previous example will load the latest bundled code from the umd branch. Alternatively, you may load a specific version by loading the file from one of the \[tagged bundles\]\(https:\/\/github.com\/$ESCAPED\/tags\). For example,\n\n\`\`\`javascript\n\1 = require\( 'https:\/\/cdn\.jsdelivr\.net\/gh\/$ESCAPED\@$VERSION-umd\/browser\.js' \)\n\`\`\`/" README.md - - git add README.md - git commit -m "Auto-generated commit" - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" umd - - git checkout -b esm origin/esm - sed -i -E "s/$ESCAPED@esm/$ESCAPED@$VERSION-esm/g" README.md - git add README.md - git commit -m "Update README.md for ESM bundle $VERSION" - git tag -a $VERSION-esm -m "$VERSION-esm" - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" $VERSION-esm - sed -i -E "s/$ESCAPED@$VERSION-esm/$ESCAPED@esm/g" README.md - - perl -0777 -i -pe "s/\`\`\`javascript\nimport\s+([a-zA-Z0-9_]+)\s+from\s*'([^']+)';\n\`\`\`/\`\`\`javascript\nimport \1 from '\2';\n\`\`\`\n\The previous example will load the latest bundled code from the esm branch. Alternatively, you may load a specific version by loading the file from one of the \[tagged bundles\]\(https:\/\/github.com\/$ESCAPED\/tags\). For example,\n\n\`\`\`javascript\nimport \1 from 'https:\/\/cdn\.jsdelivr\.net\/gh\/$ESCAPED\@$VERSION-esm\/index\.mjs';\n\`\`\`/" README.md - - git add README.md - git commit -m "Auto-generated commit" - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" esm diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml deleted file mode 100644 index 2888b88..0000000 --- a/.github/workflows/publish.yml +++ /dev/null @@ -1,252 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: publish - -# Workflow triggers: -on: - # Allow the workflow to be manually run: - workflow_dispatch: - # Workflow inputs: - inputs: - version: - description: 'Version Increment' - type: choice - default: 'none' - options: - - 'none' - - 'major' - - 'minor' - - 'patch' - - 'premajor' - - 'preminor' - - 'prepatch' - - 'prerelease' - -# Workflow jobs: -jobs: - - # Define job to publish package to npm: - publish: - - # Define display name: - name: 'Publish package to npm' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - - # Define the sequence of job steps... - steps: - - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Configure Git: - - name: 'Configure Git' - run: | - git config --local user.email "noreply@stdlib.io" - git config --local user.name "stdlib-bot" - - # Increment package version (if requested): - - name: 'Increment package version (if requested)' - if: ${{ github.event.inputs.version != 'none' }} - run: | - # Save NPM_TOKEN to user's .npmrc: - echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc - - # Increment package version: - npm version ${{ github.event.inputs.version }} --no-git-tag-version - - # Define variable for new version: - NEW_VERSION=$(node -p "require('./package.json').version") - - # Replace branch in README.md link definitions for badges with the new version: - find . -type f -name '*.md' -print0 | xargs -0 sed -Ei "s/branch([=:])[^ ]+/branch\1v${NEW_VERSION}/g" - - # Rewrite CHANGELOG.md to replace "Unreleased" with the new version: - sed -Ei "s/Unreleased/${NEW_VERSION}/g" CHANGELOG.md - sed -Ei "s/unreleased/v${NEW_VERSION}/g" CHANGELOG.md - - # Create a new commit and tag: - git add package.json README.md - git commit -m "Release v${NEW_VERSION}" - git tag -a "v${NEW_VERSION}" -m "Release v${NEW_VERSION}" - - # Push changes to GitHub: - SLUG=${{ github.repository }} - git push "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$SLUG.git" --follow-tags - - # Remove CLI: - - name: 'Remove CLI' - if: ${{ github.ref == 'refs/heads/main' }} - run: | - # Exit if the package does not have a CLI: - if ! grep -q '"bin":' package.json; then - exit 0 - fi - rm -rf ./bin/cli - rm -f test/test.cli.js - rm -f etc/cli_opts.json - rm -f docs/usage.txt - - # For all dependencies, check in all *.js files if they are still used; if not, remove them: - jq -r '.dependencies | keys[]' ./package.json | while read -r dep; do - dep=$(echo "$dep" | xargs) - if ! find lib -name "*.js" -exec grep -q "$dep" {} + && ! grep -q -s "$dep" manifest.json && ! grep -q -s "$dep" include.gypi; then - jq --indent 2 "del(.dependencies[\"$dep\"])" ./package.json > ./package.json.tmp - mv ./package.json.tmp ./package.json - fi - done - - # Set `devDependencies` to an empty object: - jq --indent 2 '.devDependencies = {}' ./package.json > ./package.json.tmp - mv ./package.json.tmp ./package.json - - # Remove CLI section: - find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"cli\">[\s\S]+?<\!\-\- \/.cli \-\->//" - - # Remove CLI from package.json: - jq -r 'del(.bin)' package.json > package.json.tmp - mv package.json.tmp package.json - - # Add entry for CLI package to See Also section of README.md: - cliPkgName=$(jq -r '.name' package.json)-cli - escapedPkg=$(echo "$cliPkgName" | sed -e 's/\//\\\//g') - escapedPkg=$(echo "$escapedPkg" | sed -e 's/\@/\\\@/g') - find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<section class=\"related\">(?:\n\n\* \* \*\n\n## See Also\n\n)?/<section class=\"related\">\n\n## See Also\n\n- <span class=\"package-name\">[\`$escapedPkg\`][$escapedPkg]<\/span><span class=\"delimiter\">: <\/span><span class=\"description\">CLI package for use as a command-line utility.<\/span>\n/" - - # Add link definition for CLI package to README.md: - find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<section class=\"links\">/<section class=\"links\">\n\n[$escapedPkg]: https:\/\/www.npmjs.com\/package\/$escapedPkg/" - - # Replace GitHub MathJax equations with SVGs: - - name: 'Replace GitHub MathJax equations with SVGs' - run: | - find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe 's/```math\n([\s\S]+?)\n```\n\n//g' - find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe 's/<!-- <div class="equation"(.*)(<\/div>\s*-->)/<div class="equation"$1<\/div>/sg' - - # Replace GitHub links to individual packages with npm links: - - name: 'Replace all GitHub links to individual packages with npm links' - run: | - find . -type f -name '*.md' -print0 | xargs -0 sed -Ei '/tree\/main/b; s/@stdlib\/([^:]*)\]: https:\/\/github.com\/stdlib-js/@stdlib\/\1\]: https:\/\/www.npmjs.com\/package\/@stdlib/g' - - # Replace list with links to other branches from installation section: - - name: 'Replace list with links to other branches from installation section' - run: | - find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/\`\`\`\n\nAlternatively,[^<]+<\/section>/\`\`\`\n\n<\/section>/" - - # Remove unnecessary files: - - name: 'Remove unnecessary files' - run: | - rm -f docs/repl.txt - rm -f docs/types/test.ts - - # Replace all stdlib GitHub dependencies with the respective npm packages: - - name: 'Replace all stdlib GitHub dependencies with the respective npm packages' - run: | - for dep in $(jq -r '.dependencies | keys | .[]' package.json); do - if [[ "$dep" != "@stdlib"* ]]; then - continue - fi - # Trim leading and trailing whitespace: - dep=$(echo "$dep" | xargs) - version="$(npm view $dep version)" - if [[ -z "$version" ]]; then - continue - fi - version="^$version" - jq -r --arg dep "$dep" --arg version "$version" '.dependencies[$dep] = $version' package.json > package.json.tmp - mv package.json.tmp package.json - done - for dep in $(jq -r '.devDependencies | keys | .[]' package.json); do - if [[ "$dep" != "@stdlib"* ]]; then - continue - fi - # Trim leading and trailing whitespace: - dep=$(echo "$dep" | xargs) - version="$(npm view $dep version)" - if [[ -z "$version" ]]; then - continue - fi - version="^$version" - jq -r --arg dep "$dep" --arg version "$version" '.devDependencies[$dep] = $version' package.json > package.json.tmp - mv package.json.tmp package.json - done - - # Publish package to npm: - - name: 'Publish package to npm' - # Pin action to full length commit SHA - uses: JS-DevTools/npm-publish@19c28f1ef146469e409470805ea4279d47c3d35c # v3.1.1 - with: - token: ${{ secrets.NPM_TOKEN }} - access: public - - # Discard any uncommitted changes: - - name: 'Discard any uncommitted changes' - run: | - git reset --hard - - # Send status to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() - - # Define job to cancel any running or queued workflow runs... - cancel: - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Time out the job after 3 minutes: - timeout-minutes: 3 - - # Define the sequence of job steps... - steps: - - # Cancel any running or queued workflow runs: - - name: 'Cancel running or queued workflow runs' - # Pin action to full length commit SHA - uses: styfle/cancel-workflow-action@85880fa0301c86cca9da44039ee3bb12d3bedbfa # v0.12.1 - with: - workflow_id: >- - benchmark.yml, - examples.yml, - test.yml, - test_coverage.yml, - test_install.yml, - publish.yml - access_token: ${{ github.token }} diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml deleted file mode 100644 index 7d95535..0000000 --- a/.github/workflows/test.yml +++ /dev/null @@ -1,99 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: test - -# Workflow triggers: -on: - # Run workflow on a weekly schedule: - schedule: - # * is a special character in YAML so you have to quote this string - - cron: '53 17 * * 2' - - # Allow the workflow to be manually run: - workflow_dispatch: - - # Run workflow on each push to the main branch: - push: - - # Run workflow upon completion of `publish` workflow run: - workflow_run: - workflows: ["publish"] - types: [completed] - -# Workflow jobs: -jobs: - - # Define job to run tests... - test: - - # Define display name: - name: 'Run tests' - - # Define the type of virtual host machine: - runs-on: 'ubuntu-latest' - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - - # Define the sequence of job steps... - steps: - - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production and development dependencies' - id: install - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Build native add-on if present: - - name: 'Build native add-on (if present)' - run: | - if [ -f "binding.gyp" ]; then - npm install node-gyp --no-save && ./node_modules/.bin/node-gyp rebuild - fi - - # Run tests: - - name: 'Run tests' - id: tests - run: | - npm test || npm test || npm test - - # Send status to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() diff --git a/.github/workflows/test_bundles.yml b/.github/workflows/test_bundles.yml deleted file mode 100644 index 5b5879a..0000000 --- a/.github/workflows/test_bundles.yml +++ /dev/null @@ -1,186 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2022 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: test_bundles - -# Workflow triggers: -on: - # Run workflow upon completion of `productionize` workflow run: - workflow_run: - workflows: ["productionize"] - types: [completed] - - # Allow workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - - # Define job to test UMD bundles... - test-umd: - - # Define display name: - name: 'Test UMD Bundles' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - - # Define the sequence of job steps... - steps: - # Checkout UMD branch of the repository: - - name: 'Checkout branch with UMD build' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - with: - ref: umd - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - - # Try loading the UMD bundle: - - name: 'Try loading UMD bundle' - run: | - node --eval "require( './index.js' )" || exit $? - - # Install playwright for headless browser testing: - - name: 'Install playwright' - run: | - npm install playwright - npx playwright install --with-deps chromium - - # Try loading the UMD browser bundle with playwright: - - name: 'Try loading UMD browser bundle with playwright' - run: | - PLAYWRIGHT_SCRIPT="\ - const { chromium } = require( 'playwright' );\ - (async () => {\ - const browser = await chromium.launch();\ - const page = await browser.newPage();\ - page.on( 'pageerror', exception => {\ - throw new Error( exception.message );\ - });\ - await page.addScriptTag({ path: './browser.js' });\ - await browser.close();\ - })();" - node --eval "$PLAYWRIGHT_SCRIPT" || exit $? - - # Send notification to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() - - # Define job to test ES modules... - test-esm: - - # Define display name: - name: 'Test ES Modules' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - - # Define the sequence of job steps... - steps: - - # Checkout ES modules branch of the repository: - - name: 'Checkout branch with ESM build' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - with: - ref: esm - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - - # Try loading the ES module bundle: - - name: 'Try loading ESM' - run: | - node --experimental-network-imports --eval "import( './index.mjs' )" || exit $? - - # Send notification to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() - - # Define job to test Deno bundles... - test-deno: - - # Define display name: - name: 'Test Deno Bundles' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - - # Define the sequence of job steps... - steps: - - # Checkout Deno branch of the repository: - - name: 'Checkout branch with Deno build' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - with: - ref: deno - - # Install Deno: - - name: 'Install Deno' - # Pin action to full length commit SHA - uses: denoland/setup-deno@041b854f97b325bd60e53e9dc2de9cb9f9ac0cba # v1.1.4 - with: - deno-version: vx.x.x - - # Try loading the Deno bundle: - - name: 'Try loading Deno build' - run: | - deno eval "import main from './mod.js'" || exit $? - - # Send notification to Slack channel if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() diff --git a/.github/workflows/test_coverage.yml b/.github/workflows/test_coverage.yml deleted file mode 100644 index 2bcf0cd..0000000 --- a/.github/workflows/test_coverage.yml +++ /dev/null @@ -1,133 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: test_coverage - -# Workflow triggers: -on: - # Run workflow upon completion of `test` workflow run: - workflow_run: - workflows: ["test"] - types: [completed] - - # Allow workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - - # Define job to run test coverage... - coverage: - - # Display name: - name: 'Calculate Test Coverage' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - - # Define the sequence of job steps... - steps: - - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production and development dependencies' - run: | - npm install || npm install || npm install - timeout-minutes: 15 - - # Build native add-on if present: - - name: 'Build native add-on (if present)' - run: | - if [ -f "binding.gyp" ]; then - npm install node-gyp --no-save && ./node_modules/.bin/node-gyp rebuild - fi - - # Calculate coverage: - - name: 'Calculate test coverage' - run: | - npm run test-cov || npm run test-cov || npm run test-cov - timeout-minutes: 15 - - # Upload coverage report to Codecov: - - name: 'Upload coverage to Codecov' - id: upload - # Pin action to full length commit SHA - uses: codecov/codecov-action@84508663e988701840491b86de86b666e8a86bed # v4.3.0 - with: - directory: reports/coverage - flags: unittests - fail_ci_if_error: true - env: - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - - # Extract coverage value: - - name: 'Extract coverage value and assign to output' - id: extract-coverage - run: | - coverage=`cat reports/coverage/lcov-report/index.html | grep "fraction" | grep -oP '\d+/\d+' | printf %s "$(cat)" | jq -R -s -c 'split("\n")'` - echo "coverage=$coverage" >> $GITHUB_OUTPUT - - # Format coverage as Markdown table row: - table=`echo $coverage | sed -e 's/,/|/g; s/"/ /g; s/\[/|/; s/\]/|/'` - echo "table=$table" >> $GITHUB_OUTPUT - - # Print coverage report to GitHub Actions log: - - name: 'Print coverage report to GitHub Actions log' - run: | - echo "## Coverage Report" >> $GITHUB_STEP_SUMMARY - echo "" >> $GITHUB_STEP_SUMMARY - echo "| Statements | Branches | Functions | Lines | " >> $GITHUB_STEP_SUMMARY - echo "| ---------- | -------- | --------- | ----- | " >> $GITHUB_STEP_SUMMARY - echo "${{ steps.extract-coverage.outputs.table }}" >> $GITHUB_STEP_SUMMARY - echo "" >> $GITHUB_STEP_SUMMARY - - # Send Slack notification if job fails: - - name: 'Send status to Slack channel in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() - - # Send data to events server: - - name: 'Post data' - # Pin action to full length commit SHA - uses: distributhor/workflow-webhook@48a40b380ce4593b6a6676528cd005986ae56629 # v3.0.3 - env: - webhook_url: ${{ secrets.STDLIB_COVERAGE_URL }} - webhook_secret: ${{ secrets.STDLIB_WEBHOOK_SECRET }} - data: '{ "coverage": ${{ steps.extract-coverage.outputs.coverage }}, "run_id": "${{ github.run_id }}" }' - if: ${{ false }} diff --git a/.github/workflows/test_install.yml b/.github/workflows/test_install.yml deleted file mode 100644 index aeb8b4c..0000000 --- a/.github/workflows/test_install.yml +++ /dev/null @@ -1,85 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: test_install - -# Workflow triggers: -on: - # Run workflow on a weekly schedule: - schedule: - # * is a special character in YAML so you have to quote this string - - cron: '53 17 * * 2' - - # Run workflow upon completion of `publish` workflow run: - workflow_run: - workflows: ["publish"] - types: [completed] - - # Allow workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - - # Define job to test installing dependencies... - test-install: - - # Define display name: - name: 'Test installing dependencies' - - # Define the type of virtual host machine on which to run the job: - runs-on: ubuntu-latest - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - - # Run workflow job if `publish` workflow run is successful or when the workflow is manually triggered or on a schedule: - if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' }} - - # Define the sequence of job steps... - steps: - - # Checkout the repository: - - name: 'Checkout repository' - # Pin action to full length commit SHA - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Install Node.js: - - name: 'Install Node.js' - # Pin action to full length commit SHA - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Install dependencies: - - name: 'Install production dependencies via npm' - run: | - npm install --only=prod || npm install --only=prod || npm install --only=prod - timeout-minutes: 15 - - # Send Slack notification if job fails: - - name: 'Send notification to Slack in case of failure' - # Pin action to full length commit SHA - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() diff --git a/.github/workflows/test_published_package.yml b/.github/workflows/test_published_package.yml deleted file mode 100644 index c46f14b..0000000 --- a/.github/workflows/test_published_package.yml +++ /dev/null @@ -1,105 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2024 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Workflow name: -name: test_published_package - -# Workflow triggers: -on: - # Run workflow on a weekly schedule: - schedule: - # * is a special character in YAML so you have to quote this string - - cron: '53 17 * * 2' - - # Run workflow upon completion of `publish` workflow run: - workflow_run: - workflows: ["publish"] - types: [completed] - - # Allow workflow to be manually run: - workflow_dispatch: - -# Workflow jobs: -jobs: - test-published: - # Define a display name: - name: 'Test running examples of published package' - - # Define the type of virtual host machine: - runs-on: ubuntu-latest - - # Define environment variables: - env: - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} - - # Run workflow job if `publish` workflow run is successful or when the workflow is manually triggered or on a schedule: - if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' }} - - # Define the job's steps: - steps: - # Checkout the repository: - - name: 'Checkout repository' - uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 - - # Install Node.js: - - name: 'Install Node.js' - uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1 - with: - node-version: 20 - timeout-minutes: 5 - - # Create test directory and run examples: - - name: 'Create test directory and run examples' - run: | - cd .. - mkdir test-published - cd test-published - - # Copy example file: - cp $GITHUB_WORKSPACE/examples/index.js . - - # Create a minimal package.json - echo '{ - "name": "test-published", - "version": "1.0.0", - "main": "index.js", - "dependencies": {} - }' > package.json - - # Get package name and modify example file: - PACKAGE_NAME=$(jq -r '.name' $GITHUB_WORKSPACE/package.json) - ESCAPED_PACKAGE_NAME=$(echo "$PACKAGE_NAME" | sed 's/[\/&]/\\&/g') - - sed -i "s/require( '.\/..\/lib' )/require( '$ESCAPED_PACKAGE_NAME' )/g" index.js - - # Extract and install dependencies: - DEPS=$(grep -oP "require\(\s*'([^']+)'\s*\)" index.js | sed "s/require(\s*'//" | sed "s/'\s*)//" | grep -v "^\.") - for dep in $DEPS; do - npm install $dep --save - done - - # Run the example: - node index.js - - # Send Slack notification if job fails: - - name: 'Send notification to Slack in case of failure' - uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2 - with: - status: ${{ job.status }} - channel: '#npm-ci' - if: failure() diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 16b03f7..0000000 --- a/.gitignore +++ /dev/null @@ -1,194 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2017 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Files # -######### -package.json.copy -.stdlibrc - -# Directories # -############### -build/ -downloads/ -reports/ -tmp/ - -# Compiled source # -################### -*.com -*.class -*.dll -*.o -*.so -*.slo -*.lo -*.obj -*.dylib -*.lai -*.la -*.a -*.lib -*.ko -*.elf -*.node - -# Precompiled headers # -####################### -*.gch -*.pch - -# Executables # -############### -*.exe -*.out -*.app - -# Packages # -############ -# It is better to unpack these files and commit the raw source -# git has its own built in compression methods -*.7z -*.dmg -*.gz -*.iso -*.jar -*.rar -*.tar -*.zip - -# Logs and databases # -###################### -*.log -*.sql -*.sqlite - -# OS generated files # -###################### -.DS_Store -.DS_Store? -._* -.Spotlight-V100 -.Trashes -Icon? -ehthumbs.db -Thumbs.db -Desktop.ini - -# Temporary files # -################### -*~ - -# Node.js # -########### -/node_modules/ -lib/node_modules/**/node_modules/ -docs/**/node_modules/ -pids -*.pid -*.seed -yarn.lock -package-lock.json - -# Typescript # -############## -*.tsbuildinfo -lib/node_modules/**/tsconfig.json -lib/node_modules/**/tslint.json - -# Matlab # -########## -*.asv -*.mex* - -# Fortran # -########### -*.mod - -# R # -##### -.Rhistory -.Rapp.history -.Rproj.user/ - -# Python # -########## -__pycache__/ -*.py[cod] -*$py.class -*.egg-info/ - -# TeX # -####### -*.aux -*.lof -*.log -*.lot -*.fls -*.out -*.toc -*.dvi -*-converted-to.* -*.bbl -*.bcf -*.blg -*-blx.aux -*-blx.bib -*.brf -*.run.xml -*.fdb_latexmk -*.synctex -*.synctex.gz -*.synctex.gz(busy) -*.pdfsync -*.alg -*.loa -acs-*.bib -*.thm -*.nav -*.snm -*.vrb -*.acn -*.acr -*.glg -*.glo -*.gls -*-concordance.tex -*.tikz -*-tikzDictionary -*.idx -*.ilg -*.ind -*.ist - -# Visual Studio # -################# -.vscode/ -jsconfig.json - -# Sublime Text # -################ -*.sublime-workspace -*.sublime-project - -# Other editor files # -###################### -.idea/ - -# Cursor # -########## -.cursorignore diff --git a/.npmignore b/.npmignore deleted file mode 100644 index 8eea7dc..0000000 --- a/.npmignore +++ /dev/null @@ -1,229 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2017 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Files # -######### -CITATION.cff -CHANGELOG.md -CODE_OF_CONDUCT.md -CONTRIBUTING.md -CONTRIBUTORS -TODO.md -ROADMAP.md -branches.md -.postinstall.json -Makefile - -# Ignore files to avoid compilation of native addon when installing package: -binding.gyp -include.gypi - -# Directories # -############### -.circleci/ -.github/ -**/benchmark/ -**/build/ -**/examples/ -reports/ -support/ -scripts/ -**/tmp/ -workshops/ - -# Ignore test directories, except for testing dependency installation: -**/test/ - -# Compiled source # -################### -*.com -*.class -*.dll -*.o -*.so -*.slo -*.lo -*.obj -*.dylib -*.lai -*.la -*.a -*.lib -*.ko -*.elf -*.node - -# Precompiled headers # -####################### -*.gch -*.pch - -# Executables # -############### -*.exe -*.out -*.app - -# Packages # -############ -*.7z -*.dmg -*.gz -*.iso -*.jar -*.rar -*.tar -*.zip - -# Make an exception for compressed distributable files: -!dist/*.gz - -# Logs and databases # -###################### -*.log -*.sql -*.sqlite - -# OS generated files # -###################### -.DS_Store -.DS_Store? -._* -.Spotlight-V100 -.Trashes -Icon? -ehthumbs.db -Thumbs.db -Desktop.ini - -# Temporary files # -################### -*~ - -# Node.js # -########### -.npmignore - -# Only top-level node_modules: -/node_modules/ - -# TypeScript # -############## -tsconfig.json -tslint.json -*.tsbuildinfo - -# Matlab # -########## -*.asv -*.mex* - -# Fortran # -########### -*.mod - -# R # -##### -.Rhistory -.Rapp.history -.Rproj.user/ - -# Python # -########## -__pycache__/ -*.py[cod] -*$py.class -*.egg-info/ -.ipynb_checkpoints -setup.cfg -setup.py - -# TeX # -####### -*.aux -*.lof -*.log -*.lot -*.fls -*.out -*.toc -*.dvi -*-converted-to.* -*.bbl -*.bcf -*.blg -*-blx.aux -*-blx.bib -*.brf -*.run.xml -*.fdb_latexmk -*.synctex -*.synctex.gz -*.synctex.gz(busy) -*.pdfsync -*.alg -*.loa -acs-*.bib -*.thm -*.nav -*.snm -*.vrb -*.acn -*.acr -*.glg -*.glo -*.gls -*-concordance.tex -*.tikz -*-tikzDictionary -*.idx -*.ilg -*.ind -*.ist - -# Git # -####### -.git* -.mailmap - -# Visual Studio # -################# -.vscode/ -jsconfig.json - -# Utilities # -############# -.jshintrc -.jshintignore -.eslintrc* -.eslintignore - -.pylintrc -.pycodestyle -.pydocstyle - -.travis.yml -circle.yml -appveyor.yml -azure-pipelines.yml - -.editorconfig -.codeclimate.yml -.codecov.yml - -.rtlintrc diff --git a/.npmrc b/.npmrc deleted file mode 100644 index 58dbd10..0000000 --- a/.npmrc +++ /dev/null @@ -1,31 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2017 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# Configuration for [npm][1]. -# -# [1]: https://docs.npmjs.com/files/npmrc - -# Disable the creation of a lock file: -package-lock = false -shrinkwrap = false - -# Disable automatically "saving" dependencies on install: -save = false - -# Do not generate provenance metadata: -provenance = false diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index 41a7ade..0000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,147 +0,0 @@ -# CHANGELOG - -> Package changelog. - -<section class="release" id="unreleased"> - -## Unreleased (2025-03-10) - -<section class="bug-fixes"> - -### Bug Fixes - -- [`844c9bb`](https://github.com/stdlib-js/stdlib/commit/844c9bb4e0ecb67410bb11c774341ea9d68167f7) - resolve TypeScript errors - -</section> - -<!-- /.bug-fixes --> - -<section class="commits"> - -### Commits - -<details> - -- [`844c9bb`](https://github.com/stdlib-js/stdlib/commit/844c9bb4e0ecb67410bb11c774341ea9d68167f7) - **fix:** resolve TypeScript errors _(by Athan Reines)_ - -</details> - -</section> - -<!-- /.commits --> - -<section class="contributors"> - -### Contributors - -A total of 1 person contributed to this release. Thank you to this contributor: - -- Athan Reines - -</section> - -<!-- /.contributors --> - -</section> - -<!-- /.release --> - -<section class="release" id="v0.2.2"> - -## 0.2.2 (2024-07-29) - -No changes reported for this release. - -</section> - -<!-- /.release --> - -<section class="release" id="v0.2.1"> - -## 0.2.1 (2024-02-25) - -No changes reported for this release. - -</section> - -<!-- /.release --> - -<section class="release" id="v0.2.0"> - -## 0.2.0 (2024-02-15) - -<section class="commits"> - -### Commits - -<details> - -- [`3e206ac`](https://github.com/stdlib-js/stdlib/commit/3e206acd54dbb2301ebac48a0a3cc6109b7abc9a) - **docs:** update examples to use a different utility _(by Athan Reines)_ - -</details> - -</section> - -<!-- /.commits --> - -<section class="contributors"> - -### Contributors - -A total of 1 person contributed to this release. Thank you to this contributor: - -- Athan Reines - -</section> - -<!-- /.contributors --> - -</section> - -<!-- /.release --> - -<section class="release" id="v0.1.0"> - -## 0.1.0 (2024-01-03) - -<section class="features"> - -### Features - -- [`951c430`](https://github.com/stdlib-js/stdlib/commit/951c430b1826b761731e2a507d560bf3d49e7eea) - add `array/base/group-entries` - -</section> - -<!-- /.features --> - -<section class="commits"> - -### Commits - -<details> - -- [`6b900de`](https://github.com/stdlib-js/stdlib/commit/6b900ded48ccd3fcc3f6e3aa211eb4ca02656777) - **style:** remove empty line _(by Athan Reines)_ -- [`951c430`](https://github.com/stdlib-js/stdlib/commit/951c430b1826b761731e2a507d560bf3d49e7eea) - **feat:** add `array/base/group-entries` _(by Athan Reines)_ - -</details> - -</section> - -<!-- /.commits --> - -<section class="contributors"> - -### Contributors - -A total of 1 person contributed to this release. Thank you to this contributor: - -- Athan Reines - -</section> - -<!-- /.contributors --> - -</section> - -<!-- /.release --> - diff --git a/CITATION.cff b/CITATION.cff deleted file mode 100644 index 2ec6fff..0000000 --- a/CITATION.cff +++ /dev/null @@ -1,30 +0,0 @@ -cff-version: 1.2.0 -title: stdlib -message: >- - If you use this software, please cite it using the - metadata from this file. - -type: software - -authors: - - name: The Stdlib Authors - url: https://github.com/stdlib-js/stdlib/graphs/contributors - -repository-code: https://github.com/stdlib-js/stdlib -url: https://stdlib.io - -abstract: | - Standard library for JavaScript and Node.js. - -keywords: - - JavaScript - - Node.js - - TypeScript - - standard library - - scientific computing - - numerical computing - - statistical computing - -license: Apache-2.0 AND BSL-1.0 - -date-released: 2016 diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md deleted file mode 100644 index 35b70c9..0000000 --- a/CODE_OF_CONDUCT.md +++ /dev/null @@ -1,3 +0,0 @@ -# Code of Conduct - -stdlib expects community participants to adhere to the project Code of Conduct. The [full text](https://github.com/stdlib-js/stdlib/blob/develop/CODE_OF_CONDUCT.md) is available in the main project repository. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 5f59443..0000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,3 +0,0 @@ -# Contribution Guidelines - -Woot woot! If you are new to stdlib, welcome! And thanks for your interest! Guidelines for how to contribute to the project are [available](https://github.com/stdlib-js/stdlib/blob/develop/CONTRIBUTING.md) in the main project repository. diff --git a/Makefile b/Makefile deleted file mode 100644 index 8c0d48f..0000000 --- a/Makefile +++ /dev/null @@ -1,534 +0,0 @@ -#/ -# @license Apache-2.0 -# -# Copyright (c) 2021 The Stdlib Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -#/ - -# USER VARIABLES # - -ifndef VERBOSE - QUIET := @ -else - QUIET := -endif - -# Indicate whether to "fast" fail when linting, running tests, etc: -ifndef FAST_FAIL - FAIL_FAST := true -else -ifeq ($(FAST_FAIL), 0) - FAIL_FAST := false -else - FAIL_FAST := true -endif -endif - -# Define the `NODE_PATH` environment variable: -NODE_PATH ?= - -# Define the `NODE_ENV` environment variable: -NODE_ENV ?= - - -# INTERNAL VARIABLES # - -# Instruct make to warn us when we use an undefined variable (e.g., misspellings). -MAKEFLAGS += --warn-undefined-variables - -# Define the default target: -.DEFAULT_GOAL := all - -# Define the `SHELL` variable to avoid issues on systems where the variable may be inherited from the environment. -# -# ## Notes -# -# - We use `bash` so that we can use `pipefail`. -# -# -# [1]: https://www.gnu.org/prep/standards/html_node/Makefile-Basics.html#Makefile-Basics -# [2]: http://clarkgrubb.com/makefile-style-guide -SHELL := bash - -# Define shell flags. -# -# ## Notes -# -# - `.SHELLFLAGS` was introduced in GNU Make 3.82 and has no effect on the version of GNU Make installed on Mac OS X, which is 3.81. -# - The `-e` flag causes `bash` to exit immediately if a `bash` executed command fails. -# - The `-u` flag causes `bash` to exit with an error message if a variable is accessed without being defined. -# - The `pipefail` option specifies that, if any of the commands in a pipeline fail, the entire pipeline fails. Otherwise the return value of a pipeline is the return value of the last command. -# - The `-c` flag is in the default value of `.SHELLFLAGS`, which must be preserved, as this is how `make` passes the script to be executed to `bash`. -# -.SHELLFLAGS := -eu -o pipefail -c - -# Remove targets if its recipe fails. -# -# ## Notes -# -# - Mentioning this target anywhere in a Makefile prevents a user from re-running make and using an incomplete or invalid target. -# - When debugging, it may be necessary to comment this line out so the incomplete or invalid target can be inspected. -# -# [1]: https://www.gnu.org/software/make/manual/html_node/Special-Targets.html -.DELETE_ON_ERROR: - -# Remove all the default suffixes, preferring to define all rules explicitly. -# -# [1]: https://www.gnu.org/software/make/manual/html_node/Suffix-Rules.html#Suffix-Rules -# [2]: https://www.gnu.org/software/make/manual/html_node/Suffix-Rules.html#Suffix-Rules -.SUFFIXES: - -# Determine the OS ([1][1], [2][2]). -# -# [1]: https://en.wikipedia.org/wiki/Uname#Examples -# [2]: http://stackoverflow.com/a/27776822/2225624 -OS ?= $(shell uname) -ifneq (, $(findstring MINGW,$(OS))) - OS := WINNT -else -ifneq (, $(findstring MSYS,$(OS))) - OS := WINNT -else -ifneq (, $(findstring CYGWIN,$(OS))) - OS := WINNT -else -ifneq (, $(findstring Windows_NT,$(OS))) - OS := WINNT -endif -endif -endif -endif - -# Determine the filename: -this_file := $(lastword $(MAKEFILE_LIST)) - -# Determine the absolute path of the Makefile (see http://blog.jgc.org/2007/01/what-makefile-am-i-in.html): -this_dir := $(dir $(CURDIR)/$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))) - -# Remove the trailing slash: -this_dir := $(patsubst %/,%,$(this_dir)) - -# Determine root directory: -ROOT_DIR = $(this_dir) - -# Define the root build directory: -BUILD_DIR ?= $(ROOT_DIR)/build - -# Define the root directory for storing distributable files: -DIST_DIR ?= $(ROOT_DIR)/dist - -# Define the root directory for storing temporary files: -TMP_DIR ?= $(ROOT_DIR)/tmp - -# Define the directories for writing reports, including code coverage: -REPORTS_DIR ?= $(ROOT_DIR)/reports -COVERAGE_DIR ?= $(REPORTS_DIR)/coverage - -# Define the top-level directory containing node module dependencies: -NODE_MODULES ?= $(ROOT_DIR)/node_modules - -# Define the top-level directory containing node module executables: -BIN_DIR ?= $(NODE_MODULES)/.bin - -# Define the path to the root `package.json`: -ROOT_PACKAGE_JSON ?= $(ROOT_DIR)/package.json - -# Define the folder name convention for source files requiring compilation: -SRC_FOLDER ?= src - -# Define the folder name convention for documentation files: -DOCUMENTATION_FOLDER ?= docs - -# Define the folder name convention for configuration files: -CONFIG_FOLDER ?= etc - -# Define the folder name convention for benchmark files: -BENCHMARKS_FOLDER ?= benchmark - -# Define the folder name convention for benchmark fixtures: -BENCHMARKS_FIXTURES_FOLDER ?= $(BENCHMARKS_FOLDER)/fixtures - -# Define the folder name convention for examples files: -EXAMPLES_FOLDER ?= examples - -# Define the folder name convention for examples fixtures: -EXAMPLES_FIXTURES_FOLDER ?= $(EXAMPLES_FOLDER)/fixtures - -# Define the folder name convention for test files: -TESTS_FOLDER ?= test - -# Define the folder name convention for test fixtures: -TESTS_FIXTURES_FOLDER ?= $(TESTS_FOLDER)/fixtures - -# Define a filepath pattern for benchmark files: -BENCHMARKS_FILTER ?= .*/.* - -# Define a filepath pattern for example files: -EXAMPLES_FILTER ?= .*/.* - -# Define a filepath pattern for test files: -TESTS_FILTER ?= .*/.* - -# Define a filename pattern for benchmark files: -BENCHMARKS_PATTERN ?= benchmark*.js - -# Define a filename pattern for example files: -EXAMPLES_PATTERN ?= *.js - -# Define a filename pattern for test files: -TESTS_PATTERN ?= test*.js - -# Define Node environments: -ifdef NODE_ENV - NODE_ENV_BENCHMARK := $(NODE_ENV) - NODE_ENV_EXAMPLES := $(NODE_ENV) - NODE_ENV_TEST := $(NODE_ENV) -else - NODE_ENV ?= - NODE_ENV_BENCHMARK ?= benchmark - NODE_ENV_EXAMPLES ?= examples - NODE_ENV_TEST ?= test -endif - -# Define whether delete operations should be safe (i.e., deleted items are sent to trash, rather than permanently deleted): -SAFE_DELETE ?= false - -# Define the delete command: -ifeq ($(SAFE_DELETE), true) - # FIXME: -rm -rf - DELETE := -rm - DELETE_FLAGS := -rf -else - DELETE ?= -rm - DELETE_FLAGS ?= -rf -endif - -# Determine the `open` command: -ifeq ($(OS), Darwin) - OPEN ?= open -else - OPEN ?= xdg-open -endif -# TODO: add Windows command - -# Define the command for `node`: -NODE ?= node - -# Define the command for `npm`: -NPM ?= npm - -# Define the path to a JavaScript test runner. -# -# ## Notes -# -# - We reference the `bin` file directly in order to support using `istanbul` for code coverage on Windows (https://github.com/gotwarlost/istanbul#usage-on-windows) -JAVASCRIPT_TEST ?= $(NODE_MODULES)/tape/bin/tape - -# Define any command-line options to use when invoking the test runner: -JAVASCRIPT_TEST_FLAGS ?= - -# Define the path to the executable for parsing TAP output: -TAP_REPORTER ?= $(BIN_DIR)/tap-min - -# Define the path to the Istanbul executable: -ISTANBUL ?= $(BIN_DIR)/istanbul - -# Define which files and directories to exclude from coverage instrumentation: -ISTANBUL_EXCLUDES_FLAGS ?= \ - --no-default-excludes \ - -x 'node_modules/**' \ - -x 'reports/**' \ - -x 'tmp/**' \ - -x 'deps/**' \ - -x 'dist/**' \ - -x "**/$(SRC_FOLDER)/**" \ - -x "**/$(TESTS_FOLDER)/**" \ - -x "**/$(EXAMPLES_FOLDER)/**" \ - -x "**/$(BENCHMARKS_FOLDER)/**" \ - -x "**/$(CONFIG_FOLDER)/**" \ - -x "**/$(DOCUMENTATION_FOLDER)/**" - -# Define the command to generate test coverage: -ISTANBUL_COVER ?= $(ISTANBUL) cover - -# Define the type of report Istanbul should produce: -ISTANBUL_COVER_REPORT_FORMAT ?= lcov - -# Define the command-line options to be used when generating code coverage: -ISTANBUL_COVER_FLAGS ?= \ - $(ISTANBUL_EXCLUDES_FLAGS) \ - --dir $(COVERAGE_DIR) \ - --report $(ISTANBUL_COVER_REPORT_FORMAT) - -# On Mac OSX, in order to use `|` and other regular expression operators, we need to use enhanced regular expression syntax (-E); see https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man7/re_format.7.html#//apple_ref/doc/man/7/re_format. -ifeq ($(OS), Darwin) - find_kernel_prefix := -E -else - find_kernel_prefix := -endif - -# Common exclude flags that most recipes for finding package files should use (Note: order does matter to some degree): -FIND_COMMON_EXCLUDE_FLAGS ?= \ - '!' -path "$(ROOT_DIR)/.*" \ - '!' -path "$(NODE_MODULES)/*" \ - '!' -path "$(BUILD_DIR)/*" \ - '!' -path "$(REPORTS_DIR)/*" \ - -# Define exclusion flags to use when searching for benchmark files: -FIND_BENCHMARKS_EXCLUDE_FLAGS ?= \ - $(FIND_COMMON_EXCLUDE_FLAGS) \ - '!' -path "$(ROOT_DIR)/**/$(BENCHMARKS_FIXTURES_FOLDER)/*" - -# Define flags for finding benchmark files: -FIND_BENCHMARKS_FLAGS ?= \ - -type f \ - -name "$(BENCHMARKS_PATTERN)" \ - \( -path "$(ROOT_DIR)/$(BENCHMARKS_FOLDER)/**" -o -path "$(ROOT_DIR)/**/$(BENCHMARKS_FOLDER)/**" \) \ - -regex "$(BENCHMARKS_FILTER)" \ - $(FIND_BENCHMARKS_EXCLUDE_FLAGS) - -ifneq ($(OS), Darwin) - FIND_BENCHMARKS_FLAGS := -regextype posix-extended $(FIND_BENCHMARKS_FLAGS) -endif - -# Define a command to list benchmark files: -FIND_BENCHMARKS_CMD ?= find $(find_kernel_prefix) $(ROOT_DIR) $(FIND_BENCHMARKS_FLAGS) - -# Define exclusion flags to use when searching for examples files: -FIND_EXAMPLES_EXCLUDE_FLAGS ?= \ - $(FIND_COMMON_EXCLUDE_FLAGS) \ - '!' -path "$(ROOT_DIR)/**/$(EXAMPLES_FIXTURES_FOLDER)/*" - -# Define flags for finding examples files: -FIND_EXAMPLES_FLAGS ?= \ - -type f \ - -name "$(EXAMPLES_PATTERN)" \ - \( -path "$(ROOT_DIR)/$(EXAMPLES_FOLDER)/**" -o -path "$(ROOT_DIR)/**/$(EXAMPLES_FOLDER)/**" \) \ - -regex "$(EXAMPLES_FILTER)" \ - $(FIND_EXAMPLES_EXCLUDE_FLAGS) - -ifneq ($(OS), Darwin) - FIND_EXAMPLES_FLAGS := -regextype posix-extended $(FIND_EXAMPLES_FLAGS) -endif - -# Define a command to list example files: -FIND_EXAMPLES_CMD ?= find $(find_kernel_prefix) $(ROOT_DIR) $(FIND_EXAMPLES_FLAGS) - -# Define exclusion flags to use when searching for test files: -FIND_TESTS_EXCLUDE_FLAGS ?= \ - $(FIND_COMMON_EXCLUDE_FLAGS) \ - '!' -path "$(ROOT_DIR)/**/$(TESTS_FIXTURES_FOLDER)/*" - -# Define flags for finding test files: -FIND_TESTS_FLAGS ?= \ - -type f \ - -name "$(TESTS_PATTERN)" \ - -regex "$(TESTS_FILTER)" \ - $(FIND_TESTS_EXCLUDE_FLAGS) - -ifneq ($(OS), Darwin) - FIND_TESTS_FLAGS := -regextype posix-extended $(FIND_TESTS_FLAGS) -endif - -# Define a command to list test files: -FIND_TESTS_CMD ?= find $(find_kernel_prefix) $(ROOT_DIR) $(FIND_TESTS_FLAGS) - - -# RULES # - -#/ -# Default target. -# -# @example -# make -# -# @example -# make all -#/ -all: help - -.PHONY: all - -#/ -# Prints a `Makefile` help message. -# -# @example -# make help -#/ -help: - $(QUIET) echo 'Read the Makefile to see the list of available commands.' - $(QUIET) echo '' - -.PHONY: help - -#/ -# Prints the runtime value of a `Makefile` variable. -# -# ## Notes -# -# - The rule uses the following format: -# -# ```bash -# $ make inspect.<variable> -# ``` -# -# @example -# make inspect.ROOT_DIR -# -# @example -# make inspect.CC -#/ -inspect.%: - $(QUIET) echo '$*=$($*)' - -#/ -# Runs the project's install sequence. -# -# @example -# make install -#/ -install: - $(NPM) install - -.PHONY: install - -#/ -# Removes node module dependencies. -# -# @example -# make clean-node -#/ -clean-node: - $(QUIET) $(DELETE) $(DELETE_FLAGS) $(NODE_MODULES) - -#/ -# Runs the project's cleanup sequence. -# -# @example -# make clean -#/ -clean: clean-node clean-cov - $(QUIET) $(DELETE) $(DELETE_FLAGS) $(BUILD_DIR) - $(QUIET) $(DELETE) $(DELETE_FLAGS) $(REPORTS_DIR) - -.PHONY: clean - -#/ -# Runs JavaScript benchmarks consecutively. -# -# ## Notes -# -# - The recipe assumes that benchmark files can be run via Node.js. -# - This rule is useful when wanting to glob for JavaScript benchmark files (e.g., run all JavaScript benchmarks for a particular package). -# -# -# @param {string} [BENCHMARKS_FILTER] - file path pattern (e.g., `.*/utils/group-by/.*`) -# -# @example -# make benchmark -# -# @example -# make benchmark BENCHMARKS_FILTER=".*/utils/group-by/.*" -#/ -benchmark: $(NODE_MODULES) - $(QUIET) $(FIND_BENCHMARKS_CMD) | grep '^[\/]\|^[a-zA-Z]:[/\]' | while read -r file; do \ - echo ""; \ - echo "Running benchmark: $$file"; \ - NODE_ENV="$(NODE_ENV_BENCHMARK)" \ - NODE_PATH="$(NODE_PATH)" \ - $(NODE) $$file || exit 1; \ - done - -.PHONY: benchmark - -#/ -# Runs JavaScript examples consecutively. -# -# ## Notes -# -# - This rule is useful when wanting to glob for JavaScript examples files (e.g., run all JavaScript examples for a particular package). -# - This rule **assumes** that examples files can be run using Node.js. -# -# -# @param {string} [EXAMPLES_FILTER] - file path pattern (e.g., `.*/math/base/special/abs/.*`) -# -# @example -# make examples -# -# @example -# make examples EXAMPLES_FILTER=".*/strided/common/.*" -#/ -examples: $(NODE_MODULES) - $(QUIET) $(FIND_EXAMPLES_CMD) | grep '^[\/]\|^[a-zA-Z]:[/\]' | while read -r file; do \ - echo ""; \ - echo "Running example: $$file"; \ - NODE_ENV="$(NODE_ENV_EXAMPLES)" \ - NODE_PATH="$(NODE_PATH)" \ - $(NODE) $$file || exit 1; \ - done - -.PHONY: examples - -#/ -# Runs JavaScript tests consecutively. -# -# ## Notes -# -# - This rule is useful when wanting to glob for JavaScript test files (e.g., run all JavaScript tests for a particular package). -# - This rule **assumes** that test files can be run using Node.js. -# -# -# @param {string} [TEST_FILTER] - file path pattern (e.g., `.*/math/base/special/abs/.*`) -# -# @example -# make test -# -# @example -# make test TESTS_FILTER=".*/strided/common/.*" -#/ -test: $(NODE_MODULES) - $(QUIET) $(FIND_TESTS_CMD) | grep '^[\/]\|^[a-zA-Z]:[/\]' | while read -r test; do \ - echo ''; \ - echo "Running test: $$test"; \ - NODE_ENV="$(NODE_ENV_TEST)" \ - NODE_PATH="$(NODE_PATH)" \ - $(JAVASCRIPT_TEST) \ - $(JAVASCRIPT_TEST_FLAGS) \ - $$test \ - | $(TAP_REPORTER) || exit 1; \ - done - -.PHONY: test - -#/ -# Runs unit tests and generate a test coverage report. -# -# @example -# make test-cov -#/ -test-cov: clean-cov - $(QUIET) NODE_ENV="$(NODE_ENV_TEST)" \ - NODE_PATH="$(NODE_PATH)" \ - $(ISTANBUL_COVER) $(ISTANBUL_COVER_FLAGS) $(JAVASCRIPT_TEST) -- $$( $(FIND_TESTS_CMD) ) - -.PHONY: test-cov - -#/ -# Removes a test coverage directory. -# -# @example -# make clean-cov -#/ -clean-cov: - $(QUIET) $(DELETE) $(DELETE_FLAGS) $(COVERAGE_DIR) diff --git a/README.md b/README.md index 8115503..c62e3d1 100644 --- a/README.md +++ b/README.md @@ -45,32 +45,38 @@ limitations under the License. <!-- Package usage documentation. --> -<section class="installation"> -## Installation -```bash -npm install @stdlib/array-base-group-entries -``` +<section class="usage"> -Alternatively, +## Usage -- To load the package in a website via a `script` tag without installation and bundlers, use the [ES Module][es-module] available on the [`esm`][esm-url] branch (see [README][esm-readme]). -- If you are using Deno, visit the [`deno`][deno-url] branch (see [README][deno-readme] for usage intructions). -- For use in Observable, or in browser/node environments, use the [Universal Module Definition (UMD)][umd] build available on the [`umd`][umd-url] branch (see [README][umd-readme]). +To use in Observable, -The [branches.md][branches-url] file summarizes the available branches and displays a diagram illustrating their relationships. +```javascript +groupEntries = require( 'https://cdn.jsdelivr.net/gh/stdlib-js/array-base-group-entries@umd/browser.js' ) +``` -To view installation and usage instructions specific to each branch build, be sure to explicitly navigate to the respective README files on each branch, as linked to above. +To vendor stdlib functionality and avoid installing dependency trees for Node.js, you can use the UMD server build: -</section> +```javascript +var groupEntries = require( 'path/to/vendor/umd/array-base-group-entries/index.js' ) +``` -<section class="usage"> +To include the bundle in a webpage, -## Usage +```html +<script type="text/javascript" src="https://cdn.jsdelivr.net/gh/stdlib-js/array-base-group-entries@umd/browser.js"></script> +``` -```javascript -var groupEntries = require( '@stdlib/array-base-group-entries' ); +If no recognized module system is present, access bundle contents via the global scope: + +```html +<script type="text/javascript"> +(function () { + window.groupEntries; +})(); +</script> ``` #### groupEntries( x, groups ) @@ -119,10 +125,15 @@ var out = groupEntries( x, groups ); <!-- eslint no-undef: "error" --> -```javascript -var discreteUniform = require( '@stdlib/random-array-discrete-uniform' ); -var take = require( '@stdlib/array-base-take-indexed' ); -var groupEntries = require( '@stdlib/array-base-group-entries' ); +```html +<!DOCTYPE html> +<html lang="en"> +<body> +<script type="text/javascript" src="https://cdn.jsdelivr.net/gh/stdlib-js/random-array-discrete-uniform@umd/browser.js"></script> +<script type="text/javascript" src="https://cdn.jsdelivr.net/gh/stdlib-js/array-base-take-indexed@umd/browser.js"></script> +<script type="text/javascript" src="https://cdn.jsdelivr.net/gh/stdlib-js/array-base-group-entries@umd/browser.js"></script> +<script type="text/javascript"> +(function () { // Define an initial array of values: var values = [ 'beep', 'boop', 'foo', 'bar', 'woot', 'woot' ]; @@ -144,6 +155,11 @@ var out = groupEntries( x, groups ); // returns {...} console.log( out ); + +})(); +</script> +</body> +</html> ``` </section> diff --git a/SECURITY.md b/SECURITY.md deleted file mode 100644 index 9702d4c..0000000 --- a/SECURITY.md +++ /dev/null @@ -1,5 +0,0 @@ -# Security - -> Policy for reporting security vulnerabilities. - -See the security policy [in the main project repository](https://github.com/stdlib-js/stdlib/security). diff --git a/benchmark/benchmark.length.js b/benchmark/benchmark.length.js deleted file mode 100644 index 0ef368f..0000000 --- a/benchmark/benchmark.length.js +++ /dev/null @@ -1,101 +0,0 @@ -/** -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -'use strict'; - -// MODULES // - -var bench = require( '@stdlib/bench-harness' ); -var pow = require( '@stdlib/math-base-special-pow' ); -var isPlainObject = require( '@stdlib/assert-is-plain-object' ); -var zeroTo = require( '@stdlib/array-base-zero-to' ); -var pkg = require( './../package.json' ).name; -var groupEntries = require( './../lib' ); - - -// FUNCTIONS // - -/** -* Creates a benchmark function. -* -* @private -* @param {PositiveInteger} len - array length -* @returns {Function} benchmark function -*/ -function createBenchmark( len ) { - var groups; - var x; - - x = zeroTo( len ); - groups = zeroTo( len ); // note: this corresponds to the extreme case where every element is in a distinct group - - return benchmark; - - /** - * Benchmark function. - * - * @private - * @param {Benchmark} b - benchmark instance - */ - function benchmark( b ) { - var out; - var i; - - b.tic(); - for ( i = 0; i < b.iterations; i++ ) { - out = groupEntries( x, groups ); - if ( typeof out !== 'object' ) { - b.fail( 'should return an object' ); - } - } - b.toc(); - if ( !isPlainObject( out ) ) { - b.fail( 'should return an object' ); - } - b.pass( 'benchmark finished' ); - b.end(); - } -} - - -// MAIN // - -/** -* Main execution sequence. -* -* @private -*/ -function main() { - var len; - var min; - var max; - var f; - var i; - - min = 1; // 10^min - max = 6; // 10^max - - for ( i = min; i <= max; i++ ) { - len = pow( 10, i ); - - f = createBenchmark( len ); - bench( pkg+':len='+len+',num_groups='+len, f ); - } -} - -main(); diff --git a/branches.md b/branches.md deleted file mode 100644 index 0b1d2f4..0000000 --- a/branches.md +++ /dev/null @@ -1,56 +0,0 @@ -<!-- - -@license Apache-2.0 - -Copyright (c) 2022 The Stdlib Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. - ---> - -# Branches - -This repository has the following branches: - -- **main**: default branch generated from the [stdlib project][stdlib-url], where all development takes place. -- **production**: [production build][production-url] of the package (e.g., reformatted error messages to reduce bundle sizes and thus the number of bytes transmitted over a network). -- **esm**: [ES Module][esm-url] branch for use via a `script` tag without the need for installation and bundlers (see [README][esm-readme]). -- **deno**: [Deno][deno-url] branch for use in Deno (see [README][deno-readme]). -- **umd**: [UMD][umd-url] branch for use in Observable, or in dual browser/Node.js environments (see [README][umd-readme]). - -The following diagram illustrates the relationships among the above branches: - -```mermaid -graph TD; -A[stdlib]-->|generate standalone package|B; -B[main] -->|productionize| C[production]; -C -->|bundle| D[esm]; -C -->|bundle| E[deno]; -C -->|bundle| F[umd]; - -%% click A href "https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/array/base/group-entries" -%% click B href "https://github.com/stdlib-js/array-base-group-entries/tree/main" -%% click C href "https://github.com/stdlib-js/array-base-group-entries/tree/production" -%% click D href "https://github.com/stdlib-js/array-base-group-entries/tree/esm" -%% click E href "https://github.com/stdlib-js/array-base-group-entries/tree/deno" -%% click F href "https://github.com/stdlib-js/array-base-group-entries/tree/umd" -``` - -[stdlib-url]: https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/array/base/group-entries -[production-url]: https://github.com/stdlib-js/array-base-group-entries/tree/production -[deno-url]: https://github.com/stdlib-js/array-base-group-entries/tree/deno -[deno-readme]: https://github.com/stdlib-js/array-base-group-entries/blob/deno/README.md -[umd-url]: https://github.com/stdlib-js/array-base-group-entries/tree/umd -[umd-readme]: https://github.com/stdlib-js/array-base-group-entries/blob/umd/README.md -[esm-url]: https://github.com/stdlib-js/array-base-group-entries/tree/esm -[esm-readme]: https://github.com/stdlib-js/array-base-group-entries/blob/esm/README.md \ No newline at end of file diff --git a/browser.js b/browser.js new file mode 100644 index 0000000..5bcedde --- /dev/null +++ b/browser.js @@ -0,0 +1,3 @@ +// Copyright (c) 2025 The Stdlib Authors. License is Apache-2.0: http://www.apache.org/licenses/LICENSE-2.0 +var r,e;r=this,e=function(){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol("foo");function e(){return r&&"symbol"==typeof Symbol.toStringTag}var t=Object.prototype.toString,n=Object.prototype.hasOwnProperty;function i(r,e){return null!=r&&n.call(r,e)}var o="function"==typeof Symbol?Symbol:void 0,a="function"==typeof o?o.toStringTag:"",u=e()?function(r){var e,n,o;if(null==r)return t.call(r);n=r[a],e=i(r,a);try{r[a]=void 0}catch(e){return t.call(r)}return o=t.call(r),e?r[a]=n:delete r[a],o}:function(r){return t.call(r)},f=Array.isArray?Array.isArray:function(r){return"[object Array]"===u(r)},l="function",s={complex128:function(r,e){return r.get(e)},complex64:function(r,e){return r.get(e)},default:function(r,e){return r.get(e)}};function h(r){var e=s[r];return"function"==typeof e?e:s.default}var c={float64:function(r,e){return r[e]},float32:function(r,e){return r[e]},int32:function(r,e){return r[e]},int16:function(r,e){return r[e]},int8:function(r,e){return r[e]},uint32:function(r,e){return r[e]},uint16:function(r,e){return r[e]},uint8:function(r,e){return r[e]},uint8c:function(r,e){return r[e]},generic:function(r,e){return r[e]},default:function(r,e){return r[e]}};function p(r){var e=c[r];return"function"==typeof e?e:c.default}var m="function"==typeof Object.defineProperty?Object.defineProperty:null,y=Object.defineProperty;function g(r){return"number"==typeof r}function w(r){var e,t="";for(e=0;e<r;e++)t+="0";return t}function b(r,e,t){var n=!1,i=e-r.length;return i<0||(function(r){return"-"===r[0]}(r)&&(n=!0,r=r.substr(1)),r=t?r+w(i):w(i)+r,n&&(r="-"+r)),r}var v=String.prototype.toLowerCase,d=String.prototype.toUpperCase;function E(r){var e,t,n;switch(r.specifier){case"b":e=2;break;case"o":e=8;break;case"x":case"X":e=16;break;default:e=10}if(t=r.arg,n=parseInt(t,10),!isFinite(n)){if(!g(t))throw new Error("invalid integer. Value: "+t);n=0}return n<0&&("u"===r.specifier||10!==e)&&(n=4294967295+n+1),n<0?(t=(-n).toString(e),r.precision&&(t=b(t,r.precision,r.padRight)),t="-"+t):(t=n.toString(e),n||r.precision?r.precision&&(t=b(t,r.precision,r.padRight)):t="",r.sign&&(t=r.sign+t)),16===e&&(r.alternate&&(t="0x"+t),t=r.specifier===d.call(r.specifier)?d.call(t):v.call(t)),8===e&&r.alternate&&"0"!==t.charAt(0)&&(t="0"+t),t}var _=Math.abs,T=String.prototype.toLowerCase,x=String.prototype.toUpperCase,A=String.prototype.replace,V=/e\+(\d)$/,S=/e-(\d)$/,j=/^(\d+)$/,F=/^(\d+)e/,k=/\.0$/,I=/\.0*e/,L=/(\..*[^0])0*e/;function R(r){var e,t,n=parseFloat(r.arg);if(!isFinite(n)){if(!g(r.arg))throw new Error("invalid floating-point number. Value: "+t);n=r.arg}switch(r.specifier){case"e":case"E":t=n.toExponential(r.precision);break;case"f":case"F":t=n.toFixed(r.precision);break;case"g":case"G":_(n)<1e-4?((e=r.precision)>0&&(e-=1),t=n.toExponential(e)):t=n.toPrecision(r.precision),r.alternate||(t=A.call(t,L,"$1e"),t=A.call(t,I,"e"),t=A.call(t,k,""));break;default:throw new Error("invalid double notation. Value: "+r.specifier)}return t=A.call(t,V,"e+0$1"),t=A.call(t,S,"e-0$1"),r.alternate&&(t=A.call(t,j,"$1."),t=A.call(t,F,"$1.e")),n>=0&&r.sign&&(t=r.sign+t),t=r.specifier===x.call(r.specifier)?x.call(t):T.call(t)}function B(r){var e,t="";for(e=0;e<r;e++)t+=" ";return t}var O=String.fromCharCode,C=Array.isArray;function M(r){return r!=r}function U(r){var e={};return e.specifier=r.specifier,e.precision=void 0===r.precision?1:r.precision,e.width=r.width,e.flags=r.flags||"",e.mapping=r.mapping,e}function N(r){var e,t,n,i,o,a,u,f,l,s,h,c,p;if(!C(r))throw new TypeError("invalid argument. First argument must be an array. Value: `"+r+"`.");for(a="",u=1,f=0;f<r.length;f++)if("string"==typeof(n=r[f]))a+=n;else{if(e=void 0!==n.precision,!(n=U(n)).specifier)throw new TypeError("invalid argument. Token is missing `specifier` property. Index: `"+f+"`. Value: `"+n+"`.");for(n.mapping&&(u=n.mapping),t=n.flags,l=0;l<t.length;l++)switch(i=t.charAt(l)){case" ":n.sign=" ";break;case"+":n.sign="+";break;case"-":n.padRight=!0,n.padZeros=!1;break;case"0":n.padZeros=t.indexOf("-")<0;break;case"#":n.alternate=!0;break;default:throw new Error("invalid flag: "+i)}if("*"===n.width){if(n.width=parseInt(arguments[u],10),u+=1,M(n.width))throw new TypeError("the argument for * width at position "+u+" is not a number. Value: `"+n.width+"`.");n.width<0&&(n.padRight=!0,n.width=-n.width)}if(e&&"*"===n.precision){if(n.precision=parseInt(arguments[u],10),u+=1,M(n.precision))throw new TypeError("the argument for * precision at position "+u+" is not a number. Value: `"+n.precision+"`.");n.precision<0&&(n.precision=1,e=!1)}switch(n.arg=arguments[u],n.specifier){case"b":case"o":case"x":case"X":case"d":case"i":case"u":e&&(n.padZeros=!1),n.arg=E(n);break;case"s":n.maxWidth=e?n.precision:-1,n.arg=String(n.arg);break;case"c":if(!M(n.arg)){if((o=parseInt(n.arg,10))<0||o>127)throw new Error("invalid character code. Value: "+n.arg);n.arg=M(o)?String(n.arg):O(o)}break;case"e":case"E":case"f":case"F":case"g":case"G":e||(n.precision=6),n.arg=R(n);break;default:throw new Error("invalid specifier: "+n.specifier)}n.maxWidth>=0&&n.arg.length>n.maxWidth&&(n.arg=n.arg.substring(0,n.maxWidth)),n.padZeros?n.arg=b(n.arg,n.width||n.precision,n.padRight):n.width&&(n.arg=(s=n.arg,h=n.width,c=n.padRight,p=void 0,(p=h-s.length)<0?s:s=c?s+B(p):B(p)+s)),a+=n.arg||"",u+=1}return a}var P=/%(?:([1-9]\d*)\$)?([0 +\-#]*)(\*|\d+)?(?:(\.)(\*|\d+)?)?[hlL]?([%A-Za-z])/g;function Y(r){var e={mapping:r[1]?parseInt(r[1],10):void 0,flags:r[2],width:r[3],precision:r[5],specifier:r[6]};return"."===r[4]&&void 0===r[5]&&(e.precision="1"),e}function W(r){var e,t,n,i;for(t=[],i=0,n=P.exec(r);n;)(e=r.slice(i,P.lastIndex-n[0].length)).length&&t.push(e),t.push(Y(n)),i=P.lastIndex,n=P.exec(r);return(e=r.slice(i)).length&&t.push(e),t}function $(r){var e,t;if("string"!=typeof r)throw new TypeError($("invalid argument. First argument must be a string. Value: `%s`.",r));for(e=[W(r)],t=1;t<arguments.length;t++)e.push(arguments[t]);return N.apply(null,e)}var G,Z=Object.prototype,J=Z.toString,X=Z.__defineGetter__,z=Z.__defineSetter__,H=Z.__lookupGetter__,q=Z.__lookupSetter__;G=function(){try{return m({},"x",{}),!0}catch(r){return!1}}()?y:function(r,e,t){var n,i,o,a;if("object"!=typeof r||null===r||"[object Array]"===J.call(r))throw new TypeError($("invalid argument. First argument must be an object. Value: `%s`.",r));if("object"!=typeof t||null===t||"[object Array]"===J.call(t))throw new TypeError($("invalid argument. Property descriptor must be an object. Value: `%s`.",t));if((i="value"in t)&&(H.call(r,e)||q.call(r,e)?(n=r.__proto__,r.__proto__=Z,delete r[e],r[e]=t.value,r.__proto__=n):r[e]=t.value),o="get"in t,a="set"in t,i&&(o||a))throw new Error("invalid argument. Cannot specify one or more accessors and a value or writable attribute in the property descriptor.");return o&&X&&X.call(r,e,t.get),a&&z&&z.call(r,e,t.set),r};var D=G;function K(r,e,t){D(r,e,{configurable:!1,enumerable:!1,writable:!1,value:t})}function Q(r){return null!==r&&"object"==typeof r}function rr(r){return Q(r)&&(r._isBuffer||r.constructor&&"function"==typeof r.constructor.isBuffer&&r.constructor.isBuffer(r))}function er(){return/^\s*function\s*([^(]*)/i}K(Q,"isObjectLikeArray",function(r){if("function"!=typeof r)throw new TypeError($("invalid argument. Must provide a function. Value: `%s`.",r));return function(e){var t,n;if(!f(e))return!1;if(0===(t=e.length))return!1;for(n=0;n<t;n++)if(!1===r(e[n]))return!1;return!0}}(Q));var tr=/^\s*function\s*([^(]*)/i;function nr(r){var e,t,n;if(("Object"===(t=u(r).slice(8,-1))||"Error"===t)&&r.constructor){if("string"==typeof(n=r.constructor).name)return n.name;if(e=tr.exec(n.toString()))return e[1]}return rr(r)?"Buffer":t}K(er,"REGEXP",tr);var ir={Float32Array:"float32",Float64Array:"float64",Array:"generic",Int16Array:"int16",Int32Array:"int32",Int8Array:"int8",Uint16Array:"uint16",Uint32Array:"uint32",Uint8Array:"uint8",Uint8ClampedArray:"uint8c",Complex64Array:"complex64",Complex128Array:"complex128"},or="function"==typeof Float64Array,ar="function"==typeof Float64Array?Float64Array:null,ur="function"==typeof Float64Array?Float64Array:void 0,fr=function(){var r,e,t;if("function"!=typeof ar)return!1;try{e=new ar([1,3.14,-3.14,NaN]),t=e,r=(or&&t instanceof Float64Array||"[object Float64Array]"===u(t))&&1===e[0]&&3.14===e[1]&&-3.14===e[2]&&e[3]!=e[3]}catch(e){r=!1}return r}()?ur:function(){throw new Error("not implemented")},lr="function"==typeof Float32Array,sr=Number.POSITIVE_INFINITY,hr="function"==typeof Float32Array?Float32Array:null,cr="function"==typeof Float32Array?Float32Array:void 0,pr=function(){var r,e,t;if("function"!=typeof hr)return!1;try{e=new hr([1,3.14,-3.14,5e40]),t=e,r=(lr&&t instanceof Float32Array||"[object Float32Array]"===u(t))&&1===e[0]&&3.140000104904175===e[1]&&-3.140000104904175===e[2]&&e[3]===sr}catch(e){r=!1}return r}()?cr:function(){throw new Error("not implemented")},mr="function"==typeof Uint32Array,yr="function"==typeof Uint32Array?Uint32Array:null,gr="function"==typeof Uint32Array?Uint32Array:void 0,wr=function(){var r,e,t;if("function"!=typeof yr)return!1;try{e=new yr(e=[1,3.14,-3.14,4294967296,4294967297]),t=e,r=(mr&&t instanceof Uint32Array||"[object Uint32Array]"===u(t))&&1===e[0]&&3===e[1]&&4294967293===e[2]&&0===e[3]&&1===e[4]}catch(e){r=!1}return r}()?gr:function(){throw new Error("not implemented")},br="function"==typeof Int32Array,vr="function"==typeof Int32Array?Int32Array:null,dr="function"==typeof Int32Array?Int32Array:void 0,Er=function(){var r,e,t;if("function"!=typeof vr)return!1;try{e=new vr([1,3.14,-3.14,2147483648]),t=e,r=(br&&t instanceof Int32Array||"[object Int32Array]"===u(t))&&1===e[0]&&3===e[1]&&-3===e[2]&&-2147483648===e[3]}catch(e){r=!1}return r}()?dr:function(){throw new Error("not implemented")},_r="function"==typeof Uint16Array,Tr="function"==typeof Uint16Array?Uint16Array:null,xr="function"==typeof Uint16Array?Uint16Array:void 0,Ar=function(){var r,e,t;if("function"!=typeof Tr)return!1;try{e=new Tr(e=[1,3.14,-3.14,65536,65537]),t=e,r=(_r&&t instanceof Uint16Array||"[object Uint16Array]"===u(t))&&1===e[0]&&3===e[1]&&65533===e[2]&&0===e[3]&&1===e[4]}catch(e){r=!1}return r}()?xr:function(){throw new Error("not implemented")},Vr="function"==typeof Int16Array,Sr="function"==typeof Int16Array?Int16Array:null,jr="function"==typeof Int16Array?Int16Array:void 0,Fr=function(){var r,e,t;if("function"!=typeof Sr)return!1;try{e=new Sr([1,3.14,-3.14,32768]),t=e,r=(Vr&&t instanceof Int16Array||"[object Int16Array]"===u(t))&&1===e[0]&&3===e[1]&&-3===e[2]&&-32768===e[3]}catch(e){r=!1}return r}()?jr:function(){throw new Error("not implemented")},kr="function"==typeof Uint8Array,Ir="function"==typeof Uint8Array?Uint8Array:null,Lr="function"==typeof Uint8Array?Uint8Array:void 0,Rr=function(){var r,e,t;if("function"!=typeof Ir)return!1;try{e=new Ir(e=[1,3.14,-3.14,256,257]),t=e,r=(kr&&t instanceof Uint8Array||"[object Uint8Array]"===u(t))&&1===e[0]&&3===e[1]&&253===e[2]&&0===e[3]&&1===e[4]}catch(e){r=!1}return r}()?Lr:function(){throw new Error("not implemented")},Br="function"==typeof Uint8ClampedArray,Or="function"==typeof Uint8ClampedArray?Uint8ClampedArray:null,Cr="function"==typeof Uint8ClampedArray?Uint8ClampedArray:void 0,Mr=function(){var r,e,t;if("function"!=typeof Or)return!1;try{e=new Or([-1,0,1,3.14,4.99,255,256]),t=e,r=(Br&&t instanceof Uint8ClampedArray||"[object Uint8ClampedArray]"===u(t))&&0===e[0]&&0===e[1]&&1===e[2]&&3===e[3]&&5===e[4]&&255===e[5]&&255===e[6]}catch(e){r=!1}return r}()?Cr:function(){throw new Error("not implemented")},Ur="function"==typeof Int8Array,Nr="function"==typeof Int8Array?Int8Array:null,Pr="function"==typeof Int8Array?Int8Array:void 0,Yr=function(){var r,e,t;if("function"!=typeof Nr)return!1;try{e=new Nr([1,3.14,-3.14,128]),t=e,r=(Ur&&t instanceof Int8Array||"[object Int8Array]"===u(t))&&1===e[0]&&3===e[1]&&-3===e[2]&&-128===e[3]}catch(e){r=!1}return r}()?Pr:function(){throw new Error("not implemented")};function Wr(r){return"number"==typeof r}var $r=Number,Gr=$r.prototype.toString,Zr=e();function Jr(r){return"object"==typeof r&&(r instanceof $r||(Zr?function(r){try{return Gr.call(r),!0}catch(r){return!1}}(r):"[object Number]"===u(r)))}function Xr(r){return Wr(r)||Jr(r)}K(Xr,"isPrimitive",Wr),K(Xr,"isObject",Jr);var zr=$r.NEGATIVE_INFINITY,Hr=Math.floor;function qr(r){return Hr(r)===r}function Dr(r){return r<sr&&r>zr&&qr(r)}function Kr(r){return Wr(r)&&Dr(r)}function Qr(r){return Jr(r)&&Dr(r.valueOf())}function re(r){return Kr(r)||Qr(r)}function ee(r){return Kr(r)&&r>=0}function te(r){return Qr(r)&&r.valueOf()>=0}function ne(r){return ee(r)||te(r)}K(re,"isPrimitive",Kr),K(re,"isObject",Qr),K(ne,"isPrimitive",ee),K(ne,"isObject",te);var ie=4294967295;function oe(r){return"object"==typeof r&&null!==r&&"number"==typeof r.length&&qr(r.length)&&r.length>=0&&r.length<=ie}var ae=9007199254740991;function ue(r){return"object"==typeof r&&null!==r&&"number"==typeof r.length&&qr(r.length)&&r.length>=0&&r.length<=ae}var fe="function"==typeof ArrayBuffer;function le(r){return fe&&r instanceof ArrayBuffer||"[object ArrayBuffer]"===u(r)}function se(r){return"object"==typeof r&&null!==r&&!f(r)}function he(r){return"string"==typeof r}var ce=String.prototype.valueOf,pe=e();function me(r){return"object"==typeof r&&(r instanceof String||(pe?function(r){try{return ce.call(r),!0}catch(r){return!1}}(r):"[object String]"===u(r)))}function ye(r){return he(r)||me(r)}K(ye,"isPrimitive",he),K(ye,"isObject",me);var ge=/./;function we(r){return"boolean"==typeof r}var be=Boolean,ve=Boolean.prototype.toString,de=e();function Ee(r){return"object"==typeof r&&(r instanceof be||(de?function(r){try{return ve.call(r),!0}catch(r){return!1}}(r):"[object Boolean]"===u(r)))}function _e(r){return we(r)||Ee(r)}K(_e,"isPrimitive",we),K(_e,"isObject",Ee);var Te="object"==typeof self?self:null,xe="object"==typeof window?window:null,Ae="object"==typeof globalThis?globalThis:null,Ve=function(r){if(arguments.length){if(!we(r))throw new TypeError($("invalid argument. Must provide a boolean. Value: `%s`.",r));if(r)return new Function("return this;")()}if(Ae)return Ae;if(Te)return Te;if(xe)return xe;throw new Error("unexpected error. Unable to resolve global object.")}(),Se=Ve.document&&Ve.document.childNodes,je=Int8Array,Fe="function"==typeof ge||"object"==typeof je||"function"==typeof Se?function(r){return nr(r).toLowerCase()}:function(r){var e;return null===r?"null":"object"==(e=typeof r)?nr(r).toLowerCase():e};function ke(r){return"function"===Fe(r)}function Ie(r,e){if(!(this instanceof Ie))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:r}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:e}),this}K(Ie,"BYTES_PER_ELEMENT",8),K(Ie.prototype,"BYTES_PER_ELEMENT",8),K(Ie.prototype,"byteLength",16),K(Ie.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(Ie.prototype,"toJSON",(function(){var r={type:"Complex128"};return r.re=this.re,r.im=this.im,r}));var Le="function"==typeof Math.fround?Math.fround:null,Re=new pr(1),Be="function"==typeof Le?Le:function(r){return Re[0]=r,Re[0]};function Oe(r,e){if(!(this instanceof Oe))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:Be(r)}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:Be(e)}),this}function Ce(r){return r instanceof Ie||r instanceof Oe||"object"==typeof r&&null!==r&&"number"==typeof r.re&&"number"==typeof r.im}function Me(r){return qr(r/2)}K(Oe,"BYTES_PER_ELEMENT",4),K(Oe.prototype,"BYTES_PER_ELEMENT",4),K(Oe.prototype,"byteLength",8),K(Oe.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(Oe.prototype,"toJSON",(function(){var r={type:"Complex64"};return r.re=this.re,r.im=this.im,r}));var Ue=8;function Ne(r){return"object"==typeof r&&null!==r&&"Complex64Array"===r.constructor.name&&r.BYTES_PER_ELEMENT===Ue}var Pe=16;function Ye(r){return"object"==typeof r&&null!==r&&"Complex128Array"===r.constructor.name&&r.BYTES_PER_ELEMENT===Pe}function We(){return"function"==typeof o&&"symbol"==typeof o("foo")&&i(o,"iterator")&&"symbol"==typeof o.iterator}var $e=We()?Symbol.iterator:null;function Ge(r,e,t){D(r,e,{configurable:!1,enumerable:!1,get:t})}function Ze(r,e){if(!(this instanceof Ze))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:Be(r)}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:Be(e)}),this}function Je(r){return r.re}function Xe(r){return r.im}function ze(r,e){return new pr(r.buffer,r.byteOffset+r.BYTES_PER_ELEMENT*e,2*(r.length-e))}function He(r,e){return new fr(r.buffer,r.byteOffset+r.BYTES_PER_ELEMENT*e,2*(r.length-e))}function qe(r){var e,t,n;for(e=[];!(t=r.next()).done;)if(oe(n=t.value)&&n.length>=2)e.push(n[0],n[1]);else{if(!Ce(n))return new TypeError($("invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",n));e.push(Je(n),Xe(n))}return e}K(Ze,"BYTES_PER_ELEMENT",4),K(Ze.prototype,"BYTES_PER_ELEMENT",4),K(Ze.prototype,"byteLength",8),K(Ze.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(Ze.prototype,"toJSON",(function(){var r={type:"Complex64"};return r.re=this.re,r.im=this.im,r}));var De=2*pr.BYTES_PER_ELEMENT,Ke=We();function Qe(r){return r instanceof tt||"object"==typeof r&&null!==r&&("Complex64Array"===r.constructor.name||"Complex128Array"===r.constructor.name)&&"number"==typeof r._length&&"object"==typeof r._buffer}function rt(r){return r===tt||"Complex128Array"===r.name}function et(r,e){return new Ze(r[e*=2],r[e+1])}function tt(){var r,e,t,n;if(e=arguments.length,!(this instanceof tt))return 0===e?new tt:1===e?new tt(arguments[0]):2===e?new tt(arguments[0],arguments[1]):new tt(arguments[0],arguments[1],arguments[2]);if(0===e)t=new pr(0);else if(1===e)if(ee(arguments[0]))t=new pr(2*arguments[0]);else if(ue(arguments[0]))if((n=(t=arguments[0]).length)&&f(t)&&Ce(t[0])){if(t=function(r,e){var t,n,i,o;for(t=e.length,o=0,i=0;i<t;i++){if(!Ce(n=e[i]))return null;r[o]=Je(n),r[o+1]=Xe(n),o+=2}return r}(new pr(2*n),t),null===t){if(!Me(n))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new pr(arguments[0])}}else{if(Ne(t))t=ze(t,0);else if(Ye(t))t=He(t,0);else if(!Me(n))throw new RangeError($("invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new pr(t)}else if(le(arguments[0])){if(!qr((t=arguments[0]).byteLength/De))throw new RangeError($("invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.",De,t.byteLength));t=new pr(t)}else{if(!se(arguments[0]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",arguments[0]));if(t=arguments[0],!1===Ke)throw new TypeError($("invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.",t));if(!ke(t[$e]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if(!ke((t=t[$e]()).next))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if((t=qe(t))instanceof Error)throw t;t=new pr(t)}else{if(!le(t=arguments[0]))throw new TypeError($("invalid argument. First argument must be an ArrayBuffer. Value: `%s`.",t));if(!ee(r=arguments[1]))throw new TypeError($("invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.",r));if(!qr(r/De))throw new RangeError($("invalid argument. Byte offset must be a multiple of %u. Value: `%u`.",De,r));if(2===e){if(!qr((n=t.byteLength-r)/De))throw new RangeError($("invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.",De,n));t=new pr(t,r)}else{if(!ee(n=arguments[2]))throw new TypeError($("invalid argument. Length must be a nonnegative integer. Value: `%s`.",n));if(n*De>t.byteLength-r)throw new RangeError($("invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.",n*De));t=new pr(t,r,2*n)}}return K(this,"_buffer",t),K(this,"_length",t.length/2),this}function nt(r,e){if(!(this instanceof nt))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:r}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:e}),this}function it(r){return r.re}function ot(r){return r.im}function at(r){var e,t,n;for(e=[];!(t=r.next()).done;)if(oe(n=t.value)&&n.length>=2)e.push(n[0],n[1]);else{if(!Ce(n))return new TypeError($("invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",n));e.push(it(n),ot(n))}return e}K(tt,"BYTES_PER_ELEMENT",De),K(tt,"name","Complex64Array"),K(tt,"from",(function(r){var e,t,n,i,o,a,u,f,l,s,c,m;if(!ke(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if((t=arguments.length)>1){if(!ke(n=arguments[1]))throw new TypeError($("invalid argument. Second argument must be a function. Value: `%s`.",n));t>2&&(e=arguments[2])}if(Qe(r)){if(f=r.length,n){for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Ce(s=n.call(e,r.get(c),c)))o[m]=Je(s),o[m+1]=Xe(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(ue(r)){if(n){for(f=r.length,u=r.get&&r.set?h("default"):p("default"),c=0;c<f;c++)if(!Ce(u(r,c))){l=!0;break}if(l){if(!Me(f))throw new RangeError($("invalid argument. First argument must have a length which is a multiple of %u. Length: `%u`.",2,f));for(o=(i=new this(f/2))._buffer,c=0;c<f;c++)o[c]=n.call(e,u(r,c),c);return i}for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Ce(s=n.call(e,u(r,c),c)))o[m]=Je(s),o[m+1]=Xe(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(se(r)&&Ke&&ke(r[$e])){if(!ke((o=r[$e]()).next))throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r));if(a=n?function(r,e,t){var n,i,o,a;for(n=[],a=-1;!(i=r.next()).done;)if(a+=1,oe(o=e.call(t,i.value,a))&&o.length>=2)n.push(o[0],o[1]);else{if(!Ce(o))return new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",o));n.push(Je(o),Xe(o))}return n}(o,n,e):qe(o),a instanceof Error)throw a;for(o=(i=new this(f=a.length/2))._buffer,c=0;c<f;c++)o[c]=a[c];return i}throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r))})),K(tt,"of",(function(){var r,e;if(!ke(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=0;e<arguments.length;e++)r.push(arguments[e]);return new this(r)})),K(tt.prototype,"at",(function(r){if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. Must provide an integer. Value: `%s`.",r));if(r<0&&(r+=this._length),!(r<0||r>=this._length))return et(this._buffer,r)})),Ge(tt.prototype,"buffer",(function(){return this._buffer.buffer})),Ge(tt.prototype,"byteLength",(function(){return this._buffer.byteLength})),Ge(tt.prototype,"byteOffset",(function(){return this._buffer.byteOffset})),K(tt.prototype,"BYTES_PER_ELEMENT",tt.BYTES_PER_ELEMENT),K(tt.prototype,"copyWithin",(function(r,e){if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return 2===arguments.length?this._buffer.copyWithin(2*r,2*e):this._buffer.copyWithin(2*r,2*e,2*arguments[2]),this})),K(tt.prototype,"entries",(function(){var r,e,t,n,i,o,a;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return e=this,r=this._buffer,n=this._length,o=-1,a=-2,K(t={},"next",(function(){var e;return o+=1,i||o>=n?{done:!0}:(e=new Ze(r[a+=2],r[a+1]),{value:[o,e],done:!1})})),K(t,"return",(function(r){return i=!0,arguments.length?{value:r,done:!0}:{done:!0}})),$e&&K(t,$e,(function(){return e.entries()})),t})),K(tt.prototype,"every",(function(r,e){var t,n;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(!r.call(e,et(t,n),n,this))return!1;return!0})),K(tt.prototype,"fill",(function(r,e,t){var n,i,o,a,u,f;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(n=this._buffer,i=this._length,arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));if(e<0&&(e+=i)<0&&(e=0),arguments.length>2){if(!qr(t))throw new TypeError($("invalid argument. Third argument must be an integer. Value: `%s`.",t));t<0&&(t+=i)<0&&(t=0),t>i&&(t=i)}else t=i}else e=0,t=i;for(a=Je(r),u=Xe(r),f=e;f<t;f++)n[o=2*f]=a,n[o+1]=u;return this})),K(tt.prototype,"filter",(function(r,e){var t,n,i,o;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=[],i=0;i<this._length;i++)o=et(t,i),r.call(e,o,i,this)&&n.push(o);return new this.constructor(n)})),K(tt.prototype,"find",(function(r,e){var t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=et(t,n),r.call(e,i,n,this))return i})),K(tt.prototype,"findIndex",(function(r,e){var t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=et(t,n),r.call(e,i,n,this))return n;return-1})),K(tt.prototype,"findLast",(function(r,e){var t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=et(t,n),r.call(e,i,n,this))return i})),K(tt.prototype,"findLastIndex",(function(r,e){var t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=et(t,n),r.call(e,i,n,this))return n;return-1})),K(tt.prototype,"forEach",(function(r,e){var t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)i=et(t,n),r.call(e,i,n,this)})),K(tt.prototype,"get",(function(r){if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ee(r))throw new TypeError($("invalid argument. Must provide a nonnegative integer. Value: `%s`.",r));if(!(r>=this._length))return et(this._buffer,r)})),K(tt.prototype,"includes",(function(r,e){var t,n,i,o,a;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=Je(r),o=Xe(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return!0;return!1})),K(tt.prototype,"indexOf",(function(r,e){var t,n,i,o,a;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=Je(r),o=Xe(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),K(tt.prototype,"join",(function(r){var e,t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(0===arguments.length)n=",";else{if(!he(r))throw new TypeError($("invalid argument. First argument must be a string. Value: `%s`.",r));n=r}for(e=[],t=this._buffer,i=0;i<this._length;i++)e.push(et(t,i).toString());return e.join(n)})),K(tt.prototype,"lastIndexOf",(function(r,e){var t,n,i,o,a;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e>=this._length?e=this._length-1:e<0&&(e+=this._length)}else e=this._length-1;for(i=Je(r),o=Xe(r),t=this._buffer,a=e;a>=0;a--)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),Ge(tt.prototype,"length",(function(){return this._length})),K(tt.prototype,"map",(function(r,e){var t,n,i,o,a;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(n=this._buffer,t=(i=new this.constructor(this._length))._buffer,o=0;o<this._length;o++)if(Ce(a=r.call(e,et(n,o),o,this)))t[2*o]=Je(a),t[2*o+1]=Xe(a);else{if(!oe(a)||2!==a.length)throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",a));t[2*o]=a[0],t[2*o+1]=a[1]}return i})),K(tt.prototype,"reduce",(function(r,e){var t,n,i,o;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));if(t=this._buffer,i=this._length,arguments.length>1)n=e,o=0;else{if(0===i)throw new Error("invalid operation. If not provided an initial value, an array must contain at least one element.");n=et(t,0),o=1}for(;o<i;o++)n=r(n,et(t,o),o,this);return n})),K(tt.prototype,"reverse",(function(){var r,e,t,n,i,o;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,r=this._buffer,n=Hr(t/2),i=0;i<n;i++)o=t-i-1,e=r[2*i],r[2*i]=r[2*o],r[2*o]=e,e=r[2*i+1],r[2*i+1]=r[2*o+1],r[2*o+1]=e;return this})),K(tt.prototype,"set",(function(r){var e,t,n,i,o,a,u,f,l;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,arguments.length>1){if(!ee(t=arguments[1]))throw new TypeError($("invalid argument. Index argument must be a nonnegative integer. Value: `%s`.",t))}else t=0;if(Ce(r)){if(t>=this._length)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%u`.",t));return n[t*=2]=Je(r),void(n[t+1]=Xe(r))}if(Qe(r)){if(t+(a=r._length)>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r._buffer,l=n.byteOffset+t*De,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new pr(e.length),f=0;f<e.length;f++)i[f]=e[f];e=i}for(t*=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2}else{if(!ue(r))throw new TypeError($("invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.",r));for(a=r.length,f=0;f<a;f++)if(!Ce(r[f])){o=!0;break}if(o){if(!Me(a))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",a));if(t+a/2>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r,l=n.byteOffset+t*De,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new pr(a),f=0;f<a;f++)i[f]=e[f];e=i}for(t*=2,a/=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2;return}if(t+a>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");for(t*=2,f=0;f<a;f++)u=r[f],n[t]=Je(u),n[t+1]=Xe(u),t+=2}})),K(tt.prototype,"slice",(function(r,e){var t,n,i,o,a,u,f;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(a=this._buffer,u=this._length,0===arguments.length)r=0,e=u;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=u)<0&&(r=0),1===arguments.length)e=u;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=u)<0&&(e=0):e>u&&(e=u)}}for(t=r<e?e-r:0,n=(i=new this.constructor(t))._buffer,f=0;f<t;f++)o=2*(f+r),n[2*f]=a[o],n[2*f+1]=a[o+1];return i})),K(tt.prototype,"some",(function(r,e){var t,n;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(r.call(e,et(t,n),n,this))return!0;return!1})),K(tt.prototype,"subarray",(function(r,e){var t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,i=this._length,0===arguments.length)r=0,e=i;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=i)<0&&(r=0),1===arguments.length)e=i;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=i)<0&&(e=0):e>i&&(e=i)}}return r>=i?(i=0,t=n.byteLength):r>=e?(i=0,t=n.byteOffset+r*De):(i=e-r,t=n.byteOffset+r*De),new this.constructor(n.buffer,t,i<0?0:i)})),K(tt.prototype,"toReversed",(function(){var r,e,t,n,i,o;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,e=new this.constructor(t),n=this._buffer,r=e._buffer,i=0;i<t;i++)o=t-i-1,r[2*i]=n[2*o],r[2*i+1]=n[2*o+1];return e})),K(tt.prototype,"toString",(function(){var r,e,t;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=this._buffer,t=0;t<this._length;t++)r.push(et(e,t).toString());return r.join(",")})),K(tt.prototype,"with",(function(r,e){var t,n,i;if(!Qe(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(i=this._length,r<0&&(r+=i),r<0||r>=i)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%s`.",r));if(!Ce(e))throw new TypeError($("invalid argument. Second argument must be a complex number. Value: `%s`.",e));return(t=(n=new this.constructor(this._buffer))._buffer)[2*r]=Je(e),t[2*r+1]=Xe(e),n})),K(nt,"BYTES_PER_ELEMENT",8),K(nt.prototype,"BYTES_PER_ELEMENT",8),K(nt.prototype,"byteLength",16),K(nt.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(nt.prototype,"toJSON",(function(){var r={type:"Complex128"};return r.re=this.re,r.im=this.im,r}));var ut=2*fr.BYTES_PER_ELEMENT,ft=We();function lt(r){return r instanceof ct||"object"==typeof r&&null!==r&&("Complex64Array"===r.constructor.name||"Complex128Array"===r.constructor.name)&&"number"==typeof r._length&&"object"==typeof r._buffer}function st(r){return r===ct||"Complex64Array"===r.name}function ht(r,e){return new nt(r[e*=2],r[e+1])}function ct(){var r,e,t,n;if(e=arguments.length,!(this instanceof ct))return 0===e?new ct:1===e?new ct(arguments[0]):2===e?new ct(arguments[0],arguments[1]):new ct(arguments[0],arguments[1],arguments[2]);if(0===e)t=new fr(0);else if(1===e)if(ee(arguments[0]))t=new fr(2*arguments[0]);else if(ue(arguments[0]))if((n=(t=arguments[0]).length)&&f(t)&&Ce(t[0])){if(t=function(r,e){var t,n,i,o;for(t=e.length,o=0,i=0;i<t;i++){if(!Ce(n=e[i]))return null;r[o]=it(n),r[o+1]=ot(n),o+=2}return r}(new fr(2*n),t),null===t){if(!Me(n))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new fr(arguments[0])}}else{if(Ne(t))t=ze(t,0);else if(Ye(t))t=He(t,0);else if(!Me(n))throw new RangeError($("invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new fr(t)}else if(le(arguments[0])){if(!qr((t=arguments[0]).byteLength/ut))throw new RangeError($("invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.",ut,t.byteLength));t=new fr(t)}else{if(!se(arguments[0]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",arguments[0]));if(t=arguments[0],!1===ft)throw new TypeError($("invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.",t));if(!ke(t[$e]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if(!ke((t=t[$e]()).next))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if((t=at(t))instanceof Error)throw t;t=new fr(t)}else{if(!le(t=arguments[0]))throw new TypeError($("invalid argument. First argument must be an ArrayBuffer. Value: `%s`.",t));if(!ee(r=arguments[1]))throw new TypeError($("invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.",r));if(!qr(r/ut))throw new RangeError($("invalid argument. Byte offset must be a multiple of %u. Value: `%u`.",ut,r));if(2===e){if(!qr((n=t.byteLength-r)/ut))throw new RangeError($("invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.",ut,n));t=new fr(t,r)}else{if(!ee(n=arguments[2]))throw new TypeError($("invalid argument. Length must be a nonnegative integer. Value: `%s`.",n));if(n*ut>t.byteLength-r)throw new RangeError($("invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.",n*ut));t=new fr(t,r,2*n)}}return K(this,"_buffer",t),K(this,"_length",t.length/2),this}K(ct,"BYTES_PER_ELEMENT",ut),K(ct,"name","Complex128Array"),K(ct,"from",(function(r){var e,t,n,i,o,a,u,f,l,s,c,m;if(!ke(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if((t=arguments.length)>1){if(!ke(n=arguments[1]))throw new TypeError($("invalid argument. Second argument must be a function. Value: `%s`.",n));t>2&&(e=arguments[2])}if(lt(r)){if(f=r.length,n){for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Ce(s=n.call(e,r.get(c),c)))o[m]=it(s),o[m+1]=ot(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(ue(r)){if(n){for(f=r.length,u=r.get&&r.set?h("default"):p("default"),c=0;c<f;c++)if(!Ce(u(r,c))){l=!0;break}if(l){if(!Me(f))throw new RangeError($("invalid argument. First argument must have a length which is a multiple of two. Length: `%u`.",f));for(o=(i=new this(f/2))._buffer,c=0;c<f;c++)o[c]=n.call(e,u(r,c),c);return i}for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Ce(s=n.call(e,u(r,c),c)))o[m]=it(s),o[m+1]=ot(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(se(r)&&ft&&ke(r[$e])){if(!ke((o=r[$e]()).next))throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r));if(a=n?function(r,e,t){var n,i,o,a;for(n=[],a=-1;!(i=r.next()).done;)if(a+=1,oe(o=e.call(t,i.value,a))&&o.length>=2)n.push(o[0],o[1]);else{if(!Ce(o))return new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",o));n.push(it(o),ot(o))}return n}(o,n,e):at(o),a instanceof Error)throw a;for(o=(i=new this(f=a.length/2))._buffer,c=0;c<f;c++)o[c]=a[c];return i}throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r))})),K(ct,"of",(function(){var r,e;if(!ke(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=0;e<arguments.length;e++)r.push(arguments[e]);return new this(r)})),K(ct.prototype,"at",(function(r){if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. Must provide an integer. Value: `%s`.",r));if(r<0&&(r+=this._length),!(r<0||r>=this._length))return ht(this._buffer,r)})),Ge(ct.prototype,"buffer",(function(){return this._buffer.buffer})),Ge(ct.prototype,"byteLength",(function(){return this._buffer.byteLength})),Ge(ct.prototype,"byteOffset",(function(){return this._buffer.byteOffset})),K(ct.prototype,"BYTES_PER_ELEMENT",ct.BYTES_PER_ELEMENT),K(ct.prototype,"copyWithin",(function(r,e){if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return 2===arguments.length?this._buffer.copyWithin(2*r,2*e):this._buffer.copyWithin(2*r,2*e,2*arguments[2]),this})),K(ct.prototype,"entries",(function(){var r,e,t,n,i,o,a;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return e=this,r=this._buffer,n=this._length,o=-1,a=-2,K(t={},"next",(function(){var e;return o+=1,i||o>=n?{done:!0}:(e=new nt(r[a+=2],r[a+1]),{value:[o,e],done:!1})})),K(t,"return",(function(r){return i=!0,arguments.length?{value:r,done:!0}:{done:!0}})),$e&&K(t,$e,(function(){return e.entries()})),t})),K(ct.prototype,"every",(function(r,e){var t,n;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(!r.call(e,ht(t,n),n,this))return!1;return!0})),K(ct.prototype,"fill",(function(r,e,t){var n,i,o,a,u,f;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(n=this._buffer,i=this._length,arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));if(e<0&&(e+=i)<0&&(e=0),arguments.length>2){if(!qr(t))throw new TypeError($("invalid argument. Third argument must be an integer. Value: `%s`.",t));t<0&&(t+=i)<0&&(t=0),t>i&&(t=i)}else t=i}else e=0,t=i;for(a=it(r),u=ot(r),f=e;f<t;f++)n[o=2*f]=a,n[o+1]=u;return this})),K(ct.prototype,"filter",(function(r,e){var t,n,i,o;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=[],i=0;i<this._length;i++)o=ht(t,i),r.call(e,o,i,this)&&n.push(o);return new this.constructor(n)})),K(ct.prototype,"find",(function(r,e){var t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=ht(t,n),r.call(e,i,n,this))return i})),K(ct.prototype,"findIndex",(function(r,e){var t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=ht(t,n),r.call(e,i,n,this))return n;return-1})),K(ct.prototype,"findLast",(function(r,e){var t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=ht(t,n),r.call(e,i,n,this))return i})),K(ct.prototype,"findLastIndex",(function(r,e){var t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=ht(t,n),r.call(e,i,n,this))return n;return-1})),K(ct.prototype,"forEach",(function(r,e){var t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)i=ht(t,n),r.call(e,i,n,this)})),K(ct.prototype,"get",(function(r){if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ee(r))throw new TypeError($("invalid argument. Must provide a nonnegative integer. Value: `%s`.",r));if(!(r>=this._length))return ht(this._buffer,r)})),Ge(ct.prototype,"length",(function(){return this._length})),K(ct.prototype,"includes",(function(r,e){var t,n,i,o,a;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=it(r),o=ot(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return!0;return!1})),K(ct.prototype,"indexOf",(function(r,e){var t,n,i,o,a;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=it(r),o=ot(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),K(ct.prototype,"join",(function(r){var e,t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(0===arguments.length)n=",";else{if(!ye(r))throw new TypeError($("invalid argument. First argument must be a string. Value: `%s`.",r));n=r}for(e=[],t=this._buffer,i=0;i<this._length;i++)e.push(ht(t,i).toString());return e.join(n)})),K(ct.prototype,"lastIndexOf",(function(r,e){var t,n,i,o,a;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ce(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e>=this._length?e=this._length-1:e<0&&(e+=this._length)}else e=this._length-1;for(i=it(r),o=ot(r),t=this._buffer,a=e;a>=0;a--)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),K(ct.prototype,"map",(function(r,e){var t,n,i,o,a;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(n=this._buffer,t=(i=new this.constructor(this._length))._buffer,o=0;o<this._length;o++)if(Ce(a=r.call(e,ht(n,o),o,this)))t[2*o]=it(a),t[2*o+1]=ot(a);else{if(!oe(a)||2!==a.length)throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",a));t[2*o]=a[0],t[2*o+1]=a[1]}return i})),K(ct.prototype,"reduce",(function(r,e){var t,n,i,o;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));if(t=this._buffer,i=this._length,arguments.length>1)n=e,o=0;else{if(0===i)throw new Error("invalid operation. If not provided an initial value, an array must contain at least one element.");n=ht(t,0),o=1}for(;o<i;o++)n=r(n,ht(t,o),o,this);return n})),K(ct.prototype,"reverse",(function(){var r,e,t,n,i,o;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,r=this._buffer,n=Hr(t/2),i=0;i<n;i++)o=t-i-1,e=r[2*i],r[2*i]=r[2*o],r[2*o]=e,e=r[2*i+1],r[2*i+1]=r[2*o+1],r[2*o+1]=e;return this})),K(ct.prototype,"set",(function(r){var e,t,n,i,o,a,u,f,l;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,arguments.length>1){if(!ee(t=arguments[1]))throw new TypeError($("invalid argument. Index argument must be a nonnegative integer. Value: `%s`.",t))}else t=0;if(Ce(r)){if(t>=this._length)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%u`.",t));return n[t*=2]=it(r),void(n[t+1]=ot(r))}if(lt(r)){if(t+(a=r._length)>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r._buffer,l=n.byteOffset+t*ut,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new fr(e.length),f=0;f<e.length;f++)i[f]=e[f];e=i}for(t*=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2}else{if(!ue(r))throw new TypeError($("invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.",r));for(a=r.length,f=0;f<a;f++)if(!Ce(r[f])){o=!0;break}if(o){if(!Me(a))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",a));if(t+a/2>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r,l=n.byteOffset+t*ut,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new fr(a),f=0;f<a;f++)i[f]=e[f];e=i}for(t*=2,a/=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2;return}if(t+a>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");for(t*=2,f=0;f<a;f++)u=r[f],n[t]=it(u),n[t+1]=ot(u),t+=2}})),K(ct.prototype,"slice",(function(r,e){var t,n,i,o,a,u,f;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(a=this._buffer,u=this._length,0===arguments.length)r=0,e=u;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=u)<0&&(r=0),1===arguments.length)e=u;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=u)<0&&(e=0):e>u&&(e=u)}}for(t=r<e?e-r:0,n=(i=new this.constructor(t))._buffer,f=0;f<t;f++)o=2*(f+r),n[2*f]=a[o],n[2*f+1]=a[o+1];return i})),K(ct.prototype,"some",(function(r,e){var t,n;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ke(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(r.call(e,ht(t,n),n,this))return!0;return!1})),K(ct.prototype,"subarray",(function(r,e){var t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,i=this._length,0===arguments.length)r=0,e=i;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=i)<0&&(r=0),1===arguments.length)e=i;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=i)<0&&(e=0):e>i&&(e=i)}}return r>=i?(i=0,t=n.byteLength):r>=e?(i=0,t=n.byteOffset+r*ut):(i=e-r,t=n.byteOffset+r*ut),new this.constructor(n.buffer,t,i<0?0:i)})),K(ct.prototype,"toReversed",(function(){var r,e,t,n,i,o;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,e=new this.constructor(t),n=this._buffer,r=e._buffer,i=0;i<t;i++)o=t-i-1,r[2*i]=n[2*o],r[2*i+1]=n[2*o+1];return e})),K(ct.prototype,"toString",(function(){var r,e,t;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=this._buffer,t=0;t<this._length;t++)r.push(ht(e,t).toString());return r.join(",")})),K(ct.prototype,"with",(function(r,e){var t,n,i;if(!lt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(i=this._length,r<0&&(r+=i),r<0||r>=i)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%s`.",r));if(!Ce(e))throw new TypeError($("invalid argument. Second argument must be a complex number. Value: `%s`.",e));return(t=(n=new this.constructor(this._buffer))._buffer)[2*r]=it(e),t[2*r+1]=ot(e),n}));var pt=[fr,pr,Er,wr,Fr,Ar,Yr,Rr,Mr,tt,ct],mt=["float64","float32","int32","uint32","int16","uint16","int8","uint8","uint8c","complex64","complex128"],yt=mt.length;function gt(r){var e,t=function(r){var e;if(f(r))return"generic";if(rr(r))return null;for(e=0;e<yt;e++)if(r instanceof pt[e])return mt[e];return ir[nr(r)]||null}(r);return typeof(e=r).get===l&&typeof e.set===l?h(t):p(t)}return function(r,e){var t,n,i,o,a,u,l,s;if(i=r.length,e.length!==i)throw new RangeError(function(){var r,e=arguments,t="https://stdlib.io/e/"+e[0]+"?";for(r=1;r<e.length;r++)t+="&arg[]="+encodeURIComponent(e[r]);return t}("1nHFI"));for(t=gt(r),n=gt(e),o={},s=0;s<i;s++)l=t(r,s),u=o[a=n(e,s).toString()],f(u)?u.push([s,l]):o[a]=[[s,l]];return o}},"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(r="undefined"!=typeof globalThis?globalThis:r||self).groupEntries=e(); +//# sourceMappingURL=browser.js.map diff --git a/browser.js.map b/browser.js.map new file mode 100644 index 0000000..432c60e --- /dev/null +++ b/browser.js.map @@ -0,0 +1 @@ +{"version":3,"file":"browser.js","sources":["../node_modules/@stdlib/assert-has-tostringtag-support/lib/main.js","../node_modules/@stdlib/assert-has-symbol-support/lib/main.js","../node_modules/@stdlib/utils-native-class/lib/tostring.js","../node_modules/@stdlib/assert-has-own-property/lib/main.js","../node_modules/@stdlib/symbol-ctor/lib/main.js","../node_modules/@stdlib/utils-native-class/lib/tostringtag.js","../node_modules/@stdlib/utils-native-class/lib/index.js","../node_modules/@stdlib/utils-native-class/lib/polyfill.js","../node_modules/@stdlib/utils-native-class/lib/main.js","../node_modules/@stdlib/assert-is-array/lib/main.js","../node_modules/@stdlib/array-base-assert-is-accessor-array/lib/main.js","../node_modules/@stdlib/array-base-accessor-getter/lib/main.js","../node_modules/@stdlib/array-base-getter/lib/main.js","../node_modules/@stdlib/utils-define-property/lib/define_property.js","../node_modules/@stdlib/utils-define-property/lib/builtin.js","../node_modules/@stdlib/string-base-format-interpolate/lib/is_number.js","../node_modules/@stdlib/string-base-format-interpolate/lib/zero_pad.js","../node_modules/@stdlib/string-base-format-interpolate/lib/format_integer.js","../node_modules/@stdlib/string-base-format-interpolate/lib/format_double.js","../node_modules/@stdlib/string-base-format-interpolate/lib/space_pad.js","../node_modules/@stdlib/string-base-format-interpolate/lib/main.js","../node_modules/@stdlib/string-base-format-interpolate/lib/is_string.js","../node_modules/@stdlib/string-base-format-tokenize/lib/main.js","../node_modules/@stdlib/string-format/lib/main.js","../node_modules/@stdlib/string-format/lib/is_string.js","../node_modules/@stdlib/utils-define-property/lib/polyfill.js","../node_modules/@stdlib/utils-define-property/lib/index.js","../node_modules/@stdlib/utils-define-property/lib/has_define_property_support.js","../node_modules/@stdlib/utils-define-nonenumerable-read-only-property/lib/main.js","../node_modules/@stdlib/assert-is-object-like/lib/main.js","../node_modules/@stdlib/assert-is-buffer/lib/main.js","../node_modules/@stdlib/regexp-function-name/lib/main.js","../node_modules/@stdlib/assert-is-object-like/lib/index.js","../node_modules/@stdlib/assert-tools-array-function/lib/main.js","../node_modules/@stdlib/regexp-function-name/lib/regexp.js","../node_modules/@stdlib/utils-constructor-name/lib/main.js","../node_modules/@stdlib/regexp-function-name/lib/index.js","../node_modules/@stdlib/array-dtype/lib/ctor2dtype.js","../node_modules/@stdlib/assert-is-float64array/lib/main.js","../node_modules/@stdlib/assert-has-float64array-support/lib/float64array.js","../node_modules/@stdlib/array-float64/lib/main.js","../node_modules/@stdlib/array-float64/lib/index.js","../node_modules/@stdlib/assert-has-float64array-support/lib/main.js","../node_modules/@stdlib/array-float64/lib/polyfill.js","../node_modules/@stdlib/assert-is-float32array/lib/main.js","../node_modules/@stdlib/constants-float64-pinf/lib/index.js","../node_modules/@stdlib/assert-has-float32array-support/lib/float32array.js","../node_modules/@stdlib/array-float32/lib/main.js","../node_modules/@stdlib/array-float32/lib/index.js","../node_modules/@stdlib/assert-has-float32array-support/lib/main.js","../node_modules/@stdlib/array-float32/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint32array/lib/main.js","../node_modules/@stdlib/assert-has-uint32array-support/lib/uint32array.js","../node_modules/@stdlib/array-uint32/lib/main.js","../node_modules/@stdlib/array-uint32/lib/index.js","../node_modules/@stdlib/assert-has-uint32array-support/lib/main.js","../node_modules/@stdlib/array-uint32/lib/polyfill.js","../node_modules/@stdlib/assert-is-int32array/lib/main.js","../node_modules/@stdlib/assert-has-int32array-support/lib/int32array.js","../node_modules/@stdlib/array-int32/lib/main.js","../node_modules/@stdlib/array-int32/lib/index.js","../node_modules/@stdlib/assert-has-int32array-support/lib/main.js","../node_modules/@stdlib/constants-int32-min/lib/index.js","../node_modules/@stdlib/array-int32/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint16array/lib/main.js","../node_modules/@stdlib/assert-has-uint16array-support/lib/uint16array.js","../node_modules/@stdlib/array-uint16/lib/main.js","../node_modules/@stdlib/array-uint16/lib/index.js","../node_modules/@stdlib/assert-has-uint16array-support/lib/main.js","../node_modules/@stdlib/array-uint16/lib/polyfill.js","../node_modules/@stdlib/assert-is-int16array/lib/main.js","../node_modules/@stdlib/assert-has-int16array-support/lib/int16array.js","../node_modules/@stdlib/array-int16/lib/main.js","../node_modules/@stdlib/array-int16/lib/index.js","../node_modules/@stdlib/assert-has-int16array-support/lib/main.js","../node_modules/@stdlib/constants-int16-min/lib/index.js","../node_modules/@stdlib/array-int16/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint8array/lib/main.js","../node_modules/@stdlib/assert-has-uint8array-support/lib/uint8array.js","../node_modules/@stdlib/array-uint8/lib/main.js","../node_modules/@stdlib/array-uint8/lib/index.js","../node_modules/@stdlib/assert-has-uint8array-support/lib/main.js","../node_modules/@stdlib/array-uint8/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint8clampedarray/lib/main.js","../node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/uint8clampedarray.js","../node_modules/@stdlib/array-uint8c/lib/main.js","../node_modules/@stdlib/array-uint8c/lib/index.js","../node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/main.js","../node_modules/@stdlib/array-uint8c/lib/polyfill.js","../node_modules/@stdlib/assert-is-int8array/lib/main.js","../node_modules/@stdlib/assert-has-int8array-support/lib/int8array.js","../node_modules/@stdlib/array-int8/lib/main.js","../node_modules/@stdlib/array-int8/lib/index.js","../node_modules/@stdlib/assert-has-int8array-support/lib/main.js","../node_modules/@stdlib/constants-int8-min/lib/index.js","../node_modules/@stdlib/array-int8/lib/polyfill.js","../node_modules/@stdlib/assert-is-number/lib/primitive.js","../node_modules/@stdlib/number-ctor/lib/main.js","../node_modules/@stdlib/assert-is-number/lib/tostring.js","../node_modules/@stdlib/assert-is-number/lib/object.js","../node_modules/@stdlib/assert-is-number/lib/try2serialize.js","../node_modules/@stdlib/assert-is-number/lib/main.js","../node_modules/@stdlib/assert-is-number/lib/index.js","../node_modules/@stdlib/constants-float64-ninf/lib/index.js","../node_modules/@stdlib/math-base-special-floor/lib/main.js","../node_modules/@stdlib/math-base-assert-is-integer/lib/main.js","../node_modules/@stdlib/assert-is-integer/lib/integer.js","../node_modules/@stdlib/assert-is-integer/lib/primitive.js","../node_modules/@stdlib/assert-is-integer/lib/object.js","../node_modules/@stdlib/assert-is-integer/lib/main.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/primitive.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/object.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/main.js","../node_modules/@stdlib/assert-is-integer/lib/index.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/index.js","../node_modules/@stdlib/constants-array-max-array-length/lib/index.js","../node_modules/@stdlib/assert-is-array-like-object/lib/main.js","../node_modules/@stdlib/constants-array-max-typed-array-length/lib/index.js","../node_modules/@stdlib/assert-is-collection/lib/main.js","../node_modules/@stdlib/assert-is-arraybuffer/lib/main.js","../node_modules/@stdlib/assert-is-object/lib/main.js","../node_modules/@stdlib/assert-is-string/lib/primitive.js","../node_modules/@stdlib/assert-is-string/lib/valueof.js","../node_modules/@stdlib/assert-is-string/lib/object.js","../node_modules/@stdlib/assert-is-string/lib/try2valueof.js","../node_modules/@stdlib/assert-is-string/lib/main.js","../node_modules/@stdlib/assert-is-string/lib/index.js","../node_modules/@stdlib/utils-type-of/lib/fixtures/re.js","../node_modules/@stdlib/assert-is-boolean/lib/primitive.js","../node_modules/@stdlib/boolean-ctor/lib/main.js","../node_modules/@stdlib/assert-is-boolean/lib/tostring.js","../node_modules/@stdlib/assert-is-boolean/lib/object.js","../node_modules/@stdlib/assert-is-boolean/lib/try2serialize.js","../node_modules/@stdlib/assert-is-boolean/lib/main.js","../node_modules/@stdlib/assert-is-boolean/lib/index.js","../node_modules/@stdlib/utils-global/lib/self.js","../node_modules/@stdlib/utils-global/lib/window.js","../node_modules/@stdlib/utils-global/lib/global_this.js","../node_modules/@stdlib/utils-type-of/lib/fixtures/nodelist.js","../node_modules/@stdlib/utils-global/lib/browser.js","../node_modules/@stdlib/utils-global/lib/codegen.js","../node_modules/@stdlib/utils-type-of/lib/fixtures/typedarray.js","../node_modules/@stdlib/utils-type-of/lib/index.js","../node_modules/@stdlib/utils-type-of/lib/check.js","../node_modules/@stdlib/utils-type-of/lib/polyfill.js","../node_modules/@stdlib/utils-type-of/lib/main.js","../node_modules/@stdlib/assert-is-function/lib/main.js","../node_modules/@stdlib/complex-float64-ctor/lib/main.js","../node_modules/@stdlib/complex-float64-ctor/lib/tostring.js","../node_modules/@stdlib/complex-float64-ctor/lib/tojson.js","../node_modules/@stdlib/number-float64-base-to-float32/lib/main.js","../node_modules/@stdlib/number-float64-base-to-float32/lib/polyfill.js","../node_modules/@stdlib/number-float64-base-to-float32/lib/index.js","../node_modules/@stdlib/complex-float32-ctor/lib/main.js","../node_modules/@stdlib/assert-is-complex-like/lib/main.js","../node_modules/@stdlib/math-base-assert-is-even/lib/main.js","../node_modules/@stdlib/complex-float32-ctor/lib/tostring.js","../node_modules/@stdlib/complex-float32-ctor/lib/tojson.js","../node_modules/@stdlib/array-base-assert-is-complex64array/lib/main.js","../node_modules/@stdlib/array-base-assert-is-complex128array/lib/main.js","../node_modules/@stdlib/assert-has-iterator-symbol-support/lib/main.js","../node_modules/@stdlib/symbol-iterator/lib/main.js","../node_modules/@stdlib/utils-define-nonenumerable-read-only-accessor/lib/main.js","../node_modules/@stdlib/complex-float32/lib/main.js","../node_modules/@stdlib/complex-realf/lib/main.js","../node_modules/@stdlib/complex-imagf/lib/main.js","../node_modules/@stdlib/strided-base-reinterpret-complex64/lib/main.js","../node_modules/@stdlib/strided-base-reinterpret-complex128/lib/main.js","../node_modules/@stdlib/array-complex64/lib/from_iterator.js","../node_modules/@stdlib/complex-float32/lib/tostring.js","../node_modules/@stdlib/complex-float32/lib/tojson.js","../node_modules/@stdlib/array-complex64/lib/main.js","../node_modules/@stdlib/array-complex64/lib/from_array.js","../node_modules/@stdlib/complex-float64/lib/main.js","../node_modules/@stdlib/complex-real/lib/main.js","../node_modules/@stdlib/complex-imag/lib/main.js","../node_modules/@stdlib/array-complex128/lib/from_iterator.js","../node_modules/@stdlib/array-complex64/lib/from_iterator_map.js","../node_modules/@stdlib/complex-float64/lib/tostring.js","../node_modules/@stdlib/complex-float64/lib/tojson.js","../node_modules/@stdlib/array-complex128/lib/main.js","../node_modules/@stdlib/array-complex128/lib/from_array.js","../node_modules/@stdlib/array-complex128/lib/from_iterator_map.js","../node_modules/@stdlib/array-dtype/lib/ctors.js","../node_modules/@stdlib/array-dtype/lib/dtypes.js","../node_modules/@stdlib/array-dtype/lib/main.js","../node_modules/@stdlib/array-base-resolve-getter/lib/main.js","../lib/main.js","../node_modules/@stdlib/error-tools-fmtprodmsg/lib/main.js"],"sourcesContent":["/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasSymbols from '@stdlib/assert-has-symbol-support';\n\n\n// VARIABLES //\n\nvar FLG = hasSymbols();\n\n\n// MAIN //\n\n/**\n* Tests for native `toStringTag` support.\n*\n* @returns {boolean} boolean indicating if an environment has `toStringTag` support\n*\n* @example\n* var bool = hasToStringTagSupport();\n* // returns <boolean>\n*/\nfunction hasToStringTagSupport() {\n\treturn ( FLG && typeof Symbol.toStringTag === 'symbol' );\n}\n\n\n// EXPORTS //\n\nexport default hasToStringTagSupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Tests for native `Symbol` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Symbol` support\n*\n* @example\n* var bool = hasSymbolSupport();\n* // returns <boolean>\n*/\nfunction hasSymbolSupport() {\n\treturn (\n\t\ttypeof Symbol === 'function' &&\n\t\ttypeof Symbol( 'foo' ) === 'symbol'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default hasSymbolSupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar toStr = Object.prototype.toString;\n\n\n// EXPORTS //\n\nexport default toStr;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// FUNCTIONS //\n\nvar has = Object.prototype.hasOwnProperty;\n\n\n// MAIN //\n\n/**\n* Tests if an object has a specified property.\n*\n* @param {*} value - value to test\n* @param {*} property - property to test\n* @returns {boolean} boolean indicating if an object has a specified property\n*\n* @example\n* var beep = {\n* 'boop': true\n* };\n*\n* var bool = hasOwnProp( beep, 'boop' );\n* // returns true\n*\n* @example\n* var beep = {\n* 'boop': true\n* };\n*\n* var bool = hasOwnProp( beep, 'bap' );\n* // returns false\n*/\nfunction hasOwnProp( value, property ) {\n\tif (\n\t\tvalue === void 0 ||\n\t\tvalue === null\n\t) {\n\t\treturn false;\n\t}\n\treturn has.call( value, property );\n}\n\n\n// EXPORTS //\n\nexport default hasOwnProp;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar Sym = ( typeof Symbol === 'function' ) ? Symbol : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default Sym;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Symbol from '@stdlib/symbol-ctor';\n\n\n// MAIN //\n\nvar toStrTag = ( typeof Symbol === 'function' ) ? Symbol.toStringTag : '';\n\n\n// EXPORTS //\n\nexport default toStrTag;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Return a string value indicating a specification defined classification of an object.\n*\n* @module @stdlib/utils-native-class\n*\n* @example\n* import nativeClass from '@stdlib/utils-native-class';\n*\n* var str = nativeClass( 'a' );\n* // returns '[object String]'\n*\n* str = nativeClass( 5 );\n* // returns '[object Number]'\n*\n* function Beep() {\n* return this;\n* }\n* str = nativeClass( new Beep() );\n* // returns '[object Object]'\n*/\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar main;\nif ( hasToStringTag() ) {\n\tmain = polyfill;\n} else {\n\tmain = builtin;\n}\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasOwnProp from '@stdlib/assert-has-own-property';\nimport toStringTag from './tostringtag.js';\nimport toStr from './tostring.js';\n\n\n// MAIN //\n\n/**\n* Returns a string value indicating a specification defined classification of an object in environments supporting `Symbol.toStringTag`.\n*\n* @param {*} v - input value\n* @returns {string} string value indicating a specification defined classification of the input value\n*\n* @example\n* var str = nativeClass( 'a' );\n* // returns '[object String]'\n*\n* @example\n* var str = nativeClass( 5 );\n* // returns '[object Number]'\n*\n* @example\n* function Beep() {\n* return this;\n* }\n* var str = nativeClass( new Beep() );\n* // returns '[object Object]'\n*/\nfunction nativeClass( v ) {\n\tvar isOwn;\n\tvar tag;\n\tvar out;\n\n\tif ( v === null || v === void 0 ) {\n\t\treturn toStr.call( v );\n\t}\n\ttag = v[ toStringTag ];\n\tisOwn = hasOwnProp( v, toStringTag );\n\n\t// Attempt to override the `toStringTag` property. For built-ins having a `Symbol.toStringTag` property (e.g., `JSON`, `Math`, etc), the `Symbol.toStringTag` property is read-only (e.g., , so we need to wrap in a `try/catch`.\n\ttry {\n\t\tv[ toStringTag ] = void 0;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn toStr.call( v );\n\t}\n\tout = toStr.call( v );\n\n\tif ( isOwn ) {\n\t\tv[ toStringTag ] = tag;\n\t} else {\n\t\tdelete v[ toStringTag ];\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default nativeClass;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport toStr from './tostring.js';\n\n\n// MAIN //\n\n/**\n* Returns a string value indicating a specification defined classification (via the internal property `[[Class]]`) of an object.\n*\n* @param {*} v - input value\n* @returns {string} string value indicating a specification defined classification of the input value\n*\n* @example\n* var str = nativeClass( 'a' );\n* // returns '[object String]'\n*\n* @example\n* var str = nativeClass( 5 );\n* // returns '[object Number]'\n*\n* @example\n* function Beep() {\n* return this;\n* }\n* var str = nativeClass( new Beep() );\n* // returns '[object Object]'\n*/\nfunction nativeClass( v ) {\n\treturn toStr.call( v );\n}\n\n\n// EXPORTS //\n\nexport default nativeClass;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar f;\n\n\n// FUNCTIONS //\n\n/**\n* Tests if a value is an array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an array\n*\n* @example\n* var bool = isArray( [] );\n* // returns true\n*\n* @example\n* var bool = isArray( {} );\n* // returns false\n*/\nfunction isArray( value ) {\n\treturn ( nativeClass( value ) === '[object Array]' );\n}\n\n\n// MAIN //\n\nif ( Array.isArray ) {\n\tf = Array.isArray;\n} else {\n\tf = isArray;\n}\n\n\n// EXPORTS //\n\nexport default f;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar TYPE = 'function';\n\n\n// MAIN //\n\n/**\n* Tests if an array-like object supports the accessor (get/set) protocol.\n*\n* @param {Object} value - value to test\n* @returns {boolean} boolean indicating whether a value is an accessor array\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n*\n* var bool = isAccessorArray( new Complex128Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isAccessorArray( [] );\n* // returns false\n*/\nfunction isAccessorArray( value ) {\n\treturn ( typeof value.get === TYPE && typeof value.set === TYPE ); // eslint-disable-line valid-typeof\n}\n\n\n// EXPORTS //\n\nexport default isAccessorArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar GETTERS = {\n\t'complex128': getComplex128,\n\t'complex64': getComplex64,\n\t'default': getArrayLike\n};\n\n\n// FUNCTIONS //\n\n/**\n* Returns an element from a `Complex128Array`.\n*\n* @private\n* @param {Complex128Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n* import real from '@stdlib/complex-float64-real';\n* import imag from '@stdlib/complex-float64-imag';\n*\n* var arr = new Complex128Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getComplex128( arr, 1 );\n* // returns <Complex128>\n*\n* var re = real( v );\n* // returns 3.0\n*\n* var im = imag( v );\n* // returns 4.0\n*/\nfunction getComplex128( arr, idx ) {\n\treturn arr.get( idx );\n}\n\n/**\n* Returns an element from a `Complex64Array`.\n*\n* @private\n* @param {Complex64Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n* import realf from '@stdlib/complex-float32-real';\n* import imagf from '@stdlib/complex-float32-imag';\n*\n* var arr = new Complex64Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getComplex64( arr, 1 );\n* // returns <Complex64>\n*\n* var re = realf( v );\n* // returns 3.0\n*\n* var im = imagf( v );\n* // returns 4.0\n*/\nfunction getComplex64( arr, idx ) {\n\treturn arr.get( idx );\n}\n\n/**\n* Returns an element from an array-like object supporting the get/set protocol.\n*\n* @private\n* @param {Collection} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {*} element value\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* function get( idx ) {\n* return arr[ idx ];\n* }\n*\n* function set( value, idx ) {\n* arr[ idx ] = value;\n* }\n*\n* arr.get = get;\n* arr.set = set;\n*\n* var v = getArrayLike( arr, 2 );\n* // returns 3\n*/\nfunction getArrayLike( arr, idx ) {\n\treturn arr.get( idx );\n}\n\n\n// MAIN //\n\n/**\n* Returns an accessor function for retrieving an element from an array-like object supporting the get/set protocol.\n*\n* @param {string} dtype - array dtype\n* @returns {Function} accessor\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n* import realf from '@stdlib/complex-float32-real';\n* import imagf from '@stdlib/complex-float32-imag';\n* import dtype from '@stdlib/array-dtype';\n*\n* var arr = new Complex64Array( [ 1, 2, 3, 4 ] );\n*\n* var get = getter( dtype( arr ) );\n* var v = get( arr, 1 );\n* // returns <Complex64>\n*\n* var re = realf( v );\n* // returns 3.0\n*\n* var im = imagf( v );\n* // returns 4.0\n*/\nfunction getter( dtype ) {\n\tvar f = GETTERS[ dtype ];\n\tif ( typeof f === 'function' ) {\n\t\treturn f;\n\t}\n\treturn GETTERS.default;\n}\n\n\n// EXPORTS //\n\nexport default getter;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar GETTERS = {\n\t'float64': getFloat64,\n\t'float32': getFloat32,\n\t'int32': getInt32,\n\t'int16': getInt16,\n\t'int8': getInt8,\n\t'uint32': getUint32,\n\t'uint16': getUint16,\n\t'uint8': getUint8,\n\t'uint8c': getUint8c,\n\t'generic': getGeneric,\n\t'default': getArrayLike\n};\n\n\n// FUNCTIONS //\n\n/**\n* Returns an element from a `Float64Array`.\n*\n* @private\n* @param {Float64Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Float64Array from '@stdlib/array-float64';\n*\n* var arr = new Float64Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getFloat64( arr, 2 );\n* // returns 3.0\n*/\nfunction getFloat64( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Float32Array`.\n*\n* @private\n* @param {Float32Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Float32Array from '@stdlib/array-float32';\n*\n* var arr = new Float32Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getFloat32( arr, 2 );\n* // returns 3.0\n*/\nfunction getFloat32( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an `Int32Array`.\n*\n* @private\n* @param {Int32Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Int32Array from '@stdlib/array-int32';\n*\n* var arr = new Int32Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getInt32( arr, 2 );\n* // returns 3\n*/\nfunction getInt32( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an `Int16Array`.\n*\n* @private\n* @param {Int16Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Int16Array from '@stdlib/array-int16';\n*\n* var arr = new Int16Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getInt16( arr, 2 );\n* // returns 3\n*/\nfunction getInt16( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an `Int8Array`.\n*\n* @private\n* @param {Int8Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Int8Array from '@stdlib/array-int8';\n*\n* var arr = new Int8Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getInt8( arr, 2 );\n* // returns 3\n*/\nfunction getInt8( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint32Array`.\n*\n* @private\n* @param {Uint32Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint32Array from '@stdlib/array-uint32';\n*\n* var arr = new Uint32Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint32( arr, 2 );\n* // returns 3\n*/\nfunction getUint32( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint16Array`.\n*\n* @private\n* @param {Uint16Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint16Array from '@stdlib/array-uint16';\n*\n* var arr = new Uint16Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint16( arr, 2 );\n* // returns 3\n*/\nfunction getUint16( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint8Array`.\n*\n* @private\n* @param {Uint8Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint8Array from '@stdlib/array-uint8';\n*\n* var arr = new Uint8Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint8( arr, 2 );\n* // returns 3\n*/\nfunction getUint8( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint8ClampedArray`.\n*\n* @private\n* @param {Uint8ClampedArray} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint8ClampedArray from '@stdlib/array-uint8c';\n*\n* var arr = new Uint8ClampedArray( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint8c( arr, 2 );\n* // returns 3\n*/\nfunction getUint8c( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a generic `Array`.\n*\n* @private\n* @param {Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {*} element value\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var v = getGeneric( arr, 2 );\n* // returns 3\n*/\nfunction getGeneric( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an indexed array-like object.\n*\n* @private\n* @param {Collection} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {*} element value\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var v = getArrayLike( arr, 2 );\n* // returns 3\n*/\nfunction getArrayLike( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n\n// MAIN //\n\n/**\n* Returns an accessor function for retrieving an element from an indexed array-like object.\n*\n* @param {string} dtype - array dtype\n* @returns {Function} accessor\n*\n* @example\n* import dtype from '@stdlib/array-dtype';\n*\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var get = getter( dtype( arr ) );\n* var v = get( arr, 2 );\n* // returns 3\n*/\nfunction getter( dtype ) {\n\tvar f = GETTERS[ dtype ];\n\tif ( typeof f === 'function' ) {\n\t\treturn f;\n\t}\n\treturn GETTERS.default;\n}\n\n\n// EXPORTS //\n\nexport default getter;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Object.defineProperty === 'function' ) ? Object.defineProperty : null;\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Defines (or modifies) an object property.\n*\n* ## Notes\n*\n* - Property descriptors come in two flavors: **data descriptors** and **accessor descriptors**. A data descriptor is a property that has a value, which may or may not be writable. An accessor descriptor is a property described by a getter-setter function pair. A descriptor must be one of these two flavors and cannot be both.\n*\n* @name defineProperty\n* @type {Function}\n* @param {Object} obj - object on which to define the property\n* @param {(string|symbol)} prop - property name\n* @param {Object} descriptor - property descriptor\n* @param {boolean} [descriptor.configurable=false] - boolean indicating if property descriptor can be changed and if the property can be deleted from the provided object\n* @param {boolean} [descriptor.enumerable=false] - boolean indicating if the property shows up when enumerating object properties\n* @param {boolean} [descriptor.writable=false] - boolean indicating if the value associated with the property can be changed with an assignment operator\n* @param {*} [descriptor.value] - property value\n* @param {(Function|void)} [descriptor.get=undefined] - function which serves as a getter for the property, or, if no getter, undefined. When the property is accessed, a getter function is called without arguments and with the `this` context set to the object through which the property is accessed (which may not be the object on which the property is defined due to inheritance). The return value will be used as the property value.\n* @param {(Function|void)} [descriptor.set=undefined] - function which serves as a setter for the property, or, if no setter, undefined. When assigning a property value, a setter function is called with one argument (the value being assigned to the property) and with the `this` context set to the object through which the property is assigned.\n* @throws {TypeError} first argument must be an object\n* @throws {TypeError} third argument must be an object\n* @throws {Error} property descriptor cannot have both a value and a setter and/or getter\n* @returns {Object} object with added property\n*\n* @example\n* var obj = {};\n*\n* defineProperty( obj, 'foo', {\n* 'value': 'bar'\n* });\n*\n* var str = obj.foo;\n* // returns 'bar'\n*/\nvar defineProperty = Object.defineProperty;\n\n\n// EXPORTS //\n\nexport default defineProperty;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a number primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* @example\n* var bool = isNumber( NaN );\n* // returns true\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns false\n*/\nfunction isNumber( value ) {\n\treturn ( typeof value === 'number' ); // NOTE: we inline the `isNumber.isPrimitive` function from `@stdlib/assert/is-number` in order to avoid circular dependencies.\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// FUNCTIONS //\n\n/**\n* Tests if a string starts with a minus sign (`-`).\n*\n* @private\n* @param {string} str - input string\n* @returns {boolean} boolean indicating if a string starts with a minus sign (`-`)\n*/\nfunction startsWithMinus( str ) {\n\treturn str[ 0 ] === '-';\n}\n\n/**\n* Returns a string of `n` zeros.\n*\n* @private\n* @param {number} n - number of zeros\n* @returns {string} string of zeros\n*/\nfunction zeros( n ) {\n\tvar out = '';\n\tvar i;\n\tfor ( i = 0; i < n; i++ ) {\n\t\tout += '0';\n\t}\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Pads a token with zeros to the specified width.\n*\n* @private\n* @param {string} str - token argument\n* @param {number} width - token width\n* @param {boolean} [right=false] - boolean indicating whether to pad to the right\n* @returns {string} padded token argument\n*/\nfunction zeroPad( str, width, right ) {\n\tvar negative = false;\n\tvar pad = width - str.length;\n\tif ( pad < 0 ) {\n\t\treturn str;\n\t}\n\tif ( startsWithMinus( str ) ) {\n\t\tnegative = true;\n\t\tstr = str.substr( 1 );\n\t}\n\tstr = ( right ) ?\n\t\tstr + zeros( pad ) :\n\t\tzeros( pad ) + str;\n\tif ( negative ) {\n\t\tstr = '-' + str;\n\t}\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default zeroPad;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isNumber from './is_number.js';\nimport zeroPad from './zero_pad.js';\n\n// NOTE: for the following, we explicitly avoid using stdlib packages in this particular package in order to avoid circular dependencies.\nvar lowercase = String.prototype.toLowerCase;\nvar uppercase = String.prototype.toUpperCase;\n\n\n// MAIN //\n\n/**\n* Formats a token object argument as an integer.\n*\n* @private\n* @param {Object} token - token object\n* @throws {Error} must provide a valid integer\n* @returns {string} formatted token argument\n*/\nfunction formatInteger( token ) {\n\tvar base;\n\tvar out;\n\tvar i;\n\n\tswitch ( token.specifier ) {\n\tcase 'b':\n\t\t// Case: %b (binary)\n\t\tbase = 2;\n\t\tbreak;\n\tcase 'o':\n\t\t// Case: %o (octal)\n\t\tbase = 8;\n\t\tbreak;\n\tcase 'x':\n\tcase 'X':\n\t\t// Case: %x, %X (hexadecimal)\n\t\tbase = 16;\n\t\tbreak;\n\tcase 'd':\n\tcase 'i':\n\tcase 'u':\n\tdefault:\n\t\t// Case: %d, %i, %u (decimal)\n\t\tbase = 10;\n\t\tbreak;\n\t}\n\tout = token.arg;\n\ti = parseInt( out, 10 );\n\tif ( !isFinite( i ) ) { // NOTE: We use the global `isFinite` function here instead of `@stdlib/math/base/assert/is-finite` in order to avoid circular dependencies.\n\t\tif ( !isNumber( out ) ) {\n\t\t\tthrow new Error( 'invalid integer. Value: ' + out );\n\t\t}\n\t\ti = 0;\n\t}\n\tif ( i < 0 && ( token.specifier === 'u' || base !== 10 ) ) {\n\t\ti = 0xffffffff + i + 1;\n\t}\n\tif ( i < 0 ) {\n\t\tout = ( -i ).toString( base );\n\t\tif ( token.precision ) {\n\t\t\tout = zeroPad( out, token.precision, token.padRight );\n\t\t}\n\t\tout = '-' + out;\n\t} else {\n\t\tout = i.toString( base );\n\t\tif ( !i && !token.precision ) {\n\t\t\tout = '';\n\t\t} else if ( token.precision ) {\n\t\t\tout = zeroPad( out, token.precision, token.padRight );\n\t\t}\n\t\tif ( token.sign ) {\n\t\t\tout = token.sign + out;\n\t\t}\n\t}\n\tif ( base === 16 ) {\n\t\tif ( token.alternate ) {\n\t\t\tout = '0x' + out;\n\t\t}\n\t\tout = ( token.specifier === uppercase.call( token.specifier ) ) ?\n\t\t\tuppercase.call( out ) :\n\t\t\tlowercase.call( out );\n\t}\n\tif ( base === 8 ) {\n\t\tif ( token.alternate && out.charAt( 0 ) !== '0' ) {\n\t\t\tout = '0' + out;\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default formatInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isNumber from './is_number.js';\n\n// NOTE: for the following, we explicitly avoid using stdlib packages in this particular package in order to avoid circular dependencies.\nvar abs = Math.abs; // eslint-disable-line stdlib/no-builtin-math\nvar lowercase = String.prototype.toLowerCase;\nvar uppercase = String.prototype.toUpperCase;\nvar replace = String.prototype.replace;\n\n\n// VARIABLES //\n\nvar RE_EXP_POS_DIGITS = /e\\+(\\d)$/;\nvar RE_EXP_NEG_DIGITS = /e-(\\d)$/;\nvar RE_ONLY_DIGITS = /^(\\d+)$/;\nvar RE_DIGITS_BEFORE_EXP = /^(\\d+)e/;\nvar RE_TRAILING_PERIOD_ZERO = /\\.0$/;\nvar RE_PERIOD_ZERO_EXP = /\\.0*e/;\nvar RE_ZERO_BEFORE_EXP = /(\\..*[^0])0*e/;\n\n\n// MAIN //\n\n/**\n* Formats a token object argument as a floating-point number.\n*\n* @private\n* @param {Object} token - token object\n* @throws {Error} must provide a valid floating-point number\n* @returns {string} formatted token argument\n*/\nfunction formatDouble( token ) {\n\tvar digits;\n\tvar out;\n\tvar f = parseFloat( token.arg );\n\tif ( !isFinite( f ) ) { // NOTE: We use the global `isFinite` function here instead of `@stdlib/math/base/assert/is-finite` in order to avoid circular dependencies.\n\t\tif ( !isNumber( token.arg ) ) {\n\t\t\tthrow new Error( 'invalid floating-point number. Value: ' + out );\n\t\t}\n\t\t// Case: NaN, Infinity, or -Infinity\n\t\tf = token.arg;\n\t}\n\tswitch ( token.specifier ) {\n\tcase 'e':\n\tcase 'E':\n\t\tout = f.toExponential( token.precision );\n\t\tbreak;\n\tcase 'f':\n\tcase 'F':\n\t\tout = f.toFixed( token.precision );\n\t\tbreak;\n\tcase 'g':\n\tcase 'G':\n\t\tif ( abs( f ) < 0.0001 ) {\n\t\t\tdigits = token.precision;\n\t\t\tif ( digits > 0 ) {\n\t\t\t\tdigits -= 1;\n\t\t\t}\n\t\t\tout = f.toExponential( digits );\n\t\t} else {\n\t\t\tout = f.toPrecision( token.precision );\n\t\t}\n\t\tif ( !token.alternate ) {\n\t\t\tout = replace.call( out, RE_ZERO_BEFORE_EXP, '$1e' );\n\t\t\tout = replace.call( out, RE_PERIOD_ZERO_EXP, 'e' );\n\t\t\tout = replace.call( out, RE_TRAILING_PERIOD_ZERO, '' );\n\t\t}\n\t\tbreak;\n\tdefault:\n\t\tthrow new Error( 'invalid double notation. Value: ' + token.specifier );\n\t}\n\tout = replace.call( out, RE_EXP_POS_DIGITS, 'e+0$1' );\n\tout = replace.call( out, RE_EXP_NEG_DIGITS, 'e-0$1' );\n\tif ( token.alternate ) {\n\t\tout = replace.call( out, RE_ONLY_DIGITS, '$1.' );\n\t\tout = replace.call( out, RE_DIGITS_BEFORE_EXP, '$1.e' );\n\t}\n\tif ( f >= 0 && token.sign ) {\n\t\tout = token.sign + out;\n\t}\n\tout = ( token.specifier === uppercase.call( token.specifier ) ) ?\n\t\tuppercase.call( out ) :\n\t\tlowercase.call( out );\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default formatDouble;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// FUNCTIONS //\n\n/**\n* Returns `n` spaces.\n*\n* @private\n* @param {number} n - number of spaces\n* @returns {string} string of spaces\n*/\nfunction spaces( n ) {\n\tvar out = '';\n\tvar i;\n\tfor ( i = 0; i < n; i++ ) {\n\t\tout += ' ';\n\t}\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Pads a token with spaces to the specified width.\n*\n* @private\n* @param {string} str - token argument\n* @param {number} width - token width\n* @param {boolean} [right=false] - boolean indicating whether to pad to the right\n* @returns {string} padded token argument\n*/\nfunction spacePad( str, width, right ) {\n\tvar pad = width - str.length;\n\tif ( pad < 0 ) {\n\t\treturn str;\n\t}\n\tstr = ( right ) ?\n\t\tstr + spaces( pad ) :\n\t\tspaces( pad ) + str;\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default spacePad;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport formatInteger from './format_integer.js';\nimport isString from './is_string.js';\nimport formatDouble from './format_double.js';\nimport spacePad from './space_pad.js';\nimport zeroPad from './zero_pad.js';\n\n\n// VARIABLES //\n\nvar fromCharCode = String.fromCharCode;\nvar isArray = Array.isArray; // NOTE: We use the global `Array.isArray` function here instead of `@stdlib/assert/is-array` to avoid circular dependencies.\n\n\n// FUNCTIONS //\n\n/**\n* Returns a boolean indicating whether a value is `NaN`.\n*\n* @private\n* @param {*} value - input value\n* @returns {boolean} boolean indicating whether a value is `NaN`\n*\n* @example\n* var bool = isnan( NaN );\n* // returns true\n*\n* @example\n* var bool = isnan( 4 );\n* // returns false\n*/\nfunction isnan( value ) { // explicitly define a function here instead of `@stdlib/math/base/assert/is-nan` in order to avoid circular dependencies\n\treturn ( value !== value );\n}\n\n/**\n* Initializes token object with properties of supplied format identifier object or default values if not present.\n*\n* @private\n* @param {Object} token - format identifier object\n* @returns {Object} token object\n*/\nfunction initialize( token ) {\n\tvar out = {};\n\tout.specifier = token.specifier;\n\tout.precision = ( token.precision === void 0 ) ? 1 : token.precision;\n\tout.width = token.width;\n\tout.flags = token.flags || '';\n\tout.mapping = token.mapping;\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Generates string from a token array by interpolating values.\n*\n* @param {Array} tokens - string parts and format identifier objects\n* @param {Array} ...args - variable values\n* @throws {TypeError} first argument must be an array\n* @throws {Error} invalid flags\n* @returns {string} formatted string\n*\n* @example\n* var tokens = [ 'beep ', { 'specifier': 's' } ];\n* var out = formatInterpolate( tokens, 'boop' );\n* // returns 'beep boop'\n*/\nfunction formatInterpolate( tokens ) {\n\tvar hasPeriod;\n\tvar flags;\n\tvar token;\n\tvar flag;\n\tvar num;\n\tvar out;\n\tvar pos;\n\tvar i;\n\tvar j;\n\n\tif ( !isArray( tokens ) ) {\n\t\tthrow new TypeError( 'invalid argument. First argument must be an array. Value: `' + tokens + '`.' );\n\t}\n\tout = '';\n\tpos = 1;\n\tfor ( i = 0; i < tokens.length; i++ ) {\n\t\ttoken = tokens[ i ];\n\t\tif ( isString( token ) ) {\n\t\t\tout += token;\n\t\t} else {\n\t\t\thasPeriod = token.precision !== void 0;\n\t\t\ttoken = initialize( token );\n\t\t\tif ( !token.specifier ) {\n\t\t\t\tthrow new TypeError( 'invalid argument. Token is missing `specifier` property. Index: `'+ i +'`. Value: `' + token + '`.' );\n\t\t\t}\n\t\t\tif ( token.mapping ) {\n\t\t\t\tpos = token.mapping;\n\t\t\t}\n\t\t\tflags = token.flags;\n\t\t\tfor ( j = 0; j < flags.length; j++ ) {\n\t\t\t\tflag = flags.charAt( j );\n\t\t\t\tswitch ( flag ) {\n\t\t\t\tcase ' ':\n\t\t\t\t\ttoken.sign = ' ';\n\t\t\t\t\tbreak;\n\t\t\t\tcase '+':\n\t\t\t\t\ttoken.sign = '+';\n\t\t\t\t\tbreak;\n\t\t\t\tcase '-':\n\t\t\t\t\ttoken.padRight = true;\n\t\t\t\t\ttoken.padZeros = false;\n\t\t\t\t\tbreak;\n\t\t\t\tcase '0':\n\t\t\t\t\ttoken.padZeros = flags.indexOf( '-' ) < 0; // NOTE: We use built-in `Array.prototype.indexOf` here instead of `@stdlib/assert/contains` in order to avoid circular dependencies.\n\t\t\t\t\tbreak;\n\t\t\t\tcase '#':\n\t\t\t\t\ttoken.alternate = true;\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new Error( 'invalid flag: ' + flag );\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( token.width === '*' ) {\n\t\t\t\ttoken.width = parseInt( arguments[ pos ], 10 );\n\t\t\t\tpos += 1;\n\t\t\t\tif ( isnan( token.width ) ) {\n\t\t\t\t\tthrow new TypeError( 'the argument for * width at position ' + pos + ' is not a number. Value: `' + token.width + '`.' );\n\t\t\t\t}\n\t\t\t\tif ( token.width < 0 ) {\n\t\t\t\t\ttoken.padRight = true;\n\t\t\t\t\ttoken.width = -token.width;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( hasPeriod ) {\n\t\t\t\tif ( token.precision === '*' ) {\n\t\t\t\t\ttoken.precision = parseInt( arguments[ pos ], 10 );\n\t\t\t\t\tpos += 1;\n\t\t\t\t\tif ( isnan( token.precision ) ) {\n\t\t\t\t\t\tthrow new TypeError( 'the argument for * precision at position ' + pos + ' is not a number. Value: `' + token.precision + '`.' );\n\t\t\t\t\t}\n\t\t\t\t\tif ( token.precision < 0 ) {\n\t\t\t\t\t\ttoken.precision = 1;\n\t\t\t\t\t\thasPeriod = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\ttoken.arg = arguments[ pos ];\n\t\t\tswitch ( token.specifier ) {\n\t\t\tcase 'b':\n\t\t\tcase 'o':\n\t\t\tcase 'x':\n\t\t\tcase 'X':\n\t\t\tcase 'd':\n\t\t\tcase 'i':\n\t\t\tcase 'u':\n\t\t\t\t// Case: %b (binary), %o (octal), %x, %X (hexadecimal), %d, %i (decimal), %u (unsigned decimal)\n\t\t\t\tif ( hasPeriod ) {\n\t\t\t\t\ttoken.padZeros = false;\n\t\t\t\t}\n\t\t\t\ttoken.arg = formatInteger( token );\n\t\t\t\tbreak;\n\t\t\tcase 's':\n\t\t\t\t// Case: %s (string)\n\t\t\t\ttoken.maxWidth = ( hasPeriod ) ? token.precision : -1;\n\t\t\t\ttoken.arg = String( token.arg );\n\t\t\t\tbreak;\n\t\t\tcase 'c':\n\t\t\t\t// Case: %c (character)\n\t\t\t\tif ( !isnan( token.arg ) ) {\n\t\t\t\t\tnum = parseInt( token.arg, 10 );\n\t\t\t\t\tif ( num < 0 || num > 127 ) {\n\t\t\t\t\t\tthrow new Error( 'invalid character code. Value: ' + token.arg );\n\t\t\t\t\t}\n\t\t\t\t\ttoken.arg = ( isnan( num ) ) ? String( token.arg ) : fromCharCode( num ); // eslint-disable-line max-len\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'e':\n\t\t\tcase 'E':\n\t\t\tcase 'f':\n\t\t\tcase 'F':\n\t\t\tcase 'g':\n\t\t\tcase 'G':\n\t\t\t\t// Case: %e, %E (scientific notation), %f, %F (decimal floating point), %g, %G (uses the shorter of %e/E or %f/F)\n\t\t\t\tif ( !hasPeriod ) {\n\t\t\t\t\ttoken.precision = 6;\n\t\t\t\t}\n\t\t\t\ttoken.arg = formatDouble( token );\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tthrow new Error( 'invalid specifier: ' + token.specifier );\n\t\t\t}\n\t\t\t// Fit argument into field width...\n\t\t\tif ( token.maxWidth >= 0 && token.arg.length > token.maxWidth ) {\n\t\t\t\ttoken.arg = token.arg.substring( 0, token.maxWidth );\n\t\t\t}\n\t\t\tif ( token.padZeros ) {\n\t\t\t\ttoken.arg = zeroPad( token.arg, token.width || token.precision, token.padRight ); // eslint-disable-line max-len\n\t\t\t} else if ( token.width ) {\n\t\t\t\ttoken.arg = spacePad( token.arg, token.width, token.padRight );\n\t\t\t}\n\t\t\tout += token.arg || '';\n\t\t\tpos += 1;\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default formatInterpolate;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a string primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string primitive\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns false\n*/\nfunction isString( value ) {\n\treturn ( typeof value === 'string' ); // NOTE: we inline the `isString.isPrimitive` function from `@stdlib/assert/is-string` in order to avoid circular dependencies.\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar RE = /%(?:([1-9]\\d*)\\$)?([0 +\\-#]*)(\\*|\\d+)?(?:(\\.)(\\*|\\d+)?)?[hlL]?([%A-Za-z])/g;\n\n\n// FUNCTIONS //\n\n/**\n* Parses a delimiter.\n*\n* @private\n* @param {Array} match - regular expression match\n* @returns {Object} delimiter token object\n*/\nfunction parse( match ) {\n\tvar token = {\n\t\t'mapping': ( match[ 1 ] ) ? parseInt( match[ 1 ], 10 ) : void 0,\n\t\t'flags': match[ 2 ],\n\t\t'width': match[ 3 ],\n\t\t'precision': match[ 5 ],\n\t\t'specifier': match[ 6 ]\n\t};\n\tif ( match[ 4 ] === '.' && match[ 5 ] === void 0 ) {\n\t\ttoken.precision = '1';\n\t}\n\treturn token;\n}\n\n\n// MAIN //\n\n/**\n* Tokenizes a string into an array of string parts and format identifier objects.\n*\n* @param {string} str - input string\n* @returns {Array} tokens\n*\n* @example\n* var tokens = formatTokenize( 'Hello %s!' );\n* // returns [ 'Hello ', {...}, '!' ]\n*/\nfunction formatTokenize( str ) {\n\tvar content;\n\tvar tokens;\n\tvar match;\n\tvar prev;\n\n\ttokens = [];\n\tprev = 0;\n\tmatch = RE.exec( str );\n\twhile ( match ) {\n\t\tcontent = str.slice( prev, RE.lastIndex - match[ 0 ].length );\n\t\tif ( content.length ) {\n\t\t\ttokens.push( content );\n\t\t}\n\t\ttokens.push( parse( match ) );\n\t\tprev = RE.lastIndex;\n\t\tmatch = RE.exec( str );\n\t}\n\tcontent = str.slice( prev );\n\tif ( content.length ) {\n\t\ttokens.push( content );\n\t}\n\treturn tokens;\n}\n\n\n// EXPORTS //\n\nexport default formatTokenize;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport interpolate from '@stdlib/string-base-format-interpolate';\nimport tokenize from '@stdlib/string-base-format-tokenize';\nimport isString from './is_string.js';\n\n\n// MAIN //\n\n/**\n* Inserts supplied variable values into a format string.\n*\n* @param {string} str - input string\n* @param {Array} ...args - variable values\n* @throws {TypeError} first argument must be a string\n* @throws {Error} invalid flags\n* @returns {string} formatted string\n*\n* @example\n* var str = format( 'Hello %s!', 'world' );\n* // returns 'Hello world!'\n*\n* @example\n* var str = format( 'Pi: ~%.2f', 3.141592653589793 );\n* // returns 'Pi: ~3.14'\n*/\nfunction format( str ) {\n\tvar args;\n\tvar i;\n\n\tif ( !isString( str ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a string. Value: `%s`.', str ) );\n\t}\n\targs = [ tokenize( str ) ];\n\tfor ( i = 1; i < arguments.length; i++ ) {\n\t\targs.push( arguments[ i ] );\n\t}\n\treturn interpolate.apply( null, args );\n}\n\n\n// EXPORTS //\n\nexport default format;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a string primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string primitive\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns false\n*/\nfunction isString( value ) {\n\treturn ( typeof value === 'string' ); // NOTE: we inline the `isString.isPrimitive` function from `@stdlib/assert/is-string` in order to avoid circular dependencies.\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n/* eslint-disable no-underscore-dangle, no-proto */\n\n'use strict';\n\n// MODULES //\n\nimport format from '@stdlib/string-format';\n\n\n// VARIABLES //\n\nvar objectProtoype = Object.prototype;\nvar toStr = objectProtoype.toString;\nvar defineGetter = objectProtoype.__defineGetter__;\nvar defineSetter = objectProtoype.__defineSetter__;\nvar lookupGetter = objectProtoype.__lookupGetter__;\nvar lookupSetter = objectProtoype.__lookupSetter__;\n\n\n// MAIN //\n\n/**\n* Defines (or modifies) an object property.\n*\n* ## Notes\n*\n* - Property descriptors come in two flavors: **data descriptors** and **accessor descriptors**. A data descriptor is a property that has a value, which may or may not be writable. An accessor descriptor is a property described by a getter-setter function pair. A descriptor must be one of these two flavors and cannot be both.\n*\n* @param {Object} obj - object on which to define the property\n* @param {string} prop - property name\n* @param {Object} descriptor - property descriptor\n* @param {boolean} [descriptor.configurable=false] - boolean indicating if property descriptor can be changed and if the property can be deleted from the provided object\n* @param {boolean} [descriptor.enumerable=false] - boolean indicating if the property shows up when enumerating object properties\n* @param {boolean} [descriptor.writable=false] - boolean indicating if the value associated with the property can be changed with an assignment operator\n* @param {*} [descriptor.value] - property value\n* @param {(Function|void)} [descriptor.get=undefined] - function which serves as a getter for the property, or, if no getter, undefined. When the property is accessed, a getter function is called without arguments and with the `this` context set to the object through which the property is accessed (which may not be the object on which the property is defined due to inheritance). The return value will be used as the property value.\n* @param {(Function|void)} [descriptor.set=undefined] - function which serves as a setter for the property, or, if no setter, undefined. When assigning a property value, a setter function is called with one argument (the value being assigned to the property) and with the `this` context set to the object through which the property is assigned.\n* @throws {TypeError} first argument must be an object\n* @throws {TypeError} third argument must be an object\n* @throws {Error} property descriptor cannot have both a value and a setter and/or getter\n* @returns {Object} object with added property\n*\n* @example\n* var obj = {};\n*\n* defineProperty( obj, 'foo', {\n* 'value': 'bar'\n* });\n*\n* var str = obj.foo;\n* // returns 'bar'\n*/\nfunction defineProperty( obj, prop, descriptor ) {\n\tvar prototype;\n\tvar hasValue;\n\tvar hasGet;\n\tvar hasSet;\n\n\tif ( typeof obj !== 'object' || obj === null || toStr.call( obj ) === '[object Array]' ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be an object. Value: `%s`.', obj ) );\n\t}\n\tif ( typeof descriptor !== 'object' || descriptor === null || toStr.call( descriptor ) === '[object Array]' ) {\n\t\tthrow new TypeError( format( 'invalid argument. Property descriptor must be an object. Value: `%s`.', descriptor ) );\n\t}\n\thasValue = ( 'value' in descriptor );\n\tif ( hasValue ) {\n\t\tif (\n\t\t\tlookupGetter.call( obj, prop ) ||\n\t\t\tlookupSetter.call( obj, prop )\n\t\t) {\n\t\t\t// Override `__proto__` to avoid touching inherited accessors:\n\t\t\tprototype = obj.__proto__;\n\t\t\tobj.__proto__ = objectProtoype;\n\n\t\t\t// Delete property as existing getters/setters prevent assigning value to specified property:\n\t\t\tdelete obj[ prop ];\n\t\t\tobj[ prop ] = descriptor.value;\n\n\t\t\t// Restore original prototype:\n\t\t\tobj.__proto__ = prototype;\n\t\t} else {\n\t\t\tobj[ prop ] = descriptor.value;\n\t\t}\n\t}\n\thasGet = ( 'get' in descriptor );\n\thasSet = ( 'set' in descriptor );\n\n\tif ( hasValue && ( hasGet || hasSet ) ) {\n\t\tthrow new Error( 'invalid argument. Cannot specify one or more accessors and a value or writable attribute in the property descriptor.' );\n\t}\n\n\tif ( hasGet && defineGetter ) {\n\t\tdefineGetter.call( obj, prop, descriptor.get );\n\t}\n\tif ( hasSet && defineSetter ) {\n\t\tdefineSetter.call( obj, prop, descriptor.set );\n\t}\n\treturn obj;\n}\n\n\n// EXPORTS //\n\nexport default defineProperty;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Define (or modify) an object property.\n*\n* @module @stdlib/utils-define-property\n*\n* @example\n* import defineProperty from '@stdlib/utils-define-property';\n*\n* var obj = {};\n* defineProperty( obj, 'foo', {\n* 'value': 'bar',\n* 'writable': false,\n* 'configurable': false,\n* 'enumerable': false\n* });\n* obj.foo = 'boop'; // => throws\n*/\n\n// MODULES //\n\nimport hasDefinePropertySupport from './has_define_property_support.js';\nimport builtin from './builtin.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar defineProperty;\nif ( hasDefinePropertySupport() ) {\n\tdefineProperty = builtin;\n} else {\n\tdefineProperty = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default defineProperty;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport defineProperty from './define_property.js';\n\n\n// MAIN //\n\n/**\n* Tests for `Object.defineProperty` support.\n*\n* @private\n* @returns {boolean} boolean indicating if an environment has `Object.defineProperty` support\n*\n* @example\n* var bool = hasDefinePropertySupport();\n* // returns <boolean>\n*/\nfunction hasDefinePropertySupport() {\n\t// Test basic support...\n\ttry {\n\t\tdefineProperty( {}, 'x', {} );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default hasDefinePropertySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport defineProperty from '@stdlib/utils-define-property';\n\n\n// MAIN //\n\n/**\n* Defines a non-enumerable read-only property.\n*\n* @param {Object} obj - object on which to define the property\n* @param {(string|symbol)} prop - property name\n* @param {*} value - value to set\n*\n* @example\n* var obj = {};\n*\n* setNonEnumerableReadOnly( obj, 'foo', 'bar' );\n*\n* try {\n* obj.foo = 'boop';\n* } catch ( err ) {\n* console.error( err.message );\n* }\n*/\nfunction setNonEnumerableReadOnly( obj, prop, value ) {\n\tdefineProperty( obj, prop, {\n\t\t'configurable': false,\n\t\t'enumerable': false,\n\t\t'writable': false,\n\t\t'value': value\n\t});\n}\n\n\n// EXPORTS //\n\nexport default setNonEnumerableReadOnly;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is object-like.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether a value is object-like\n*\n* @example\n* var bool = isObjectLike( {} );\n* // returns true\n*\n* @example\n* var bool = isObjectLike( [] );\n* // returns true\n*\n* @example\n* var bool = isObjectLike( null );\n* // returns false\n*/\nfunction isObjectLike( value ) {\n\treturn (\n\t\tvalue !== null &&\n\t\ttypeof value === 'object'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isObjectLike;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isObjectLike from '@stdlib/assert-is-object-like';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Buffer instance.\n*\n* @param {*} value - value to validate\n* @returns {boolean} boolean indicating if a value is a Buffer instance\n*\n* @example\n* var v = isBuffer( new Buffer( 'beep' ) );\n* // returns true\n*\n* @example\n* var v = isBuffer( new Buffer( [1,2,3,4] ) );\n* // returns true\n*\n* @example\n* var v = isBuffer( {} );\n* // returns false\n*\n* @example\n* var v = isBuffer( [] );\n* // returns false\n*/\nfunction isBuffer( value ) {\n\treturn (\n\t\tisObjectLike( value ) &&\n\t\t(\n\t\t\t// eslint-disable-next-line no-underscore-dangle\n\t\t\tvalue._isBuffer || // for envs missing Object.prototype.constructor (e.g., Safari 5-7)\n\t\t\t(\n\t\t\t\tvalue.constructor &&\n\n\t\t\t\t// WARNING: `typeof` is not a foolproof check, as certain envs consider RegExp and NodeList instances to be functions\n\t\t\t\ttypeof value.constructor.isBuffer === 'function' &&\n\t\t\t\tvalue.constructor.isBuffer( value )\n\t\t\t)\n\t\t)\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isBuffer;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Returns a regular expression to capture everything that is not a space immediately after the `function` keyword and before the first left parenthesis.\n*\n* @returns {RegExp} regular expression\n*\n* @example\n* var RE_FUNCTION_NAME = reFunctionName();\n*\n* function fname( fcn ) {\n* return RE_FUNCTION_NAME.exec( fcn.toString() )[ 1 ];\n* }\n*\n* var fn = fname( Math.sqrt );\n* // returns 'sqrt'\n*\n* fn = fname( Int8Array );\n* // returns 'Int8Array'\n*\n* fn = fname( Object.prototype.toString );\n* // returns 'toString'\n*\n* fn = fname( function(){} );\n* // returns ''\n*/\nfunction reFunctionName() {\n\treturn /^\\s*function\\s*([^(]*)/i;\n}\n\n\n// EXPORTS //\n\nexport default reFunctionName;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is object-like.\n*\n* @module @stdlib/assert-is-object-like\n*\n* @example\n* import isObjectLike from '@stdlib/assert-is-object-like';\n*\n* var bool = isObjectLike( {} );\n* // returns true\n*\n* bool = isObjectLike( [] );\n* // returns true\n*\n* bool = isObjectLike( null );\n* // returns false\n*\n* @example\n* import { isObjectLikeArray as isObjectLike } from '@stdlib/assert-is-object-like';\n*\n* var bool = isObjectLike( [ {}, [] ] );\n* // returns true\n*\n* bool = isObjectLike( [ {}, '3.0' ] );\n* // returns false\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport arrayfun from '@stdlib/assert-tools-array-function';\nimport main from './main.js';\n\n\n// VARIABLES //\n\nvar isObjectLikeArray = arrayfun( main );\n\n\n// MAIN //\n\nsetReadOnly( main, 'isObjectLikeArray', isObjectLikeArray );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArray from '@stdlib/assert-is-array';\nimport format from '@stdlib/string-format';\n\n\n// MAIN //\n\n/**\n* Returns a function which tests if every element in an array passes a test condition.\n*\n* @param {Function} predicate - function to apply\n* @throws {TypeError} must provide a function\n* @returns {Function} an array function\n*\n* @example\n* import isOdd from '@stdlib/assert-is-odd';\n*\n* var arr1 = [ 1, 3, 5, 7 ];\n* var arr2 = [ 3, 5, 8 ];\n*\n* var validate = arrayfcn( isOdd );\n*\n* var bool = validate( arr1 );\n* // returns true\n*\n* bool = validate( arr2 );\n* // returns false\n*/\nfunction arrayfcn( predicate ) {\n\tif ( typeof predicate !== 'function' ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide a function. Value: `%s`.', predicate ) );\n\t}\n\treturn every;\n\n\t/**\n\t* Tests if every element in an array passes a test condition.\n\t*\n\t* @private\n\t* @param {*} value - value to test\n\t* @returns {boolean} boolean indicating whether a value is an array for which all elements pass a test condition\n\t*/\n\tfunction every( value ) {\n\t\tvar len;\n\t\tvar i;\n\t\tif ( !isArray( value ) ) {\n\t\t\treturn false;\n\t\t}\n\t\tlen = value.length;\n\t\tif ( len === 0 ) {\n\t\t\treturn false;\n\t\t}\n\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\tif ( predicate( value[ i ] ) === false ) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default arrayfcn;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport reFunctionName from './main.js';\n\n\n// MAIN //\n\n/**\n* Captures everything that is not a space immediately after the `function` keyword and before the first left parenthesis.\n*\n* Regular expression: `/^\\s*function\\s*([^(]*)/i`\n*\n* - `/^\\s*`\n* - Match zero or more spaces at beginning\n*\n* - `function`\n* - Match the word `function`\n*\n* - `\\s*`\n* - Match zero or more spaces after the word `function`\n*\n* - `()`\n* - Capture\n*\n* - `[^(]*`\n* - Match anything except a left parenthesis `(` zero or more times\n*\n* - `/i`\n* - ignore case\n*\n* @constant\n* @type {RegExp}\n* @default /^\\s*function\\s*([^(]*)/i\n*/\nvar RE_FUNCTION_NAME = reFunctionName();\n\n\n// EXPORTS //\n\nexport default RE_FUNCTION_NAME;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\nimport { REGEXP as RE } from '@stdlib/regexp-function-name';\nimport isBuffer from '@stdlib/assert-is-buffer';\n\n\n// MAIN //\n\n/**\n* Determines the name of a value's constructor.\n*\n* @param {*} v - input value\n* @returns {string} name of a value's constructor\n*\n* @example\n* var v = constructorName( 'a' );\n* // returns 'String'\n*\n* @example\n* var v = constructorName( 5 );\n* // returns 'Number'\n*\n* @example\n* var v = constructorName( null );\n* // returns 'Null'\n*\n* @example\n* var v = constructorName( undefined );\n* // returns 'Undefined'\n*\n* @example\n* var v = constructorName( function noop() {} );\n* // returns 'Function'\n*/\nfunction constructorName( v ) {\n\tvar match;\n\tvar name;\n\tvar ctor;\n\tname = nativeClass( v ).slice( 8, -1 );\n\tif ( (name === 'Object' || name === 'Error') && v.constructor ) {\n\t\tctor = v.constructor;\n\t\tif ( typeof ctor.name === 'string' ) {\n\t\t\treturn ctor.name;\n\t\t}\n\t\tmatch = RE.exec( ctor.toString() );\n\t\tif ( match ) {\n\t\t\treturn match[ 1 ];\n\t\t}\n\t}\n\tif ( isBuffer( v ) ) {\n\t\treturn 'Buffer';\n\t}\n\treturn name;\n}\n\n\n// EXPORTS //\n\nexport default constructorName;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Regular expression to capture everything that is not a space immediately after the `function` keyword and before the first left parenthesis.\n*\n* @module @stdlib/regexp-function-name\n*\n* @example\n* import reFunctionName from '@stdlib/regexp-function-name';\n* var RE_FUNCTION_NAME = reFunctionName();\n*\n* function fname( fcn ) {\n* return RE_FUNCTION_NAME.exec( fcn.toString() )[ 1 ];\n* }\n*\n* var fn = fname( Math.sqrt );\n* // returns 'sqrt'\n*\n* fn = fname( Int8Array );\n* // returns 'Int8Array'\n*\n* fn = fname( Object.prototype.toString );\n* // returns 'toString'\n*\n* fn = fname( function(){} );\n* // returns ''\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport REGEXP from './regexp.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'REGEXP', REGEXP );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n// Mapping from array constructors to data types...\nvar ctor2dtypes = {\n\t'Float32Array': 'float32',\n\t'Float64Array': 'float64',\n\t'Array': 'generic',\n\t'Int16Array': 'int16',\n\t'Int32Array': 'int32',\n\t'Int8Array': 'int8',\n\t'Uint16Array': 'uint16',\n\t'Uint32Array': 'uint32',\n\t'Uint8Array': 'uint8',\n\t'Uint8ClampedArray': 'uint8c',\n\t'Complex64Array': 'complex64',\n\t'Complex128Array': 'complex128'\n};\n\n\n// EXPORTS //\n\nexport default ctor2dtypes;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasFloat64Array = ( typeof Float64Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Float64Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Float64Array\n*\n* @example\n* var bool = isFloat64Array( new Float64Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isFloat64Array( [] );\n* // returns false\n*/\nfunction isFloat64Array( value ) {\n\treturn (\n\t\t( hasFloat64Array && value instanceof Float64Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Float64Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isFloat64Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Float64Array === 'function' ) ? Float64Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Float64Array === 'function' ) ? Float64Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of double-precision floating-point numbers in the platform byte order.\n*\n* @module @stdlib/array-float64\n*\n* @example\n* import ctor from '@stdlib/array-float64';\n*\n* var arr = new ctor( 10 );\n* // returns <Float64Array>\n*/\n\n// MODULES //\n\nimport hasFloat64ArraySupport from '@stdlib/assert-has-float64array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasFloat64ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isFloat64Array from '@stdlib/assert-is-float64array';\nimport GlobalFloat64Array from './float64array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Float64Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Float64Array` support\n*\n* @example\n* var bool = hasFloat64ArraySupport();\n* // returns <boolean>\n*/\nfunction hasFloat64ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalFloat64Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalFloat64Array( [ 1.0, 3.14, -3.14, NaN ] );\n\t\tbool = (\n\t\t\tisFloat64Array( arr ) &&\n\t\t\tarr[ 0 ] === 1.0 &&\n\t\t\tarr[ 1 ] === 3.14 &&\n\t\t\tarr[ 2 ] === -3.14 &&\n\t\t\tarr[ 3 ] !== arr[ 3 ]\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasFloat64ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of double-precision floating-point numbers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasFloat32Array = ( typeof Float32Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Float32Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Float32Array\n*\n* @example\n* var bool = isFloat32Array( new Float32Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isFloat32Array( [] );\n* // returns false\n*/\nfunction isFloat32Array( value ) {\n\treturn (\n\t\t( hasFloat32Array && value instanceof Float32Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Float32Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isFloat32Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Double-precision floating-point positive infinity.\n*\n* @module @stdlib/constants-float64-pinf\n* @type {number}\n*\n* @example\n* import FLOAT64_PINF from '@stdlib/constants-float64-pinf';\n* // returns Infinity\n*/\n\n\n// MAIN //\n\n/**\n* Double-precision floating-point positive infinity.\n*\n* ## Notes\n*\n* Double-precision floating-point positive infinity has the bit sequence\n*\n* ```binarystring\n* 0 11111111111 00000000000000000000 00000000000000000000000000000000\n* ```\n*\n* @constant\n* @type {number}\n* @default Number.POSITIVE_INFINITY\n* @see [IEEE 754]{@link https://en.wikipedia.org/wiki/IEEE_754-1985}\n*/\nvar FLOAT64_PINF = Number.POSITIVE_INFINITY; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default FLOAT64_PINF;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Float32Array === 'function' ) ? Float32Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Float32Array === 'function' ) ? Float32Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of single-precision floating-point numbers in the platform byte order.\n*\n* @module @stdlib/array-float32\n*\n* @example\n* import ctor from '@stdlib/array-float32';\n*\n* var arr = new ctor( 10 );\n* // returns <Float32Array>\n*/\n\n// MODULES //\n\nimport hasFloat32ArraySupport from '@stdlib/assert-has-float32array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasFloat32ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isFloat32Array from '@stdlib/assert-is-float32array';\nimport PINF from '@stdlib/constants-float64-pinf';\nimport GlobalFloat32Array from './float32array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Float32Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Float32Array` support\n*\n* @example\n* var bool = hasFloat32ArraySupport();\n* // returns <boolean>\n*/\nfunction hasFloat32ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalFloat32Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalFloat32Array( [ 1.0, 3.14, -3.14, 5.0e40 ] );\n\t\tbool = (\n\t\t\tisFloat32Array( arr ) &&\n\t\t\tarr[ 0 ] === 1.0 &&\n\t\t\tarr[ 1 ] === 3.140000104904175 &&\n\t\t\tarr[ 2 ] === -3.140000104904175 &&\n\t\t\tarr[ 3 ] === PINF\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasFloat32ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of single-precision floating-point numbers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint32Array = ( typeof Uint32Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint32Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint32Array\n*\n* @example\n* var bool = isUint32Array( new Uint32Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint32Array( [] );\n* // returns false\n*/\nfunction isUint32Array( value ) {\n\treturn (\n\t\t( hasUint32Array && value instanceof Uint32Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint32Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint32Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint32Array === 'function' ) ? Uint32Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint32Array === 'function' ) ? Uint32Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 32-bit unsigned integers in the platform byte order.\n*\n* @module @stdlib/array-uint32\n*\n* @example\n* import ctor from '@stdlib/array-uint32';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint32Array>\n*/\n\n// MODULES //\n\nimport hasUint32ArraySupport from '@stdlib/assert-has-uint32array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint32ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint32Array from '@stdlib/assert-is-uint32array';\nimport UINT32_MAX from '@stdlib/constants-uint32-max';\nimport GlobalUint32Array from './uint32array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint32Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint32Array` support\n*\n* @example\n* var bool = hasUint32ArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint32ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint32Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = [ 1, 3.14, -3.14, UINT32_MAX+1, UINT32_MAX+2 ];\n\t\tarr = new GlobalUint32Array( arr );\n\t\tbool = (\n\t\t\tisUint32Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === UINT32_MAX-2 && // truncation and wrap around\n\t\t\tarr[ 3 ] === 0 && // wrap around\n\t\t\tarr[ 4 ] === 1 // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint32ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 32-bit unsigned integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasInt32Array = ( typeof Int32Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an Int32Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an Int32Array\n*\n* @example\n* var bool = isInt32Array( new Int32Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isInt32Array( [] );\n* // returns false\n*/\nfunction isInt32Array( value ) {\n\treturn (\n\t\t( hasInt32Array && value instanceof Int32Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Int32Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInt32Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Int32Array === 'function' ) ? Int32Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Int32Array === 'function' ) ? Int32Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of twos-complement 32-bit signed integers in the platform byte order.\n*\n* @module @stdlib/array-int32\n*\n* @example\n* import ctor from '@stdlib/array-int32';\n*\n* var arr = new ctor( 10 );\n* // returns <Int32Array>\n*/\n\n// MODULES //\n\nimport hasInt32ArraySupport from '@stdlib/assert-has-int32array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasInt32ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInt32Array from '@stdlib/assert-is-int32array';\nimport INT32_MAX from '@stdlib/constants-int32-max';\nimport INT32_MIN from '@stdlib/constants-int32-min';\nimport GlobalInt32Array from './int32array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Int32Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Int32Array` support\n*\n* @example\n* var bool = hasInt32ArraySupport();\n* // returns <boolean>\n*/\nfunction hasInt32ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalInt32Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalInt32Array( [ 1, 3.14, -3.14, INT32_MAX+1 ] );\n\t\tbool = (\n\t\t\tisInt32Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === -3 && // truncation\n\t\t\tarr[ 3 ] === INT32_MIN // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasInt32ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Minimum signed 32-bit integer.\n*\n* @module @stdlib/constants-int32-min\n* @type {integer32}\n*\n* @example\n* import INT32_MIN from '@stdlib/constants-int32-min';\n* // returns -2147483648\n*/\n\n\n// MAIN //\n\n/**\n* Minimum signed 32-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* -(2^{31})\n* ```\n*\n* which corresponds to the two's complement bit sequence\n*\n* ```binarystring\n* 10000000000000000000000000000000\n* ```\n*\n* @constant\n* @type {integer32}\n* @default -2147483648\n*/\nvar INT32_MIN = -2147483648|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT32_MIN;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of twos-complement 32-bit signed integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint16Array = ( typeof Uint16Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint16Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint16Array\n*\n* @example\n* var bool = isUint16Array( new Uint16Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint16Array( [] );\n* // returns false\n*/\nfunction isUint16Array( value ) {\n\treturn (\n\t\t( hasUint16Array && value instanceof Uint16Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint16Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint16Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint16Array === 'function' ) ? Uint16Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint16Array === 'function' ) ? Uint16Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 16-bit unsigned integers in the platform byte order.\n*\n* @module @stdlib/array-uint16\n*\n* @example\n* import ctor from '@stdlib/array-uint16';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint16Array>\n*/\n\n// MODULES //\n\nimport hasUint16ArraySupport from '@stdlib/assert-has-uint16array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint16ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint16Array from '@stdlib/assert-is-uint16array';\nimport UINT16_MAX from '@stdlib/constants-uint16-max';\nimport GlobalUint16Array from './uint16array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint16Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint16Array` support\n*\n* @example\n* var bool = hasUint16ArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint16ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint16Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = [ 1, 3.14, -3.14, UINT16_MAX+1, UINT16_MAX+2 ];\n\t\tarr = new GlobalUint16Array( arr );\n\t\tbool = (\n\t\t\tisUint16Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === UINT16_MAX-2 && // truncation and wrap around\n\t\t\tarr[ 3 ] === 0 && // wrap around\n\t\t\tarr[ 4 ] === 1 // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint16ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 16-bit unsigned integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasInt16Array = ( typeof Int16Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an Int16Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an Int16Array\n*\n* @example\n* var bool = isInt16Array( new Int16Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isInt16Array( [] );\n* // returns false\n*/\nfunction isInt16Array( value ) {\n\treturn (\n\t\t( hasInt16Array && value instanceof Int16Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Int16Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInt16Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Int16Array === 'function' ) ? Int16Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Int16Array === 'function' ) ? Int16Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of twos-complement 16-bit signed integers in the platform byte order.\n*\n* @module @stdlib/array-int16\n*\n* @example\n* import ctor from '@stdlib/array-int16';\n*\n* var arr = new ctor( 10 );\n* // returns <Int16Array>\n*/\n\n// MODULES //\n\nimport hasInt16ArraySupport from '@stdlib/assert-has-int16array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasInt16ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInt16Array from '@stdlib/assert-is-int16array';\nimport INT16_MAX from '@stdlib/constants-int16-max';\nimport INT16_MIN from '@stdlib/constants-int16-min';\nimport GlobalInt16Array from './int16array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Int16Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Int16Array` support\n*\n* @example\n* var bool = hasInt16ArraySupport();\n* // returns <boolean>\n*/\nfunction hasInt16ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalInt16Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalInt16Array( [ 1, 3.14, -3.14, INT16_MAX+1 ] );\n\t\tbool = (\n\t\t\tisInt16Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === -3 && // truncation\n\t\t\tarr[ 3 ] === INT16_MIN // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasInt16ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Minimum signed 16-bit integer.\n*\n* @module @stdlib/constants-int16-min\n* @type {integer32}\n*\n* @example\n* import INT16_MIN from '@stdlib/constants-int16-min';\n* // returns -32768\n*/\n\n\n// MAIN //\n\n/**\n* Minimum signed 16-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* -(2^{15})\n* ```\n*\n* which corresponds to the two's complement bit sequence\n*\n* ```binarystring\n* 1000000000000000\n* ```\n*\n* @constant\n* @type {integer32}\n* @default -32768\n*/\nvar INT16_MIN = -32768|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT16_MIN;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of twos-complement 16-bit signed integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint8Array = ( typeof Uint8Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint8Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint8Array\n*\n* @example\n* var bool = isUint8Array( new Uint8Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint8Array( [] );\n* // returns false\n*/\nfunction isUint8Array( value ) {\n\treturn (\n\t\t( hasUint8Array && value instanceof Uint8Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint8Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint8Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint8Array === 'function' ) ? Uint8Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint8Array === 'function' ) ? Uint8Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 8-bit unsigned integers in the platform byte order.\n*\n* @module @stdlib/array-uint8\n*\n* @example\n* import ctor from '@stdlib/array-uint8';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint8Array>\n*/\n\n// MODULES //\n\nimport hasUint8ArraySupport from '@stdlib/assert-has-uint8array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint8ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint8Array from '@stdlib/assert-is-uint8array';\nimport UINT8_MAX from '@stdlib/constants-uint8-max';\nimport GlobalUint8Array from './uint8array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint8Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint8Array` support\n*\n* @example\n* var bool = hasUint8ArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint8ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint8Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = [ 1, 3.14, -3.14, UINT8_MAX+1, UINT8_MAX+2 ];\n\t\tarr = new GlobalUint8Array( arr );\n\t\tbool = (\n\t\t\tisUint8Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === UINT8_MAX-2 && // truncation and wrap around\n\t\t\tarr[ 3 ] === 0 && // wrap around\n\t\t\tarr[ 4 ] === 1 // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint8ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 8-bit unsigned integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint8ClampedArray = ( typeof Uint8ClampedArray === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint8ClampedArray.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint8ClampedArray\n*\n* @example\n* var bool = isUint8ClampedArray( new Uint8ClampedArray( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint8ClampedArray( [] );\n* // returns false\n*/\nfunction isUint8ClampedArray( value ) {\n\treturn (\n\t\t( hasUint8ClampedArray && value instanceof Uint8ClampedArray ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint8ClampedArray]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint8ClampedArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint8ClampedArray === 'function' ) ? Uint8ClampedArray : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint8ClampedArray === 'function' ) ? Uint8ClampedArray : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 8-bit unsigned integers in the platform byte order clamped to 0-255.\n*\n* @module @stdlib/array-uint8c\n*\n* @example\n* import ctor from '@stdlib/array-uint8c';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint8ClampedArray>\n*/\n\n// MODULES //\n\nimport hasUint8ClampedArraySupport from '@stdlib/assert-has-uint8clampedarray-support'; // eslint-disable-line id-length\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint8ClampedArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint8ClampedArray from '@stdlib/assert-is-uint8clampedarray';\nimport GlobalUint8ClampedArray from './uint8clampedarray.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint8ClampedArray` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint8ClampedArray` support\n*\n* @example\n* var bool = hasUint8ClampedArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint8ClampedArraySupport() { // eslint-disable-line id-length\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint8ClampedArray !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalUint8ClampedArray( [ -1, 0, 1, 3.14, 4.99, 255, 256 ] );\n\t\tbool = (\n\t\t\tisUint8ClampedArray( arr ) &&\n\t\t\tarr[ 0 ] === 0 && // clamped\n\t\t\tarr[ 1 ] === 0 &&\n\t\t\tarr[ 2 ] === 1 &&\n\t\t\tarr[ 3 ] === 3 && // round to nearest\n\t\t\tarr[ 4 ] === 5 && // round to nearest\n\t\t\tarr[ 5 ] === 255 &&\n\t\t\tarr[ 6 ] === 255 // clamped\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint8ClampedArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 8-bit unsigned integers in the platform byte order clamped to 0-255.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasInt8Array = ( typeof Int8Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an Int8Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an Int8Array\n*\n* @example\n* var bool = isInt8Array( new Int8Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isInt8Array( [] );\n* // returns false\n*/\nfunction isInt8Array( value ) {\n\treturn (\n\t\t( hasInt8Array && value instanceof Int8Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Int8Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInt8Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Int8Array === 'function' ) ? Int8Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Int8Array === 'function' ) ? Int8Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of twos-complement 8-bit signed integers in the platform byte order.\n*\n* @module @stdlib/array-int8\n*\n* @example\n* import ctor from '@stdlib/array-int8';\n*\n* var arr = new ctor( 10 );\n* // returns <Int8Array>\n*/\n\n// MODULES //\n\nimport hasInt8ArraySupport from '@stdlib/assert-has-int8array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasInt8ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInt8Array from '@stdlib/assert-is-int8array';\nimport INT8_MAX from '@stdlib/constants-int8-max';\nimport INT8_MIN from '@stdlib/constants-int8-min';\nimport GlobalInt8Array from './int8array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Int8Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Int8Array` support\n*\n* @example\n* var bool = hasInt8ArraySupport();\n* // returns <boolean>\n*/\nfunction hasInt8ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalInt8Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalInt8Array( [ 1, 3.14, -3.14, INT8_MAX+1 ] );\n\t\tbool = (\n\t\t\tisInt8Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === -3 && // truncation\n\t\t\tarr[ 3 ] === INT8_MIN // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasInt8ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Minimum signed 8-bit integer.\n*\n* @module @stdlib/constants-int8-min\n* @type {integer32}\n*\n* @example\n* import INT8_MIN from '@stdlib/constants-int8-min';\n* // returns -128\n*/\n\n\n// MAIN //\n\n/**\n* Minimum signed 8-bit integer.\n*\n* ## Notes\n*\n* The number is given by\n*\n* ```tex\n* -(2^{7})\n* ```\n*\n* which corresponds to the two's complement bit sequence\n*\n* ```binarystring\n* 10000000\n* ```\n*\n* @constant\n* @type {integer32}\n* @default -128\n*/\nvar INT8_MIN = -128|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT8_MIN;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of twos-complement 8-bit signed integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a number primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* @example\n* var bool = isNumber( NaN );\n* // returns true\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns false\n*/\nfunction isNumber( value ) {\n\treturn ( typeof value === 'number' );\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// EXPORTS //\n\nexport default Number; // eslint-disable-line stdlib/require-globals\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Number from '@stdlib/number-ctor';\n\n\n// MAIN //\n\n// eslint-disable-next-line stdlib/no-redeclare\nvar toString = Number.prototype.toString; // non-generic\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport nativeClass from '@stdlib/utils-native-class';\nimport Number from '@stdlib/number-ctor';\nimport test from './try2serialize.js';\n\n\n// VARIABLES //\n\nvar FLG = hasToStringTag();\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number object\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns false\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*/\nfunction isNumber( value ) {\n\tif ( typeof value === 'object' ) {\n\t\tif ( value instanceof Number ) {\n\t\t\treturn true;\n\t\t}\n\t\tif ( FLG ) {\n\t\t\treturn test( value );\n\t\t}\n\t\treturn ( nativeClass( value ) === '[object Number]' );\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport toString from './tostring.js'; // eslint-disable-line stdlib/no-redeclare\n\n\n// MAIN //\n\n/**\n* Attempts to serialize a value to a string.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value can be serialized\n*/\nfunction test( value ) {\n\ttry {\n\t\ttoString.call( value );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default test;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a number\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*\n* @example\n* var bool = isNumber( NaN );\n* // returns true\n*\n* @example\n* var bool = isNumber( null );\n* // returns false\n*/\nfunction isNumber( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a number.\n*\n* @module @stdlib/assert-is-number\n*\n* @example\n* import isNumber from '@stdlib/assert-is-number';\n*\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*\n* bool = isNumber( NaN );\n* // returns true\n*\n* bool = isNumber( null );\n* // returns false\n*\n* @example\n* import { isPrimitive as isNumber } from '@stdlib/assert-is-number';\n*\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* bool = isNumber( NaN );\n* // returns true\n*\n* bool = isNumber( new Number( 3.14 ) );\n* // returns false\n*\n* @example\n* import { isObject as isNumber } from '@stdlib/assert-is-number';\n*\n* var bool = isNumber( 3.14 );\n* // returns false\n*\n* bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Double-precision floating-point negative infinity.\n*\n* @module @stdlib/constants-float64-ninf\n* @type {number}\n*\n* @example\n* import FLOAT64_NINF from '@stdlib/constants-float64-ninf';\n* // returns -Infinity\n*/\n\n// MODULES //\n\nimport Number from '@stdlib/number-ctor';\n\n\n// MAIN //\n\n/**\n* Double-precision floating-point negative infinity.\n*\n* ## Notes\n*\n* Double-precision floating-point negative infinity has the bit sequence\n*\n* ```binarystring\n* 1 11111111111 00000000000000000000 00000000000000000000000000000000\n* ```\n*\n* @constant\n* @type {number}\n* @default Number.NEGATIVE_INFINITY\n* @see [IEEE 754]{@link https://en.wikipedia.org/wiki/IEEE_754-1985}\n*/\nvar FLOAT64_NINF = Number.NEGATIVE_INFINITY;\n\n\n// EXPORTS //\n\nexport default FLOAT64_NINF;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: implementation (?)\n\n/**\n* Rounds a double-precision floating-point number toward negative infinity.\n*\n* @param {number} x - input value\n* @returns {number} rounded value\n*\n* @example\n* var v = floor( -4.2 );\n* // returns -5.0\n*\n* @example\n* var v = floor( 9.99999 );\n* // returns 9.0\n*\n* @example\n* var v = floor( 0.0 );\n* // returns 0.0\n*\n* @example\n* var v = floor( NaN );\n* // returns NaN\n*/\nvar floor = Math.floor; // eslint-disable-line stdlib/no-builtin-math\n\n\n// EXPORTS //\n\nexport default floor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport floor from '@stdlib/math-base-special-floor';\n\n\n// MAIN //\n\n/**\n* Tests if a finite double-precision floating-point number is an integer.\n*\n* @param {number} x - value to test\n* @returns {boolean} boolean indicating whether the value is an integer\n*\n* @example\n* var bool = isInteger( 1.0 );\n* // returns true\n*\n* @example\n* var bool = isInteger( 3.14 );\n* // returns false\n*/\nfunction isInteger( x ) {\n\treturn (floor(x) === x);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport PINF from '@stdlib/constants-float64-pinf';\nimport NINF from '@stdlib/constants-float64-ninf';\nimport isInt from '@stdlib/math-base-assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a number primitive is an integer value.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a number primitive is an integer value\n*/\nfunction isInteger( value ) {\n\treturn (\n\t\tvalue < PINF &&\n\t\tvalue > NINF &&\n\t\tisInt( value )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport isInt from './integer.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number primitive having an integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive having an integer value\n*\n* @example\n* var bool = isInteger( -3.0 );\n* // returns true\n*\n* @example\n* var bool = isInteger( new Number( -3.0 ) );\n* // returns false\n*/\nfunction isInteger( value ) {\n\treturn (\n\t\tisNumber( value ) &&\n\t\tisInt( value )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isObject as isNumber } from '@stdlib/assert-is-number';\nimport isInt from './integer.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number object having an integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number object having an integer value\n*\n* @example\n* var bool = isInteger( 3.0 );\n* // returns false\n*\n* @example\n* var bool = isInteger( new Number( 3.0 ) );\n* // returns true\n*/\nfunction isInteger( value ) {\n\treturn (\n\t\tisNumber( value ) &&\n\t\tisInt( value.valueOf() )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is an integer.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an integer\n*\n* @example\n* var bool = isInteger( 5.0 );\n* // returns true\n*\n* @example\n* var bool = isInteger( new Number( 5.0 ) );\n* // returns true\n*\n* @example\n* var bool = isInteger( -3.14 );\n* // returns false\n*\n* @example\n* var bool = isInteger( null );\n* // returns false\n*/\nfunction isInteger( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isInteger } from '@stdlib/assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number primitive having a nonnegative integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive having a nonnegative integer value\n*\n* @example\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns true\n*\n* @example\n* var bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns false\n*/\nfunction isNonNegativeInteger( value ) {\n\treturn (\n\t\tisInteger( value ) &&\n\t\tvalue >= 0\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isNonNegativeInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isObject as isInteger } from '@stdlib/assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number object having a nonnegative integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number object having a nonnegative integer value\n*\n* @example\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns false\n*\n* @example\n* var bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns true\n*/\nfunction isNonNegativeInteger( value ) {\n\treturn (\n\t\tisInteger( value ) &&\n\t\tvalue.valueOf() >= 0\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isNonNegativeInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a nonnegative integer.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a nonnegative integer\n*\n* @example\n* var bool = isNonNegativeInteger( 5.0 );\n* // returns true\n*\n* @example\n* var bool = isNonNegativeInteger( new Number( 5.0 ) );\n* // returns true\n*\n* @example\n* var bool = isNonNegativeInteger( -5.0 );\n* // returns false\n*\n* @example\n* var bool = isNonNegativeInteger( 3.14 );\n* // returns false\n*\n* @example\n* var bool = isNonNegativeInteger( null );\n* // returns false\n*/\nfunction isNonNegativeInteger( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isNonNegativeInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is an integer.\n*\n* @module @stdlib/assert-is-integer\n*\n* @example\n* import isInteger from '@stdlib/assert-is-integer';\n*\n* var bool = isInteger( 5.0 );\n* // returns true\n*\n* bool = isInteger( new Number( 5.0 ) );\n* // returns true\n*\n* bool = isInteger( -3.14 );\n* // returns false\n*\n* bool = isInteger( null );\n* // returns false\n*\n* @example\n* // Use interface to check for integer primitives...\n* import { isPrimitive as isInteger } from '@stdlib/assert-is-integer';\n*\n* var bool = isInteger( -3.0 );\n* // returns true\n*\n* bool = isInteger( new Number( -3.0 ) );\n* // returns false\n*\n* @example\n* // Use interface to check for integer objects...\n* import { isObject as isInteger } from '@stdlib/assert-is-integer';\n*\n* var bool = isInteger( 3.0 );\n* // returns false\n*\n* bool = isInteger( new Number( 3.0 ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a nonnegative integer.\n*\n* @module @stdlib/assert-is-nonnegative-integer\n*\n* @example\n* import isNonNegativeInteger from '@stdlib/assert-is-nonnegative-integer';\n*\n* var bool = isNonNegativeInteger( 5.0 );\n* // returns true\n*\n* bool = isNonNegativeInteger( new Number( 5.0 ) );\n* // returns true\n*\n* bool = isNonNegativeInteger( -5.0 );\n* // returns false\n*\n* bool = isNonNegativeInteger( 3.14 );\n* // returns false\n*\n* bool = isNonNegativeInteger( null );\n* // returns false\n*\n* @example\n* import { isPrimitive as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\n*\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns true\n*\n* bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns false\n*\n* @example\n* import { isObject as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\n*\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns false\n*\n* bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum length of a generic array.\n*\n* @module @stdlib/constants-array-max-array-length\n*\n* @example\n* import MAX_ARRAY_LENGTH from '@stdlib/constants-array-max-array-length';\n* // returns 4294967295\n*/\n\n// MAIN //\n\n/**\n* Maximum length of a generic array.\n*\n* ```tex\n* 2^{32} - 1\n* ```\n*\n* @constant\n* @type {uinteger32}\n* @default 4294967295\n*/\nvar MAX_ARRAY_LENGTH = 4294967295>>>0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default MAX_ARRAY_LENGTH;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport MAX_LENGTH from '@stdlib/constants-array-max-array-length';\n\n\n// MAIN //\n\n/**\n* Tests if a value is an array-like object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is an array-like object\n*\n* @example\n* var bool = isArrayLikeObject( [] );\n* // returns true\n*\n* @example\n* var bool = isArrayLikeObject( { 'length':10 } );\n* // returns true\n*\n* @example\n* var bool = isArrayLikeObject( 'beep' );\n* // returns false\n*/\nfunction isArrayLikeObject( value ) {\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\ttypeof value.length === 'number' &&\n\t\tisInteger( value.length ) &&\n\t\tvalue.length >= 0 &&\n\t\tvalue.length <= MAX_LENGTH\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isArrayLikeObject;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum length of a typed array.\n*\n* @module @stdlib/constants-array-max-typed-array-length\n*\n* @example\n* import MAX_TYPED_ARRAY_LENGTH from '@stdlib/constants-array-max-typed-array-length';\n* // returns 9007199254740991\n*/\n\n// MAIN //\n\n/**\n* Maximum length of a typed array.\n*\n* ```tex\n* 2^{53} - 1\n* ```\n*\n* @constant\n* @type {number}\n* @default 9007199254740991\n*/\nvar MAX_TYPED_ARRAY_LENGTH = 9007199254740991;\n\n\n// EXPORTS //\n\nexport default MAX_TYPED_ARRAY_LENGTH;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport MAX_LENGTH from '@stdlib/constants-array-max-typed-array-length';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a collection.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether a value is a collection\n*\n* @example\n* var bool = isCollection( [] );\n* // returns true\n*\n* @example\n* var bool = isCollection( {} );\n* // returns false\n*/\nfunction isCollection( value ) {\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\ttypeof value.length === 'number' &&\n\t\tisInteger( value.length ) &&\n\t\tvalue.length >= 0 &&\n\t\tvalue.length <= MAX_LENGTH\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isCollection;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasArrayBuffer = ( typeof ArrayBuffer === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an ArrayBuffer.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an ArrayBuffer\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var bool = isArrayBuffer( new ArrayBuffer( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isArrayBuffer( [] );\n* // returns false\n*/\nfunction isArrayBuffer( value ) {\n\treturn (\n\t\t( hasArrayBuffer && value instanceof ArrayBuffer ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object ArrayBuffer]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isArrayBuffer;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArray from '@stdlib/assert-is-array';\n\n\n// MAIN //\n\n/**\n* Tests if a value is an object; e.g., `{}`.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an object\n*\n* @example\n* var bool = isObject( {} );\n* // returns true\n*\n* @example\n* var bool = isObject( null );\n* // returns false\n*/\nfunction isObject( value ) {\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\t!isArray( value )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isObject;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a string primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string primitive\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns false\n*/\nfunction isString( value ) {\n\treturn ( typeof value === 'string' );\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// eslint-disable-next-line stdlib/no-redeclare\nvar valueOf = String.prototype.valueOf; // non-generic\n\n\n// EXPORTS //\n\nexport default valueOf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport nativeClass from '@stdlib/utils-native-class';\nimport test from './try2valueof.js';\n\n\n// VARIABLES //\n\nvar FLG = hasToStringTag();\n\n\n// MAIN //\n\n/**\n* Tests if a value is a string object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string object\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns false\n*/\nfunction isString( value ) {\n\tif ( typeof value === 'object' ) {\n\t\tif ( value instanceof String ) {\n\t\t\treturn true;\n\t\t}\n\t\tif ( FLG ) {\n\t\t\treturn test( value );\n\t\t}\n\t\treturn ( nativeClass( value ) === '[object String]' );\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport valueOf from './valueof.js'; // eslint-disable-line stdlib/no-redeclare\n\n\n// MAIN //\n\n/**\n* Attempts to extract a string value.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a string can be extracted\n*/\nfunction test( value ) {\n\ttry {\n\t\tvalueOf.call( value );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default test;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a string.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a string\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*/\nfunction isString( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a string.\n*\n* @module @stdlib/assert-is-string\n*\n* @example\n* import isString from '@stdlib/assert-is-string';\n*\n* var bool = isString( 'beep' );\n* // returns true\n*\n* bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* bool = isString( 5 );\n* // returns false\n*\n* @example\n* import { isObject as isString } from '@stdlib/assert-is-string';\n*\n* var bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* bool = isString( 'beep' );\n* // returns false\n*\n* @example\n* import { isPrimitive as isString } from '@stdlib/assert-is-string';\n*\n* var bool = isString( 'beep' );\n* // returns true\n*\n* bool = isString( new String( 'beep' ) );\n* // returns false\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\nvar RE = /./;\n\n\n// EXPORTS //\n\nexport default RE;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a boolean primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a boolean primitive\n*\n* @example\n* var bool = isBoolean( true );\n* // returns true\n*\n* @example\n* var bool = isBoolean( false );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( true ) );\n* // returns false\n*/\nfunction isBoolean( value ) {\n\treturn ( typeof value === 'boolean' );\n}\n\n\n// EXPORTS //\n\nexport default isBoolean;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Returns a boolean.\n*\n* @name Boolean\n* @constructor\n* @type {Function}\n* @param {*} value - input value\n* @returns {(boolean|Boolean)} boolean\n*\n* @example\n* var b = Boolean( null );\n* // returns false\n*\n* b = Boolean( [] );\n* // returns true\n*\n* b = Boolean( {} );\n* // returns true\n*\n* @example\n* var b = new Boolean( false );\n* // returns <Boolean>\n*/\nvar Bool = Boolean; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default Bool;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// eslint-disable-next-line stdlib/no-redeclare\nvar toString = Boolean.prototype.toString; // non-generic\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport nativeClass from '@stdlib/utils-native-class';\nimport Boolean from '@stdlib/boolean-ctor';\nimport test from './try2serialize.js';\n\n\n// VARIABLES //\n\nvar FLG = hasToStringTag();\n\n\n// MAIN //\n\n/**\n* Tests if a value is a boolean object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a boolean object\n*\n* @example\n* var bool = isBoolean( true );\n* // returns false\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( false ) );\n* // returns true\n*/\nfunction isBoolean( value ) {\n\tif ( typeof value === 'object' ) {\n\t\tif ( value instanceof Boolean ) {\n\t\t\treturn true;\n\t\t}\n\t\tif ( FLG ) {\n\t\t\treturn test( value );\n\t\t}\n\t\treturn ( nativeClass( value ) === '[object Boolean]' );\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default isBoolean;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport toString from './tostring.js'; // eslint-disable-line stdlib/no-redeclare\n\n\n// MAIN //\n\n/**\n* Attempts to serialize a value to a string.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value can be serialized\n*/\nfunction test( value ) {\n\ttry {\n\t\ttoString.call( value );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default test;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a boolean.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a boolean\n*\n* @example\n* var bool = isBoolean( false );\n* // returns true\n*\n* @example\n* var bool = isBoolean( true );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( false ) );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( true ) );\n* // returns true\n*/\nfunction isBoolean( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isBoolean;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a boolean.\n*\n* @module @stdlib/assert-is-boolean\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n* import isBoolean from '@stdlib/assert-is-boolean';\n*\n* var bool = isBoolean( false );\n* // returns true\n*\n* bool = isBoolean( new Boolean( false ) );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n* import { isPrimitive as isBoolean } from '@stdlib/assert-is-boolean';\n*\n* var bool = isBoolean( false );\n* // returns true\n*\n* bool = isBoolean( new Boolean( true ) );\n* // returns false\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n* import { isObject as isBoolean } from '@stdlib/assert-is-boolean';\n*\n* var bool = isBoolean( true );\n* // returns false\n*\n* bool = isBoolean( new Boolean( false ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar obj = ( typeof self === 'object' ) ? self : null;\n\n\n// EXPORTS //\n\nexport default obj;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar obj = ( typeof window === 'object' ) ? window : null;\n\n\n// EXPORTS //\n\nexport default obj;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar obj = ( typeof globalThis === 'object' ) ? globalThis : null; // eslint-disable-line no-undef\n\n\n// EXPORTS //\n\nexport default obj;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport getGlobal from '@stdlib/utils-global';\n\n\n// MAIN //\n\nvar root = getGlobal();\nvar nodeList = root.document && root.document.childNodes;\n\n\n// EXPORTS //\n\nexport default nodeList;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isBoolean } from '@stdlib/assert-is-boolean';\nimport format from '@stdlib/string-format';\nimport getThis from './codegen.js';\nimport Self from './self.js';\nimport Win from './window.js';\nimport GlobalThis from './global_this.js';\n\n\n// MAIN //\n\n/**\n* Returns the global object.\n*\n* ## Notes\n*\n* - Using code generation is the **most** reliable way to resolve the global object; however, doing so is likely to violate content security policies (CSPs) in, e.g., Chrome Apps and elsewhere.\n*\n* @private\n* @param {boolean} [codegen=false] - boolean indicating whether to use code generation to resolve the global object\n* @throws {TypeError} must provide a boolean\n* @throws {Error} unable to resolve global object\n* @returns {Object} global object\n*\n* @example\n* var g = getGlobal();\n* // returns {...}\n*/\nfunction getGlobal( codegen ) {\n\tif ( arguments.length ) {\n\t\tif ( !isBoolean( codegen ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a boolean. Value: `%s`.', codegen ) );\n\t\t}\n\t\tif ( codegen ) {\n\t\t\treturn getThis();\n\t\t}\n\t\t// Fall through...\n\t}\n\t// Case: 2020 revision of ECMAScript standard\n\tif ( GlobalThis ) {\n\t\treturn GlobalThis;\n\t}\n\t// Case: browsers and web workers\n\tif ( Self ) {\n\t\treturn Self;\n\t}\n\t// Case: browsers\n\tif ( Win ) {\n\t\treturn Win;\n\t}\n\t// Case: unknown\n\tthrow new Error( 'unexpected error. Unable to resolve global object.' );\n}\n\n\n// EXPORTS //\n\nexport default getGlobal;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Returns the global object using code generation.\n*\n* @private\n* @returns {Object} global object\n*/\nfunction getGlobal() {\n\treturn new Function( 'return this;' )(); // eslint-disable-line no-new-func, stdlib/require-globals\n}\n\n\n// EXPORTS //\n\nexport default getGlobal;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\nvar typedarray = Int8Array; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default typedarray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Determine a value's type.\n*\n* @module @stdlib/utils-type-of\n*\n* @example\n* import typeOf from '@stdlib/utils-type-of';\n*\n* var str = typeOf( 'a' );\n* // returns 'string'\n*\n* str = typeOf( 5 );\n* // returns 'number'\n*/\n\n// MODULES //\n\nimport usePolyfill from './check.js';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar main = ( usePolyfill() ) ? polyfill : builtin;\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport RE from './fixtures/re.js';\nimport nodeList from './fixtures/nodelist.js';\nimport typedarray from './fixtures/typedarray.js';\n\n\n// MAIN //\n\n/**\n* Checks whether a polyfill is needed when using the `typeof` operator.\n*\n* @private\n* @returns {boolean} boolean indicating whether a polyfill is needed\n*/\nfunction check() {\n\tif (\n\t\t// Chrome 1-12 returns 'function' for regular expression instances (see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/typeof):\n\t\ttypeof RE === 'function' ||\n\n\t\t// Safari 8 returns 'object' for typed array and weak map constructors (underscore #1929):\n\t\ttypeof typedarray === 'object' ||\n\n\t\t// PhantomJS 1.9 returns 'function' for `NodeList` instances (underscore #2236):\n\t\ttypeof nodeList === 'function'\n\t) {\n\t\treturn true;\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default check;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport ctorName from '@stdlib/utils-constructor-name';\n\n\n// MAIN //\n\n/**\n* Determines a value's type.\n*\n* @param {*} v - input value\n* @returns {string} string indicating the value's type\n*/\nfunction typeOf( v ) {\n\treturn ctorName( v ).toLowerCase();\n}\n\n\n// EXPORTS //\n\nexport default typeOf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport ctorName from '@stdlib/utils-constructor-name';\n\n\n// NOTES //\n\n/*\n* Built-in `typeof` operator behavior:\n*\n* ```text\n* typeof null => 'object'\n* typeof undefined => 'undefined'\n* typeof 'a' => 'string'\n* typeof 5 => 'number'\n* typeof NaN => 'number'\n* typeof true => 'boolean'\n* typeof false => 'boolean'\n* typeof {} => 'object'\n* typeof [] => 'object'\n* typeof function foo(){} => 'function'\n* typeof function* foo(){} => 'object'\n* typeof Symbol() => 'symbol'\n* ```\n*\n*/\n\n\n// MAIN //\n\n/**\n* Determines a value's type.\n*\n* @param {*} v - input value\n* @returns {string} string indicating the value's type\n*/\nfunction typeOf( v ) {\n\tvar type;\n\n\t// Address `typeof null` => `object` (see http://wiki.ecmascript.org/doku.php?id=harmony:typeof_null):\n\tif ( v === null ) {\n\t\treturn 'null';\n\t}\n\ttype = typeof v;\n\n\t// If the `typeof` operator returned something other than `object`, we are done. Otherwise, we need to check for an internal class name or search for a constructor.\n\tif ( type === 'object' ) {\n\t\treturn ctorName( v ).toLowerCase();\n\t}\n\treturn type;\n}\n\n\n// EXPORTS //\n\nexport default typeOf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport typeOf from '@stdlib/utils-type-of';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a function.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a function\n*\n* @example\n* function beep() {\n* return 'beep';\n* }\n*\n* var bool = isFunction( beep );\n* // returns true\n*/\nfunction isFunction( value ) {\n\t// Note: cannot use `typeof` directly, as various browser engines incorrectly return `'function'` when operating on non-function objects, such as regular expressions and NodeLists.\n\treturn ( typeOf( value ) === 'function' );\n}\n\n\n// EXPORTS //\n\nexport default isFunction;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 128-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex128} 128-bit complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n* // returns <Complex128>\n*/\nfunction Complex128( real, imag ) {\n\tif ( !( this instanceof Complex128 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': real\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': imag\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex128.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128.prototype, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 16\n*/\nsetReadOnly( Complex128.prototype, 'byteLength', 16 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex128.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex128` instance.\n*\n* @name toJSON\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex128', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex128.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex128;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex128';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar fround = ( typeof Math.fround === 'function' ) ? Math.fround : null; // eslint-disable-line stdlib/no-builtin-math\n\n\n// EXPORTS //\n\nexport default fround;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float32Array from '@stdlib/array-float32';\n\n\n// VARIABLES //\n\nvar FLOAT32_VIEW = new Float32Array( 1 );\n\n\n// MAIN //\n\n/**\n* Converts a double-precision floating-point number to the nearest single-precision floating-point number.\n*\n* @param {number} x - double-precision floating-point number\n* @returns {number} nearest single-precision floating-point number\n*\n* @example\n* var y = float64ToFloat32( 1.337 );\n* // returns 1.3370000123977661\n*/\nfunction float64ToFloat32( x ) {\n\tFLOAT32_VIEW[ 0 ] = x;\n\treturn FLOAT32_VIEW[ 0 ];\n}\n\n\n// EXPORTS //\n\nexport default float64ToFloat32;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Convert a double-precision floating-point number to the nearest single-precision floating-point number.\n*\n* @module @stdlib/number-float64-base-to-float32\n*\n* @example\n* import float64ToFloat32 from '@stdlib/number-float64-base-to-float32';\n*\n* var y = float64ToFloat32( 1.337 );\n* // returns 1.3370000123977661\n*/\n\n// MODULES //\n\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar float64ToFloat32;\nif ( typeof builtin === 'function' ) {\n\tfloat64ToFloat32 = builtin;\n} else {\n\tfloat64ToFloat32 = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default float64ToFloat32;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport float64ToFloat32 from '@stdlib/number-float64-base-to-float32';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 64-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex64} 64-bit complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n* // returns <Complex64>\n*/\nfunction Complex64( real, imag ) {\n\tif ( !( this instanceof Complex64 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( real )\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( imag )\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex64.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64.prototype, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 8\n*/\nsetReadOnly( Complex64.prototype, 'byteLength', 8 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex64.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex64` instance.\n*\n* @name toJSON\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex64', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex64.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex64;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Complex128 from '@stdlib/complex-float64-ctor';\nimport Complex64 from '@stdlib/complex-float32-ctor';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a complex number-like object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex number-like object.\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64-ctor';\n* import Complex64 from '@stdlib/complex-float32-ctor';\n*\n* var x = new Complex128( 4.0, 2.0 );\n* var bool = isComplexLike( x );\n* // returns true\n*\n* x = new Complex64( 4.0, 2.0 );\n* bool = isComplexLike( x );\n* // returns true\n*/\nfunction isComplexLike( value ) {\n\tif ( value instanceof Complex128 || value instanceof Complex64 ) {\n\t\treturn true;\n\t}\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\ttypeof value.re === 'number' &&\n\t\ttypeof value.im === 'number'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isComplexLike;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInteger from '@stdlib/math-base-assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a finite numeric value is an even number.\n*\n* @param {number} x - value to test\n* @returns {boolean} boolean indicating whether the value is an even number\n*\n* @example\n* var bool = isEven( 5.0 );\n* // returns false\n*\n* @example\n* var bool = isEven( -2.0 );\n* // returns true\n*\n* @example\n* var bool = isEven( 0.0 );\n* // returns true\n*\n* @example\n* var bool = isEven( NaN );\n* // returns false\n*/\nfunction isEven( x ) {\n\treturn isInteger( x/2.0 );\n}\n\n\n// EXPORTS //\n\nexport default isEven;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex64';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2024 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = 8; // 4 bytes per float32 x (1 real + 1 imag component)\n\n\n// MAIN //\n\n/**\n* Returns a boolean indicating if a value is a `Complex64Array`.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a `Complex64Array`\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n*\n* var bool = isComplex64Array( new Complex64Array( 10 ) );\n* // returns true\n*\n* bool = isComplex64Array( [] );\n* // returns false\n*/\nfunction isComplex64Array( value ) {\n\t// Note: the following is not robust and that is intentional. In this case, we are seeking a lower cost way to reasonably determine whether an input value is a `Complex64Array` in order to avoid walking the prototype chain and resolving constructors, which is necessary for robust identification of cross-realm instances. For more robust validation, see `@stdlib/assert/is-complex64array`.\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\tvalue.constructor.name === 'Complex64Array' &&\n\t\tvalue.BYTES_PER_ELEMENT === BYTES_PER_ELEMENT\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isComplex64Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2024 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = 16; // 8 bytes per float64 x (1 real + 1 imag component)\n\n\n// MAIN //\n\n/**\n* Returns a boolean indicating if a value is a `Complex128Array`.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a `Complex128Array`\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n*\n* var bool = isComplex128Array( new Complex128Array( 10 ) );\n* // returns true\n*\n* bool = isComplex128Array( [] );\n* // returns false\n*/\nfunction isComplex128Array( value ) {\n\t// Note: the following is not robust and that is intentional. In this case, we are seeking a lower cost way to reasonably determine whether an input value is a `Complex128Array` in order to avoid walking the prototype chain and resolving constructors, which is necessary for robust identification of cross-realm instances. For more robust validation, see `@stdlib/assert/is-complex128array`.\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\tvalue.constructor.name === 'Complex128Array' &&\n\t\tvalue.BYTES_PER_ELEMENT === BYTES_PER_ELEMENT\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isComplex128Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasOwnProp from '@stdlib/assert-has-own-property';\nimport Symbol from '@stdlib/symbol-ctor';\n\n\n// MAIN //\n\n/**\n* Tests for native `Symbol.iterator` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Symbol.iterator` support\n*\n* @example\n* var bool = hasIteratorSymbolSupport();\n* // returns <boolean>\n*/\nfunction hasIteratorSymbolSupport() {\n\treturn (\n\t\ttypeof Symbol === 'function' &&\n\t\ttypeof Symbol( 'foo' ) === 'symbol' &&\n\t\thasOwnProp( Symbol, 'iterator' ) &&\n\t\ttypeof Symbol.iterator === 'symbol'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default hasIteratorSymbolSupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasIteratorSymbolSupport from '@stdlib/assert-has-iterator-symbol-support';\n\n\n// MAIN //\n\n/**\n* Iterator symbol.\n*\n* @name IteratorSymbol\n* @constant\n* @type {(symbol|null)}\n*\n* @example\n* function iterator() {\n* var it;\n* var i;\n*\n* i = -1;\n*\n* it = {};\n* it.next = next;\n* it.return = done;\n*\n* if ( IteratorSymbol ) {\n* it[ IteratorSymbol ] = iterator;\n* }\n* return it;\n*\n* function next() {\n* i += 1;\n* return {\n* 'value': i,\n* 'done': false\n* };\n* }\n*\n* function done( value ) {\n* if ( arguments.length === 0 ) {\n* return {\n* 'done': true\n* };\n* }\n* return {\n* 'value': value,\n* 'done': true\n* };\n* }\n* }\n*\n* var obj = iterator();\n*/\nvar IteratorSymbol = ( hasIteratorSymbolSupport() ) ? Symbol.iterator : null;\n\n\n// EXPORTS //\n\nexport default IteratorSymbol;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport defineProperty from '@stdlib/utils-define-property';\n\n\n// MAIN //\n\n/**\n* Defines a non-enumerable read-only accessor.\n*\n* @param {Object} obj - object on which to define the property\n* @param {(string|symbol)} prop - property name\n* @param {Function} getter - accessor\n*\n* @example\n* function getter() {\n* return 'bar';\n* }\n*\n* var obj = {};\n*\n* setNonEnumerableReadOnlyAccessor( obj, 'foo', getter );\n*\n* try {\n* obj.foo = 'boop';\n* } catch ( err ) {\n* console.error( err.message );\n* }\n*/\nfunction setNonEnumerableReadOnlyAccessor( obj, prop, getter ) { // eslint-disable-line id-length\n\tdefineProperty( obj, prop, {\n\t\t'configurable': false,\n\t\t'enumerable': false,\n\t\t'get': getter\n\t});\n}\n\n\n// EXPORTS //\n\nexport default setNonEnumerableReadOnlyAccessor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport float64ToFloat32 from '@stdlib/number-float64-base-to-float32';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 64-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex64} 64-bit complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n* // returns <Complex64>\n*/\nfunction Complex64( real, imag ) {\n\tif ( !( this instanceof Complex64 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( real )\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( imag )\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex64.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64.prototype, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 8\n*/\nsetReadOnly( Complex64.prototype, 'byteLength', 8 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex64.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex64` instance.\n*\n* @name toJSON\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex64', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex64.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex64;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the real component of a single-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} real component\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var re = realf( z );\n* // returns 5.0\n*/\nfunction realf( z ) {\n\treturn z.re;\n}\n\n\n// EXPORTS //\n\nexport default realf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the imaginary component of a single-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} imaginary component\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var im = imagf( z );\n* // returns 3.0\n*/\nfunction imagf( z ) {\n\treturn z.im;\n}\n\n\n// EXPORTS //\n\nexport default imagf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float32Array from '@stdlib/array-float32';\n\n\n// MAIN //\n\n/**\n* Reinterprets a `Complex64Array` as a `Float32Array`.\n*\n* @param {Complex64Array} x - input array\n* @param {NonNegativeInteger} offset - starting index\n* @returns {Float32Array} `Float32Array` view\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n*\n* var x = new Complex64Array( 10 );\n*\n* var out = reinterpret( x, 0 );\n* // returns <Float32Array>\n*\n* var bool = ( out.buffer === x.buffer );\n* // returns true\n*/\nfunction reinterpret( x, offset ) {\n\treturn new Float32Array( x.buffer, x.byteOffset+(x.BYTES_PER_ELEMENT*offset), 2*(x.length-offset) ); // eslint-disable-line max-len\n}\n\n\n// EXPORTS //\n\nexport default reinterpret;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float64Array from '@stdlib/array-float64';\n\n\n// MAIN //\n\n/**\n* Reinterprets a `Complex128Array` as a `Float64Array`.\n*\n* @param {Complex128Array} x - input array\n* @param {NonNegativeInteger} offset - starting index\n* @returns {Float64Array} `Float64Array` view\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n*\n* var x = new Complex128Array( 10 );\n*\n* var out = reinterpret( x, 0 );\n* // returns <Float64Array>\n*\n* var bool = ( out.buffer === x.buffer );\n* // returns true\n*/\nfunction reinterpret( x, offset ) {\n\treturn new Float64Array( x.buffer, x.byteOffset+(x.BYTES_PER_ELEMENT*offset), 2*(x.length-offset) ); // eslint-disable-line max-len\n}\n\n\n// EXPORTS //\n\nexport default reinterpret;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\nimport format from '@stdlib/string-format';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIterator( it ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\n\tout = [];\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\tz = v.value;\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( realf( z ), imagf( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIterator;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex64';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/* eslint-disable no-restricted-syntax, max-lines, no-invalid-this */\n\n/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isCollection from '@stdlib/assert-is-collection';\nimport isArrayBuffer from '@stdlib/assert-is-arraybuffer';\nimport isObject from '@stdlib/assert-is-object';\nimport isArray from '@stdlib/assert-is-array';\nimport { isPrimitive as isString } from '@stdlib/assert-is-string';\nimport isFunction from '@stdlib/assert-is-function';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport isEven from '@stdlib/math-base-assert-is-even';\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport isComplex64Array from '@stdlib/array-base-assert-is-complex64array';\nimport isComplex128Array from '@stdlib/array-base-assert-is-complex128array';\nimport hasIteratorSymbolSupport from '@stdlib/assert-has-iterator-symbol-support';\nimport ITERATOR_SYMBOL from '@stdlib/symbol-iterator';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport setReadOnlyAccessor from '@stdlib/utils-define-nonenumerable-read-only-accessor';\nimport Float32Array from '@stdlib/array-float32';\nimport Complex64 from '@stdlib/complex-float32';\nimport format from '@stdlib/string-format';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\nimport floor from '@stdlib/math-base-special-floor';\nimport reinterpret64 from '@stdlib/strided-base-reinterpret-complex64';\nimport reinterpret128 from '@stdlib/strided-base-reinterpret-complex128';\nimport getter from '@stdlib/array-base-getter';\nimport accessorGetter from '@stdlib/array-base-accessor-getter';\nimport fromIterator from './from_iterator.js';\nimport fromIteratorMap from './from_iterator_map.js';\nimport fromArray from './from_array.js';\n\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = Float32Array.BYTES_PER_ELEMENT * 2;\nvar HAS_ITERATOR_SYMBOL = hasIteratorSymbolSupport();\n\n\n// FUNCTIONS //\n\n/**\n* Returns a boolean indicating if a value is a complex typed array.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array\n*/\nfunction isComplexArray( value ) {\n\treturn (\n\t\tvalue instanceof Complex64Array ||\n\t\t(\n\t\t\ttypeof value === 'object' &&\n\t\t\tvalue !== null &&\n\t\t\t(\n\t\t\t\tvalue.constructor.name === 'Complex64Array' ||\n\t\t\t\tvalue.constructor.name === 'Complex128Array'\n\t\t\t) &&\n\t\t\ttypeof value._length === 'number' && // eslint-disable-line no-underscore-dangle\n\n\t\t\t// NOTE: we don't perform a more rigorous test here for a typed array for performance reasons, as robustly checking for a typed array instance could require walking the prototype tree and performing relatively expensive constructor checks...\n\t\t\ttypeof value._buffer === 'object' // eslint-disable-line no-underscore-dangle\n\t\t)\n\t);\n}\n\n/**\n* Returns a boolean indicating if a value is a complex typed array constructor.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array constructor\n*/\nfunction isComplexArrayConstructor( value ) {\n\treturn (\n\t\tvalue === Complex64Array ||\n\n\t\t// NOTE: weaker test in order to avoid a circular dependency with Complex128Array...\n\t\tvalue.name === 'Complex128Array'\n\t);\n}\n\n/**\n* Retrieves a complex number from a complex number array buffer.\n*\n* @private\n* @param {Float32Array} buf - array buffer\n* @param {NonNegativeInteger} idx - element index\n* @returns {Complex64} complex number\n*/\nfunction getComplex64( buf, idx ) {\n\tidx *= 2;\n\treturn new Complex64( buf[ idx ], buf[ idx+1 ] );\n}\n\n\n// MAIN //\n\n/**\n* 64-bit complex number array constructor.\n*\n* @constructor\n* @param {(NonNegativeInteger|Collection|ArrayBuffer|Iterable)} [arg] - length, typed array, array-like object, buffer, or an iterable\n* @param {NonNegativeInteger} [byteOffset=0] - byte offset\n* @param {NonNegativeInteger} [length] - view length\n* @throws {RangeError} ArrayBuffer byte length must be a multiple of `8`\n* @throws {RangeError} array-like object and typed array input arguments must have a length which is a multiple of two\n* @throws {TypeError} if provided only a single argument, must provide a valid argument\n* @throws {TypeError} byte offset must be a nonnegative integer\n* @throws {RangeError} byte offset must be a multiple of `8`\n* @throws {TypeError} view length must be a positive multiple of `8`\n* @throws {RangeError} must provide sufficient memory to accommodate byte offset and view length requirements\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex64Array} complex number array\n*\n* @example\n* var arr = new Complex64Array();\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 0\n*\n* @example\n* var arr = new Complex64Array( 2 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* var arr = new Complex64Array( [ 1.0, -1.0 ] );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 16 );\n* var arr = new Complex64Array( buf );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 16 );\n* var arr = new Complex64Array( buf, 8 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 32 );\n* var arr = new Complex64Array( buf, 8, 2 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nfunction Complex64Array() {\n\tvar byteOffset;\n\tvar nargs;\n\tvar buf;\n\tvar len;\n\n\tnargs = arguments.length;\n\tif ( !(this instanceof Complex64Array) ) {\n\t\tif ( nargs === 0 ) {\n\t\t\treturn new Complex64Array();\n\t\t}\n\t\tif ( nargs === 1 ) {\n\t\t\treturn new Complex64Array( arguments[0] );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\treturn new Complex64Array( arguments[0], arguments[1] );\n\t\t}\n\t\treturn new Complex64Array( arguments[0], arguments[1], arguments[2] );\n\t}\n\t// Create the underlying data buffer...\n\tif ( nargs === 0 ) {\n\t\tbuf = new Float32Array( 0 ); // backward-compatibility\n\t} else if ( nargs === 1 ) {\n\t\tif ( isNonNegativeInteger( arguments[0] ) ) {\n\t\t\tbuf = new Float32Array( arguments[0]*2 );\n\t\t} else if ( isCollection( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tlen = buf.length;\n\n\t\t\t// If provided a \"generic\" array, peak at the first value, and, if the value is a complex number, try to process as an array of complex numbers, falling back to \"normal\" typed array initialization if we fail and ensuring consistency if the first value had not been a complex number...\n\t\t\tif ( len && isArray( buf ) && isComplexLike( buf[0] ) ) {\n\t\t\t\tbuf = fromArray( new Float32Array( len*2 ), buf );\n\t\t\t\tif ( buf === null ) {\n\t\t\t\t\t// We failed and we are now forced to allocate a new array :-(\n\t\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t\t}\n\t\t\t\t\t// We failed, so fall back to directly setting values...\n\t\t\t\t\tbuf = new Float32Array( arguments[0] );\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif ( isComplex64Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret64( buf, 0 );\n\t\t\t\t} else if ( isComplex128Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret128( buf, 0 );\n\t\t\t\t} else if ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t}\n\t\t\t\tbuf = new Float32Array( buf );\n\t\t\t}\n\t\t} else if ( isArrayBuffer( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( !isInteger( buf.byteLength/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.', BYTES_PER_ELEMENT, buf.byteLength ) );\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf );\n\t\t} else if ( isObject( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( HAS_ITERATOR_SYMBOL === false ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tif ( !isFunction( buf[ ITERATOR_SYMBOL ] ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tbuf = buf[ ITERATOR_SYMBOL ]();\n\t\t\tif ( !isFunction( buf.next ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) ); // FIXME: `buf` is what is returned from above, NOT the original value\n\t\t\t}\n\t\t\tbuf = fromIterator( buf );\n\t\t\tif ( buf instanceof Error ) {\n\t\t\t\tthrow buf;\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf );\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', arguments[0] ) );\n\t\t}\n\t} else {\n\t\tbuf = arguments[ 0 ];\n\t\tif ( !isArrayBuffer( buf ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an ArrayBuffer. Value: `%s`.', buf ) );\n\t\t}\n\t\tbyteOffset = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( byteOffset ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.', byteOffset ) );\n\t\t}\n\t\tif ( !isInteger( byteOffset/BYTES_PER_ELEMENT ) ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Byte offset must be a multiple of %u. Value: `%u`.', BYTES_PER_ELEMENT, byteOffset ) );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\tlen = buf.byteLength - byteOffset;\n\t\t\tif ( !isInteger( len/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.', BYTES_PER_ELEMENT, len ) );\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf, byteOffset );\n\t\t} else {\n\t\t\tlen = arguments[ 2 ];\n\t\t\tif ( !isNonNegativeInteger( len ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Length must be a nonnegative integer. Value: `%s`.', len ) );\n\t\t\t}\n\t\t\tif ( (len*BYTES_PER_ELEMENT) > (buf.byteLength-byteOffset) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.', len*BYTES_PER_ELEMENT ) );\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf, byteOffset, len*2 );\n\t\t}\n\t}\n\tsetReadOnly( this, '_buffer', buf );\n\tsetReadOnly( this, '_length', buf.length/2 );\n\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64Array\n* @readonly\n* @type {PositiveInteger}\n* @default 8\n*\n* @example\n* var nbytes = Complex64Array.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex64Array, 'BYTES_PER_ELEMENT', BYTES_PER_ELEMENT );\n\n/**\n* Constructor name.\n*\n* @name name\n* @memberof Complex64Array\n* @readonly\n* @type {string}\n* @default 'Complex64Array'\n*\n* @example\n* var str = Complex64Array.name;\n* // returns 'Complex64Array'\n*/\nsetReadOnly( Complex64Array, 'name', 'Complex64Array' );\n\n/**\n* Creates a new 64-bit complex number array from an array-like object or an iterable.\n*\n* @name from\n* @memberof Complex64Array\n* @type {Function}\n* @param {(Collection|Iterable)} src - array-like object or iterable\n* @param {Function} [clbk] - callback to invoke for each source element\n* @param {*} [thisArg] - context\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an array-like object or an iterable\n* @throws {TypeError} second argument must be a function\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @throws {TypeError} when provided an iterator, a callback must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex64Array} 64-bit complex number array\n*\n* @example\n* var arr = Complex64Array.from( [ 1.0, -1.0 ] );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = Complex64Array.from( [ new Complex64( 1.0, 1.0 ) ] );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function clbk( v ) {\n* return new Complex64( realf(v)*2.0, imagf(v)*2.0 );\n* }\n*\n* var arr = Complex64Array.from( [ new Complex64( 1.0, 1.0 ) ], clbk );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*/\nsetReadOnly( Complex64Array, 'from', function from( src ) {\n\tvar thisArg;\n\tvar nargs;\n\tvar clbk;\n\tvar out;\n\tvar buf;\n\tvar tmp;\n\tvar get;\n\tvar len;\n\tvar flg;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tnargs = arguments.length;\n\tif ( nargs > 1 ) {\n\t\tclbk = arguments[ 1 ];\n\t\tif ( !isFunction( clbk ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a function. Value: `%s`.', clbk ) );\n\t\t}\n\t\tif ( nargs > 2 ) {\n\t\t\tthisArg = arguments[ 2 ];\n\t\t}\n\t}\n\tif ( isComplexArray( src ) ) {\n\t\tlen = src.length;\n\t\tif ( clbk ) {\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, src.get( i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = realf( v );\n\t\t\t\t\tbuf[ j+1 ] = imagf( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isCollection( src ) ) {\n\t\tif ( clbk ) {\n\t\t\t// Note: array contents affect how we iterate over a provided data source. If only complex number objects, we can extract real and imaginary components. Otherwise, for non-complex number arrays (e.g., `Float64Array`, etc), we assume a strided array where real and imaginary components are interleaved. In the former case, we expect a callback to return real and imaginary components (possibly as a complex number). In the latter case, we expect a callback to return *either* a real or imaginary component.\n\n\t\t\tlen = src.length;\n\t\t\tif ( src.get && src.set ) {\n\t\t\t\tget = accessorGetter( 'default' );\n\t\t\t} else {\n\t\t\t\tget = getter( 'default' );\n\t\t\t}\n\t\t\t// Detect whether we've been provided an array which returns complex number objects...\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tif ( !isComplexLike( get( src, i ) ) ) {\n\t\t\t\t\tflg = true;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// If an array does not contain only complex number objects, then we assume interleaved real and imaginary components...\n\t\t\tif ( flg ) {\n\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. First argument must have a length which is a multiple of %u. Length: `%u`.', 2, len ) );\n\t\t\t\t}\n\t\t\t\tout = new this( len/2 );\n\t\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\t\tbuf[ i ] = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\t}\n\t\t\t\treturn out;\n\t\t\t}\n\t\t\t// If an array contains only complex number objects, then we need to extract real and imaginary components...\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = realf( v );\n\t\t\t\t\tbuf[ j+1 ] = imagf( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isObject( src ) && HAS_ITERATOR_SYMBOL && isFunction( src[ ITERATOR_SYMBOL ] ) ) { // eslint-disable-line max-len\n\t\tbuf = src[ ITERATOR_SYMBOL ]();\n\t\tif ( !isFunction( buf.next ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n\t\t}\n\t\tif ( clbk ) {\n\t\t\ttmp = fromIteratorMap( buf, clbk, thisArg );\n\t\t} else {\n\t\t\ttmp = fromIterator( buf );\n\t\t}\n\t\tif ( tmp instanceof Error ) {\n\t\t\tthrow tmp;\n\t\t}\n\t\tlen = tmp.length / 2;\n\t\tout = new this( len );\n\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\tbuf[ i ] = tmp[ i ];\n\t\t}\n\t\treturn out;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n});\n\n/**\n* Creates a new 64-bit complex number array from a variable number of arguments.\n*\n* @name of\n* @memberof Complex64Array\n* @type {Function}\n* @param {...*} element - array elements\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} 64-bit complex number array\n*\n* @example\n* var arr = Complex64Array.of( 1.0, 1.0, 1.0, 1.0 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nsetReadOnly( Complex64Array, 'of', function of() {\n\tvar args;\n\tvar i;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\targs = [];\n\tfor ( i = 0; i < arguments.length; i++ ) {\n\t\targs.push( arguments[ i ] );\n\t}\n\treturn new this( args );\n});\n\n/**\n* Returns an array element with support for both nonnegative and negative integer indices.\n*\n* @name at\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide an integer\n* @returns {(Complex64|void)} array element\n*\n* @example\n* var arr = new Complex64Array( 10 );\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var z = arr.at( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 0.0\n*\n* var im = imagf( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 9.0, -9.0 ], 9 );\n*\n* z = arr.at( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns -1.0\n*\n* z = arr.at( -1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 9.0\n*\n* im = imagf( z );\n* // returns -9.0\n*\n* z = arr.at( 100 );\n* // returns undefined\n*\n* z = arr.at( -100 );\n* // returns undefined\n*/\nsetReadOnly( Complex64Array.prototype, 'at', function at( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide an integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx < 0 ) {\n\t\tidx += this._length;\n\t}\n\tif ( idx < 0 || idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex64( this._buffer, idx );\n});\n\n/**\n* Pointer to the underlying data buffer.\n*\n* @name buffer\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {ArrayBuffer}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var buf = arr.buffer;\n* // returns <ArrayBuffer>\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'buffer', function get() {\n\treturn this._buffer.buffer;\n});\n\n/**\n* Size (in bytes) of the array.\n*\n* @name byteLength\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var byteLength = arr.byteLength;\n* // returns 80\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'byteLength', function get() {\n\treturn this._buffer.byteLength;\n});\n\n/**\n* Offset (in bytes) of the array from the start of its underlying `ArrayBuffer`.\n*\n* @name byteOffset\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var byteOffset = arr.byteOffset;\n* // returns 0\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'byteOffset', function get() {\n\treturn this._buffer.byteOffset;\n});\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {PositiveInteger}\n* @default 8\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var nbytes = arr.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex64Array.prototype, 'BYTES_PER_ELEMENT', Complex64Array.BYTES_PER_ELEMENT );\n\n/**\n* Copies a sequence of elements within the array to the position starting at `target`.\n*\n* @name copyWithin\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} target - index at which to start copying elements\n* @param {integer} start - source index at which to copy elements from\n* @param {integer} [end] - source index at which to stop copying elements from\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} modified array\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 4 );\n*\n* // Set the array elements:\n* arr.set( new Complex64( 1.0, 1.0 ), 0 );\n* arr.set( new Complex64( 2.0, 2.0 ), 1 );\n* arr.set( new Complex64( 3.0, 3.0 ), 2 );\n* arr.set( new Complex64( 4.0, 4.0 ), 3 );\n*\n* // Copy the first two elements to the last two elements:\n* arr.copyWithin( 2, 0, 2 );\n*\n* // Get the last array element:\n* var z = arr.get( 3 );\n*\n* var re = realf( z );\n* // returns 2.0\n*\n* var im = imagf( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex64Array.prototype, 'copyWithin', function copyWithin( target, start ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\t// FIXME: prefer a functional `copyWithin` implementation which addresses lack of universal browser support (e.g., IE11 and Safari) or ensure that typed arrays are polyfilled\n\tif ( arguments.length === 2 ) {\n\t\tthis._buffer.copyWithin( target*2, start*2 );\n\t} else {\n\t\tthis._buffer.copyWithin( target*2, start*2, arguments[2]*2 );\n\t}\n\treturn this;\n});\n\n/**\n* Returns an iterator for iterating over array key-value pairs.\n*\n* @name entries\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Iterator} iterator\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = [\n* new Complex64( 1.0, 1.0 ),\n* new Complex64( 2.0, 2.0 ),\n* new Complex64( 3.0, 3.0 )\n* ];\n* arr = new Complex64Array( arr );\n*\n* // Create an iterator:\n* var it = arr.entries();\n*\n* // Iterate over the key-value pairs...\n* var v = it.next().value;\n* // returns [ 0, <Complex64> ]\n*\n* v = it.next().value;\n* // returns [ 1, <Complex64> ]\n*\n* v = it.next().value;\n* // returns [ 2, <Complex64> ]\n*\n* var bool = it.next().done;\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'entries', function entries() {\n\tvar buffer;\n\tvar self;\n\tvar iter;\n\tvar len;\n\tvar FLG;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tself = this;\n\tbuffer = this._buffer;\n\tlen = this._length;\n\n\t// Initialize the iteration indices:\n\ti = -1;\n\tj = -2;\n\n\t// Create an iterator protocol-compliant object:\n\titer = {};\n\tsetReadOnly( iter, 'next', next );\n\tsetReadOnly( iter, 'return', end );\n\n\tif ( ITERATOR_SYMBOL ) {\n\t\tsetReadOnly( iter, ITERATOR_SYMBOL, factory );\n\t}\n\treturn iter;\n\n\t/**\n\t* Returns an iterator protocol-compliant object containing the next iterated value.\n\t*\n\t* @private\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction next() {\n\t\tvar z;\n\t\ti += 1;\n\t\tif ( FLG || i >= len ) {\n\t\t\treturn {\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\tj += 2;\n\t\tz = new Complex64( buffer[ j ], buffer[ j+1 ] );\n\t\treturn {\n\t\t\t'value': [ i, z ],\n\t\t\t'done': false\n\t\t};\n\t}\n\n\t/**\n\t* Finishes an iterator.\n\t*\n\t* @private\n\t* @param {*} [value] - value to return\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction end( value ) {\n\t\tFLG = true;\n\t\tif ( arguments.length ) {\n\t\t\treturn {\n\t\t\t\t'value': value,\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\t'done': true\n\t\t};\n\t}\n\n\t/**\n\t* Returns a new iterator.\n\t*\n\t* @private\n\t* @returns {Iterator} iterator\n\t*/\n\tfunction factory() {\n\t\treturn self.entries();\n\t}\n});\n\n/**\n* Tests whether all elements in an array pass a test implemented by a predicate function.\n*\n* @name every\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether all elements pass a test\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var bool = arr.every( predicate );\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'every', function every( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( !predicate.call( thisArg, getComplex64( buf, i ), i, this ) ) {\n\t\t\treturn false;\n\t\t}\n\t}\n\treturn true;\n});\n\n/**\n* Returns a modified typed array filled with a fill value.\n*\n* @name fill\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} value - fill value\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @throws {TypeError} third argument must be an integer\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.fill( new Complex64( 1.0, 1.0 ), 1 );\n*\n* var z = arr.get( 1 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns 1.0\n*\n* z = arr.get( 1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'fill', function fill( value, start, end ) {\n\tvar buf;\n\tvar len;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length > 2 ) {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Third argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t} else {\n\t\t\tend = len;\n\t\t}\n\t} else {\n\t\tstart = 0;\n\t\tend = len;\n\t}\n\tre = realf( value );\n\tim = imagf( value );\n\tfor ( i = start; i < end; i++ ) {\n\t\tidx = 2*i;\n\t\tbuf[ idx ] = re;\n\t\tbuf[ idx+1 ] = im;\n\t}\n\treturn this;\n});\n\n/**\n* Returns a new array containing the elements of an array which pass a test implemented by a predicate function.\n*\n* @name filter\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex64Array} complex number array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.filter( predicate );\n* // returns <Complex64Array>\n*\n* var len = out.length;\n* // returns 1\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 2.0\n*\n* var im = imagf( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex64Array.prototype, 'filter', function filter( predicate, thisArg ) {\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tout = [];\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\tout.push( z );\n\t\t}\n\t}\n\treturn new this.constructor( out );\n});\n\n/**\n* Returns the first element in an array for which a predicate function returns a truthy value.\n*\n* @name find\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex64|void)} array element or undefined\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import Complex64 from '@stdlib/complex-float32';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.find( predicate );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'find', function find( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the first element in an array for which a predicate function returns a truthy value.\n*\n* @name findIndex\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var idx = arr.findIndex( predicate );\n* // returns 2\n*/\nsetReadOnly( Complex64Array.prototype, 'findIndex', function findIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLast\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex64|void)} array element or undefined\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import Complex64 from '@stdlib/complex-float32';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.findLast( predicate );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 3.0\n*\n* var im = imagf( z );\n* // returns 3.0\n*/\nsetReadOnly( Complex64Array.prototype, 'findLast', function findLast( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLastIndex\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var idx = arr.findLastIndex( predicate );\n* // returns 1\n*/\nsetReadOnly( Complex64Array.prototype, 'findLastIndex', function findLastIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Invokes a function once for each array element.\n*\n* @name forEach\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} fcn - function to invoke\n* @param {*} [thisArg] - function invocation context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* function log( v, i ) {\n* console.log( '%s: %s', i, v.toString() );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* arr.forEach( log );\n*/\nsetReadOnly( Complex64Array.prototype, 'forEach', function forEach( fcn, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tfcn.call( thisArg, z, i, this );\n\t}\n});\n\n/**\n* Returns an array element.\n*\n* @name get\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {NonNegativeInteger} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide a nonnegative integer\n* @returns {(Complex64|void)} array element\n*\n* @example\n* var arr = new Complex64Array( 10 );\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var z = arr.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 0.0\n*\n* var im = imagf( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns -1.0\n*\n* z = arr.get( 100 );\n* // returns undefined\n*/\nsetReadOnly( Complex64Array.prototype, 'get', function get( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isNonNegativeInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide a nonnegative integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex64( this._buffer, idx );\n});\n\n/**\n* Returns a boolean indicating whether an array includes a provided value.\n*\n* @name includes\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - search element\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {boolean} boolean indicating whether an array includes a provided value\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var bool = arr.includes( new Complex64( 3.0, -3.0 ) );\n* // returns true\n*\n* bool = arr.includes( new Complex64( 3.0, -3.0 ), 3 );\n* // returns false\n*\n* bool = arr.includes( new Complex64( 4.0, -4.0 ), -3 );\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'includes', function includes( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = realf( searchElement );\n\tim = imagf( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Returns the first index at which a given element can be found.\n*\n* @name indexOf\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 10 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var idx = arr.indexOf( new Complex64( 3.0, -3.0 ) );\n* // returns 2\n*\n* idx = arr.indexOf( new Complex64( 3.0, -3.0 ), 3 );\n* // returns -1\n*\n* idx = arr.indexOf( new Complex64( 4.0, -4.0 ), -3 );\n* // returns -1\n*/\nsetReadOnly( Complex64Array.prototype, 'indexOf', function indexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = realf( searchElement );\n\tim = imagf( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns a new string by concatenating all array elements.\n*\n* @name join\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {string} [separator=','] - element separator\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a string\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex64Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.join();\n* // returns '1 + 1i,2 + 2i'\n*\n* str = arr.join( '/' );\n* // returns '1 + 1i/2 + 2i'\n*/\nsetReadOnly( Complex64Array.prototype, 'join', function join( separator ) {\n\tvar out;\n\tvar buf;\n\tvar sep;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( arguments.length === 0 ) {\n\t\tsep = ',';\n\t} else if ( isString( separator ) ) {\n\t\tsep = separator;\n\t} else {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a string. Value: `%s`.', separator ) );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex64( buf, i ).toString() );\n\t}\n\treturn out.join( sep );\n});\n\n/**\n* Returns the last index at which a given element can be found.\n*\n* @name lastIndexOf\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex] - index at which to start searching backward (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 3.0, -3.0 ], 4 );\n*\n* var idx = arr.lastIndexOf( new Complex64( 3.0, -3.0 ) );\n* // returns 4\n*\n* idx = arr.lastIndexOf( new Complex64( 3.0, -3.0 ), 3 );\n* // returns 2\n*\n* idx = arr.lastIndexOf( new Complex64( 5.0, -5.0 ), 3 );\n* // returns -1\n*\n* idx = arr.lastIndexOf( new Complex64( 2.0, -2.0 ), -3 );\n* // returns 1\n*/\nsetReadOnly( Complex64Array.prototype, 'lastIndexOf', function lastIndexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex >= this._length ) {\n\t\t\tfromIndex = this._length - 1;\n\t\t} else if ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t}\n\t} else {\n\t\tfromIndex = this._length - 1;\n\t}\n\tre = realf( searchElement );\n\tim = imagf( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i >= 0; i-- ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Number of array elements.\n*\n* @name length\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var len = arr.length;\n* // returns 10\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'length', function get() {\n\treturn this._length;\n});\n\n/**\n* Returns a new array with each element being the result of a provided callback function.\n*\n* @name map\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} fcn - callback function\n* @param {*} [thisArg] - callback function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex64Array} complex number array\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function scale( v, i ) {\n* return new Complex64( 2.0*realf( v ), 2.0*imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.map( scale );\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 2\n*\n* var im = imagf( z );\n* // returns -2\n*/\nsetReadOnly( Complex64Array.prototype, 'map', function map( fcn, thisArg ) {\n\tvar outbuf;\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar v;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tout = new this.constructor( this._length );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tv = fcn.call( thisArg, getComplex64( buf, i ), i, this );\n\t\tif ( isComplexLike( v ) ) {\n\t\t\toutbuf[ 2*i ] = realf( v );\n\t\t\toutbuf[ (2*i)+1 ] = imagf( v );\n\t\t} else if ( isArrayLikeObject( v ) && v.length === 2 ) {\n\t\t\toutbuf[ 2*i ] = v[ 0 ];\n\t\t\toutbuf[ (2*i)+1 ] = v[ 1 ];\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t}\n\t}\n\treturn out;\n});\n\n/**\n* Applies a provided callback function to each element of the array, in order, passing in the return value from the calculation on the preceding element and returning the accumulated result upon completion.\n*\n* @name reduce\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} reducer - callback function\n* @param {*} [initialValue] - initial value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @throws {Error} if not provided an initial value, the array must have at least one element\n* @returns {*} accumulated result\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import caddf from '@stdlib/math-base-ops-caddf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.reduce( caddf );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 6.0\n*\n* var im = imagf( z );\n* // returns 6.0\n*/\nsetReadOnly( Complex64Array.prototype, 'reduce', function reduce( reducer, initialValue ) {\n\tvar buf;\n\tvar acc;\n\tvar len;\n\tvar v;\n\tvar i;\n\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( reducer ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', reducer ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tacc = initialValue;\n\t\ti = 0;\n\t} else {\n\t\tif ( len === 0 ) {\n\t\t\tthrow new Error( 'invalid operation. If not provided an initial value, an array must contain at least one element.' );\n\t\t}\n\t\tacc = getComplex64( buf, 0 );\n\t\ti = 1;\n\t}\n\tfor ( ; i < len; i++ ) {\n\t\tv = getComplex64( buf, i );\n\t\tacc = reducer( acc, v, i, this );\n\t}\n\treturn acc;\n});\n\n/**\n* Reverses an array in-place.\n*\n* @name reverse\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} reversed array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.reverse();\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 3.0\n*\n* var im = imagf( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'reverse', function reverse() {\n\tvar buf;\n\tvar tmp;\n\tvar len;\n\tvar N;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tbuf = this._buffer;\n\tN = floor( len / 2 );\n\tfor ( i = 0; i < N; i++ ) {\n\t\tj = len - i - 1;\n\t\ttmp = buf[ (2*i) ];\n\t\tbuf[ (2*i) ] = buf[ (2*j) ];\n\t\tbuf[ (2*j) ] = tmp;\n\t\ttmp = buf[ (2*i)+1 ];\n\t\tbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t\tbuf[ (2*j)+1 ] = tmp;\n\t}\n\treturn this;\n});\n\n/**\n* Sets an array element.\n*\n* ## Notes\n*\n* - When provided a typed array, real or complex, we must check whether the source array shares the same buffer as the target array and whether the underlying memory overlaps. In particular, we are concerned with the following scenario:\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* In the above, as we copy values from `src`, we will overwrite values in the `src` view, resulting in duplicated values copied into the end of `buf`, which is not intended. Hence, to avoid overwriting source values, we must **copy** source values to a temporary array.\n*\n* In the other overlapping scenario,\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* by the time we begin copying into the overlapping region, we are copying from the end of `src`, a non-overlapping region, which means we don't run the risk of copying copied values, rather than the original `src` values, as intended.\n*\n* @name set\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {(Collection|Complex|ComplexArray)} value - value(s)\n* @param {NonNegativeInteger} [i=0] - element index at which to start writing values\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be either a complex number, an array-like object, or a complex number array\n* @throws {TypeError} index argument must be a nonnegative integer\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {RangeError} target array lacks sufficient storage to accommodate source values\n* @returns {void}\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 10 );\n*\n* var z = arr.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 0.0\n*\n* var im = imagf( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns -1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'set', function set( value ) {\n\t/* eslint-disable no-underscore-dangle */\n\tvar sbuf;\n\tvar idx;\n\tvar buf;\n\tvar tmp;\n\tvar flg;\n\tvar N;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tif ( arguments.length > 1 ) {\n\t\tidx = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( idx ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Index argument must be a nonnegative integer. Value: `%s`.', idx ) );\n\t\t}\n\t} else {\n\t\tidx = 0;\n\t}\n\tif ( isComplexLike( value ) ) {\n\t\tif ( idx >= this._length ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%u`.', idx ) );\n\t\t}\n\t\tidx *= 2;\n\t\tbuf[ idx ] = realf( value );\n\t\tbuf[ idx+1 ] = imagf( value );\n\t\treturn;\n\t}\n\tif ( isComplexArray( value ) ) {\n\t\tN = value._length;\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tsbuf = value._buffer;\n\n\t\t// Check for overlapping memory...\n\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\tif (\n\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t(\n\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t)\n\t\t) {\n\t\t\t// We need to copy source values...\n\t\t\ttmp = new Float32Array( sbuf.length );\n\t\t\tfor ( i = 0; i < sbuf.length; i++ ) {\n\t\t\t\ttmp[ i ] = sbuf[ i ];\n\t\t\t}\n\t\t\tsbuf = tmp;\n\t\t}\n\t\tidx *= 2;\n\t\tj = 0;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\tidx += 2; // stride\n\t\t\tj += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tif ( isCollection( value ) ) {\n\t\t// Detect whether we've been provided an array of complex numbers...\n\t\tN = value.length;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tif ( !isComplexLike( value[ i ] ) ) {\n\t\t\t\tflg = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// If an array does not contain only complex numbers, then we assume interleaved real and imaginary components...\n\t\tif ( flg ) {\n\t\t\tif ( !isEven( N ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', N ) );\n\t\t\t}\n\t\t\tif ( idx+(N/2) > this._length ) {\n\t\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t\t}\n\t\t\tsbuf = value;\n\n\t\t\t// Check for overlapping memory...\n\t\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\t\tif (\n\t\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t\t(\n\t\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\t// We need to copy source values...\n\t\t\t\ttmp = new Float32Array( N );\n\t\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\t\ttmp[ i ] = sbuf[ i ]; // TODO: handle accessor arrays\n\t\t\t\t}\n\t\t\t\tsbuf = tmp;\n\t\t\t}\n\t\t\tidx *= 2;\n\t\t\tN /= 2;\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\t\tidx += 2; // stride\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t\t// If an array contains only complex numbers, then we need to extract real and imaginary components...\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tidx *= 2;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tv = value[ i ];\n\t\t\tbuf[ idx ] = realf( v );\n\t\t\tbuf[ idx+1 ] = imagf( v );\n\t\t\tidx += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.', value ) );\n\n\t/* eslint-enable no-underscore-dangle */\n});\n\n/**\n* Copies a portion of a typed array to a new typed array.\n*\n* @name slice\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex64Array} complex number array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var out = arr.slice();\n* // returns <Complex64Array>\n*\n* var len = out.length;\n* // returns 5\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns -1.0\n*\n* z = out.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 5.0\n*\n* im = imagf( z );\n* // returns -5.0\n*\n* out = arr.slice( 1, -2 );\n* // returns <Complex64Array>\n*\n* len = out.length;\n* // returns 2\n*\n* z = out.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns -2.0\n*\n* z = out.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 3.0\n*\n* im = imagf( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex64Array.prototype, 'slice', function slice( start, end ) {\n\tvar outlen;\n\tvar outbuf;\n\tvar out;\n\tvar idx;\n\tvar buf;\n\tvar len;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tstart = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( start < end ) {\n\t\toutlen = end - start;\n\t} else {\n\t\toutlen = 0;\n\t}\n\tout = new this.constructor( outlen );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < outlen; i++ ) {\n\t\tidx = 2*(i+start);\n\t\toutbuf[ 2*i ] = buf[ idx ];\n\t\toutbuf[ (2*i)+1 ] = buf[ idx+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Tests whether at least one element in an array passes a test implemented by a predicate function.\n*\n* @name some\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether at least one element passes a test\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var bool = arr.some( predicate );\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'some', function some( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( predicate.call( thisArg, getComplex64( buf, i ), i, this ) ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Creates a new typed array view over the same underlying `ArrayBuffer` and with the same underlying data type as the host array.\n*\n* @name subarray\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} [begin=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex64Array} subarray\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var subarr = arr.subarray();\n* // returns <Complex64Array>\n*\n* var len = subarr.length;\n* // returns 5\n*\n* var z = subarr.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns -1.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 5.0\n*\n* im = imagf( z );\n* // returns -5.0\n*\n* subarr = arr.subarray( 1, -2 );\n* // returns <Complex64Array>\n*\n* len = subarr.length;\n* // returns 2\n*\n* z = subarr.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns -2.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 3.0\n*\n* im = imagf( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex64Array.prototype, 'subarray', function subarray( begin, end ) {\n\tvar offset;\n\tvar buf;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tbegin = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( begin ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', begin ) );\n\t\t}\n\t\tif ( begin < 0 ) {\n\t\t\tbegin += len;\n\t\t\tif ( begin < 0 ) {\n\t\t\t\tbegin = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( begin >= len ) {\n\t\tlen = 0;\n\t\toffset = buf.byteLength;\n\t} else if ( begin >= end ) {\n\t\tlen = 0;\n\t\toffset = buf.byteOffset + (begin*BYTES_PER_ELEMENT);\n\t} else {\n\t\tlen = end - begin;\n\t\toffset = buf.byteOffset + ( begin*BYTES_PER_ELEMENT );\n\t}\n\treturn new this.constructor( buf.buffer, offset, ( len < 0 ) ? 0 : len );\n});\n\n/**\n* Returns a new typed array containing the elements in reversed order.\n*\n* @name toReversed\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} reversed array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.toReversed();\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 3.0\n*\n* var im = imagf( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'toReversed', function toReversed() {\n\tvar outbuf;\n\tvar out;\n\tvar len;\n\tvar buf;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tout = new this.constructor( len );\n\tbuf = this._buffer;\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < len; i++ ) {\n\t\tj = len - i - 1;\n\t\toutbuf[ (2*i) ] = buf[ (2*j) ];\n\t\toutbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Serializes an array as a string.\n*\n* @name toString\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex64Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.toString();\n* // returns '1 + 1i,2 + 2i'\n*/\nsetReadOnly( Complex64Array.prototype, 'toString', function toString() {\n\tvar out;\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex64( buf, i ).toString() );\n\t}\n\treturn out.join( ',' );\n});\n\n/**\n* Returns a new typed array with the element at a provided index replaced with a provided value.\n*\n* @name with\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} index - element index\n* @param {ComplexLike} value - new value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {TypeError} second argument must be a complex number\n* @returns {Complex64Array} new typed array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.with( 0, new Complex64( 4.0, 4.0 ) );\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 4.0\n*\n* var im = imagf( z );\n* // returns 4.0\n*/\nsetReadOnly( Complex64Array.prototype, 'with', function copyWith( index, value ) {\n\tvar buf;\n\tvar out;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( index ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', index ) );\n\t}\n\tlen = this._length;\n\tif ( index < 0 ) {\n\t\tindex += len;\n\t}\n\tif ( index < 0 || index >= len ) {\n\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%s`.', index ) );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tout = new this.constructor( this._buffer );\n\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tbuf[ 2*index ] = realf( value );\n\tbuf[ (2*index)+1 ] = imagf( value );\n\treturn out;\n});\n\n\n// EXPORTS //\n\nexport default Complex64Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\n\n\n// MAIN //\n\n/**\n* Returns a strided array of real and imaginary components.\n*\n* @private\n* @param {Float32Array} buf - output array\n* @param {Array} arr - array containing complex numbers\n* @returns {(Float32Array|null)} output array or null\n*/\nfunction fromArray( buf, arr ) {\n\tvar len;\n\tvar v;\n\tvar i;\n\tvar j;\n\n\tlen = arr.length;\n\tj = 0;\n\tfor ( i = 0; i < len; i++ ) {\n\t\tv = arr[ i ];\n\t\tif ( !isComplexLike( v ) ) {\n\t\t\treturn null;\n\t\t}\n\t\tbuf[ j ] = realf( v );\n\t\tbuf[ j+1 ] = imagf( v );\n\t\tj += 2; // stride\n\t}\n\treturn buf;\n}\n\n\n// EXPORTS //\n\nexport default fromArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 128-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex128} 128-bit complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n* // returns <Complex128>\n*/\nfunction Complex128( real, imag ) {\n\tif ( !( this instanceof Complex128 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': real\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': imag\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex128.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128.prototype, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 16\n*/\nsetReadOnly( Complex128.prototype, 'byteLength', 16 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex128.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex128` instance.\n*\n* @name toJSON\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex128', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex128.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex128;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the real component of a double-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} real component\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var re = real( z );\n* // returns 5.0\n*/\nfunction real( z ) {\n\treturn z.re;\n}\n\n\n// EXPORTS //\n\nexport default real;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the imaginary component of a double-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} imaginary component\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var im = imag( z );\n* // returns 3.0\n*/\nfunction imag( z ) {\n\treturn z.im;\n}\n\n\n// EXPORTS //\n\nexport default imag;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport format from '@stdlib/string-format';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIterator( it ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\n\tout = [];\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\tz = v.value;\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( real( z ), imag( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIterator;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\nimport format from '@stdlib/string-format';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @param {Function} clbk - callback to invoke for each iterated value\n* @param {*} thisArg - invocation context\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIteratorMap( it, clbk, thisArg ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\tvar i;\n\n\tout = [];\n\ti = -1;\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\ti += 1;\n\t\tz = clbk.call( thisArg, v.value, i );\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( realf( z ), imagf( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIteratorMap;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex128';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/* eslint-disable no-restricted-syntax, max-lines, no-invalid-this */\n\n/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isCollection from '@stdlib/assert-is-collection';\nimport isArrayBuffer from '@stdlib/assert-is-arraybuffer';\nimport isObject from '@stdlib/assert-is-object';\nimport isArray from '@stdlib/assert-is-array';\nimport isString from '@stdlib/assert-is-string';\nimport isFunction from '@stdlib/assert-is-function';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport isEven from '@stdlib/math-base-assert-is-even';\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport isComplex64Array from '@stdlib/array-base-assert-is-complex64array';\nimport isComplex128Array from '@stdlib/array-base-assert-is-complex128array';\nimport hasIteratorSymbolSupport from '@stdlib/assert-has-iterator-symbol-support';\nimport ITERATOR_SYMBOL from '@stdlib/symbol-iterator';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport setReadOnlyAccessor from '@stdlib/utils-define-nonenumerable-read-only-accessor';\nimport Float64Array from '@stdlib/array-float64';\nimport Complex128 from '@stdlib/complex-float64';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\nimport floor from '@stdlib/math-base-special-floor';\nimport reinterpret64 from '@stdlib/strided-base-reinterpret-complex64';\nimport reinterpret128 from '@stdlib/strided-base-reinterpret-complex128';\nimport getter from '@stdlib/array-base-getter';\nimport accessorGetter from '@stdlib/array-base-accessor-getter';\nimport format from '@stdlib/string-format';\nimport fromIterator from './from_iterator.js';\nimport fromIteratorMap from './from_iterator_map.js';\nimport fromArray from './from_array.js';\n\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = Float64Array.BYTES_PER_ELEMENT * 2;\nvar HAS_ITERATOR_SYMBOL = hasIteratorSymbolSupport();\n\n\n// FUNCTIONS //\n\n/**\n* Returns a boolean indicating if a value is a complex typed array.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array\n*/\nfunction isComplexArray( value ) {\n\treturn (\n\t\tvalue instanceof Complex128Array ||\n\t\t(\n\t\t\ttypeof value === 'object' &&\n\t\t\tvalue !== null &&\n\t\t\t(\n\t\t\t\tvalue.constructor.name === 'Complex64Array' ||\n\t\t\t\tvalue.constructor.name === 'Complex128Array'\n\t\t\t) &&\n\t\t\ttypeof value._length === 'number' && // eslint-disable-line no-underscore-dangle\n\n\t\t\t// NOTE: we don't perform a more rigorous test here for a typed array for performance reasons, as robustly checking for a typed array instance could require walking the prototype tree and performing relatively expensive constructor checks...\n\t\t\ttypeof value._buffer === 'object' // eslint-disable-line no-underscore-dangle\n\t\t)\n\t);\n}\n\n/**\n* Returns a boolean indicating if a value is a complex typed array constructor.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array constructor\n*/\nfunction isComplexArrayConstructor( value ) {\n\treturn (\n\t\tvalue === Complex128Array ||\n\n\t\t// NOTE: weaker test in order to avoid a circular dependency with Complex64Array...\n\t\tvalue.name === 'Complex64Array'\n\t);\n}\n\n/**\n* Retrieves a complex number from a complex number array buffer.\n*\n* @private\n* @param {Float64Array} buf - array buffer\n* @param {NonNegativeInteger} idx - element index\n* @returns {Complex128} complex number\n*/\nfunction getComplex128( buf, idx ) {\n\tidx *= 2;\n\treturn new Complex128( buf[ idx ], buf[ idx+1 ] );\n}\n\n\n// MAIN //\n\n/**\n* 128-bit complex number array constructor.\n*\n* @constructor\n* @param {(NonNegativeInteger|Collection|ArrayBuffer|Iterable)} [arg] - length, typed array, array-like object, buffer, or iterable\n* @param {NonNegativeInteger} [byteOffset=0] - byte offset\n* @param {NonNegativeInteger} [length] - view length\n* @throws {RangeError} ArrayBuffer byte length must be a multiple of `16`\n* @throws {RangeError} array-like object and typed array input arguments must have a length which is a multiple of two\n* @throws {TypeError} if provided only a single argument, must provide a valid argument\n* @throws {TypeError} byte offset must be a nonnegative integer\n* @throws {RangeError} byte offset must be a multiple of `16`\n* @throws {TypeError} view length must be a positive multiple of `16`\n* @throws {RangeError} must provide sufficient memory to accommodate byte offset and view length requirements\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex128Array} complex number array\n*\n* @example\n* var arr = new Complex128Array();\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 0\n*\n* @example\n* var arr = new Complex128Array( 2 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* var arr = new Complex128Array( [ 1.0, -1.0 ] );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 32 );\n* var arr = new Complex128Array( buf );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 32 );\n* var arr = new Complex128Array( buf, 16 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 64 );\n* var arr = new Complex128Array( buf, 16, 2 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nfunction Complex128Array() {\n\tvar byteOffset;\n\tvar nargs;\n\tvar buf;\n\tvar len;\n\n\tnargs = arguments.length;\n\tif ( !(this instanceof Complex128Array) ) {\n\t\tif ( nargs === 0 ) {\n\t\t\treturn new Complex128Array();\n\t\t}\n\t\tif ( nargs === 1 ) {\n\t\t\treturn new Complex128Array( arguments[0] );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\treturn new Complex128Array( arguments[0], arguments[1] );\n\t\t}\n\t\treturn new Complex128Array( arguments[0], arguments[1], arguments[2] );\n\t}\n\t// Create the underlying data buffer...\n\tif ( nargs === 0 ) {\n\t\tbuf = new Float64Array( 0 ); // backward-compatibility\n\t} else if ( nargs === 1 ) {\n\t\tif ( isNonNegativeInteger( arguments[0] ) ) {\n\t\t\tbuf = new Float64Array( arguments[0]*2 );\n\t\t} else if ( isCollection( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tlen = buf.length;\n\n\t\t\t// If provided a \"generic\" array, peak at the first value, and, if the value is a complex number, try to process as an array of complex numbers, falling back to \"normal\" typed array initialization if we fail and ensuring consistency if the first value had not been a complex number...\n\t\t\tif ( len && isArray( buf ) && isComplexLike( buf[0] ) ) {\n\t\t\t\tbuf = fromArray( new Float64Array( len*2 ), buf );\n\t\t\t\tif ( buf === null ) {\n\t\t\t\t\t// We failed and we are now forced to allocate a new array :-(\n\t\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t\t}\n\t\t\t\t\t// We failed, so fall back to directly setting values...\n\t\t\t\t\tbuf = new Float64Array( arguments[0] );\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif ( isComplex64Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret64( buf, 0 );\n\t\t\t\t} else if ( isComplex128Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret128( buf, 0 );\n\t\t\t\t} else if ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t}\n\t\t\t\tbuf = new Float64Array( buf );\n\t\t\t}\n\t\t} else if ( isArrayBuffer( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( !isInteger( buf.byteLength/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.', BYTES_PER_ELEMENT, buf.byteLength ) );\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf );\n\t\t} else if ( isObject( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( HAS_ITERATOR_SYMBOL === false ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tif ( !isFunction( buf[ ITERATOR_SYMBOL ] ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tbuf = buf[ ITERATOR_SYMBOL ]();\n\t\t\tif ( !isFunction( buf.next ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tbuf = fromIterator( buf );\n\t\t\tif ( buf instanceof Error ) {\n\t\t\t\tthrow buf;\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf );\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', arguments[0] ) );\n\t\t}\n\t} else {\n\t\tbuf = arguments[ 0 ];\n\t\tif ( !isArrayBuffer( buf ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an ArrayBuffer. Value: `%s`.', buf ) );\n\t\t}\n\t\tbyteOffset = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( byteOffset ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.', byteOffset ) );\n\t\t}\n\t\tif ( !isInteger( byteOffset/BYTES_PER_ELEMENT ) ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Byte offset must be a multiple of %u. Value: `%u`.', BYTES_PER_ELEMENT, byteOffset ) );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\tlen = buf.byteLength - byteOffset;\n\t\t\tif ( !isInteger( len/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.', BYTES_PER_ELEMENT, len ) );\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf, byteOffset );\n\t\t} else {\n\t\t\tlen = arguments[ 2 ];\n\t\t\tif ( !isNonNegativeInteger( len ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Length must be a nonnegative integer. Value: `%s`.', len ) );\n\t\t\t}\n\t\t\tif ( (len*BYTES_PER_ELEMENT) > (buf.byteLength-byteOffset) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.', len*BYTES_PER_ELEMENT ) );\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf, byteOffset, len*2 );\n\t\t}\n\t}\n\tsetReadOnly( this, '_buffer', buf );\n\tsetReadOnly( this, '_length', buf.length/2 );\n\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128Array\n* @readonly\n* @type {PositiveInteger}\n* @default 16\n*\n* @example\n* var nbytes = Complex128Array.BYTES_PER_ELEMENT;\n* // returns 16\n*/\nsetReadOnly( Complex128Array, 'BYTES_PER_ELEMENT', BYTES_PER_ELEMENT );\n\n/**\n* Constructor name.\n*\n* @name name\n* @memberof Complex128Array\n* @readonly\n* @type {string}\n* @default 'Complex128Array'\n*\n* @example\n* var name = Complex128Array.name;\n* // returns 'Complex128Array'\n*/\nsetReadOnly( Complex128Array, 'name', 'Complex128Array' );\n\n/**\n* Creates a new 128-bit complex number array from an array-like object or an iterable.\n*\n* @name from\n* @memberof Complex128Array\n* @type {Function}\n* @param {(Collection|Object)} src - array-like object or iterable\n* @param {Function} [clbk] - callback to invoke for each source element\n* @param {*} [thisArg] - context\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an array-like object or an iterable\n* @throws {TypeError} second argument must be a function\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @throws {TypeError} when provided an iterator, a callback must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex128Array} 128-bit complex number array\n*\n* @example\n* var arr = Complex128Array.from( [ 1.0, -1.0 ] );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = Complex128Array.from( [ new Complex128( 1.0, 1.0 ) ] );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function clbk( v ) {\n* return new Complex128( real(v)*2.0, imag(v)*2.0 );\n* }\n*\n* var arr = Complex128Array.from( [ new Complex128( 1.0, 1.0 ) ], clbk );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*/\nsetReadOnly( Complex128Array, 'from', function from( src ) {\n\tvar thisArg;\n\tvar nargs;\n\tvar clbk;\n\tvar out;\n\tvar buf;\n\tvar tmp;\n\tvar get;\n\tvar len;\n\tvar flg;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tnargs = arguments.length;\n\tif ( nargs > 1 ) {\n\t\tclbk = arguments[ 1 ];\n\t\tif ( !isFunction( clbk ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a function. Value: `%s`.', clbk ) );\n\t\t}\n\t\tif ( nargs > 2 ) {\n\t\t\tthisArg = arguments[ 2 ];\n\t\t}\n\t}\n\tif ( isComplexArray( src ) ) {\n\t\tlen = src.length;\n\t\tif ( clbk ) {\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, src.get( i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = real( v );\n\t\t\t\t\tbuf[ j+1 ] = imag( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isCollection( src ) ) {\n\t\tif ( clbk ) {\n\t\t\t// Note: array contents affect how we iterate over a provided data source. If only complex number objects, we can extract real and imaginary components. Otherwise, for non-complex number arrays (e.g., `Float64Array`, etc), we assume a strided array where real and imaginary components are interleaved. In the former case, we expect a callback to return real and imaginary components (possibly as a complex number). In the latter case, we expect a callback to return *either* a real or imaginary component.\n\n\t\t\tlen = src.length;\n\t\t\tif ( src.get && src.set ) {\n\t\t\t\tget = accessorGetter( 'default' );\n\t\t\t} else {\n\t\t\t\tget = getter( 'default' );\n\t\t\t}\n\t\t\t// Detect whether we've been provided an array which returns complex number objects...\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tif ( !isComplexLike( get( src, i ) ) ) {\n\t\t\t\t\tflg = true;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// If an array does not contain only complex number objects, then we assume interleaved real and imaginary components...\n\t\t\tif ( flg ) {\n\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. First argument must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t}\n\t\t\t\tout = new this( len/2 );\n\t\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\t\tbuf[ i ] = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\t}\n\t\t\t\treturn out;\n\t\t\t}\n\t\t\t// If an array contains only complex number objects, then we need to extract real and imaginary components...\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = real( v );\n\t\t\t\t\tbuf[ j+1 ] = imag( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isObject( src ) && HAS_ITERATOR_SYMBOL && isFunction( src[ ITERATOR_SYMBOL ] ) ) { // eslint-disable-line max-len\n\t\tbuf = src[ ITERATOR_SYMBOL ]();\n\t\tif ( !isFunction( buf.next ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n\t\t}\n\t\tif ( clbk ) {\n\t\t\ttmp = fromIteratorMap( buf, clbk, thisArg );\n\t\t} else {\n\t\t\ttmp = fromIterator( buf );\n\t\t}\n\t\tif ( tmp instanceof Error ) {\n\t\t\tthrow tmp;\n\t\t}\n\t\tlen = tmp.length / 2;\n\t\tout = new this( len );\n\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\tbuf[ i ] = tmp[ i ];\n\t\t}\n\t\treturn out;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n});\n\n/**\n* Creates a new 128-bit complex number array from a variable number of arguments.\n*\n* @name of\n* @memberof Complex128Array\n* @type {Function}\n* @param {...*} element - array elements\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} 128-bit complex number array\n*\n* @example\n* var arr = Complex128Array.of( 1.0, 1.0, 1.0, 1.0 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nsetReadOnly( Complex128Array, 'of', function of() {\n\tvar args;\n\tvar i;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\targs = [];\n\tfor ( i = 0; i < arguments.length; i++ ) {\n\t\targs.push( arguments[ i ] );\n\t}\n\treturn new this( args );\n});\n\n/**\n* Returns an array element with support for both nonnegative and negative integer indices.\n*\n* @name at\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide an integer\n* @returns {(Complex128|void)} array element\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 10 );\n*\n* var z = arr.at( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 0.0\n*\n* var im = imag( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 9.0, -9.0 ], 9 );\n*\n* z = arr.at( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns -1.0\n*\n* z = arr.at( -1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 9.0\n*\n* im = imag( z );\n* // returns -9.0\n*\n* z = arr.at( 100 );\n* // returns undefined\n*\n* z = arr.at( -100 );\n* // returns undefined\n*/\nsetReadOnly( Complex128Array.prototype, 'at', function at( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide an integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx < 0 ) {\n\t\tidx += this._length;\n\t}\n\tif ( idx < 0 || idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex128( this._buffer, idx );\n});\n\n/**\n* Pointer to the underlying data buffer.\n*\n* @name buffer\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {ArrayBuffer}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var buf = arr.buffer;\n* // returns <ArrayBuffer>\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'buffer', function get() {\n\treturn this._buffer.buffer;\n});\n\n/**\n* Size (in bytes) of the array.\n*\n* @name byteLength\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var byteLength = arr.byteLength;\n* // returns 160\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'byteLength', function get() {\n\treturn this._buffer.byteLength;\n});\n\n/**\n* Offset (in bytes) of the array from the start of its underlying `ArrayBuffer`.\n*\n* @name byteOffset\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var byteOffset = arr.byteOffset;\n* // returns 0\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'byteOffset', function get() {\n\treturn this._buffer.byteOffset;\n});\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {PositiveInteger}\n* @default 16\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var nbytes = arr.BYTES_PER_ELEMENT;\n* // returns 16\n*/\nsetReadOnly( Complex128Array.prototype, 'BYTES_PER_ELEMENT', Complex128Array.BYTES_PER_ELEMENT );\n\n/**\n* Copies a sequence of elements within the array to the position starting at `target`.\n*\n* @name copyWithin\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} target - index at which to start copying elements\n* @param {integer} start - source index at which to copy elements from\n* @param {integer} [end] - source index at which to stop copying elements from\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} modified array\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 4 );\n*\n* // Set the array elements:\n* arr.set( new Complex128( 1.0, 1.0 ), 0 );\n* arr.set( new Complex128( 2.0, 2.0 ), 1 );\n* arr.set( new Complex128( 3.0, 3.0 ), 2 );\n* arr.set( new Complex128( 4.0, 4.0 ), 3 );\n*\n* // Copy the first two elements to the last two elements:\n* arr.copyWithin( 2, 0, 2 );\n*\n* // Get the last array element:\n* var z = arr.get( 3 );\n*\n* var re = real( z );\n* // returns 2.0\n*\n* var im = imag( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex128Array.prototype, 'copyWithin', function copyWithin( target, start ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\t// FIXME: prefer a functional `copyWithin` implementation which addresses lack of universal browser support (e.g., IE11 and Safari) or ensure that typed arrays are polyfilled\n\tif ( arguments.length === 2 ) {\n\t\tthis._buffer.copyWithin( target*2, start*2 );\n\t} else {\n\t\tthis._buffer.copyWithin( target*2, start*2, arguments[2]*2 );\n\t}\n\treturn this;\n});\n\n/**\n* Returns an iterator for iterating over array key-value pairs.\n*\n* @name entries\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Iterator} iterator\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = [\n* new Complex128( 1.0, 1.0 ),\n* new Complex128( 2.0, 2.0 ),\n* new Complex128( 3.0, 3.0 )\n* ];\n* arr = new Complex128Array( arr );\n*\n* // Create an iterator:\n* var it = arr.entries();\n*\n* // Iterate over the key-value pairs...\n* var v = it.next().value;\n* // returns [ 0, <Complex128> ]\n*\n* v = it.next().value;\n* // returns [ 1, <Complex128> ]\n*\n* v = it.next().value;\n* // returns [ 2, <Complex128> ]\n*\n* var bool = it.next().done;\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'entries', function entries() {\n\tvar buffer;\n\tvar self;\n\tvar iter;\n\tvar len;\n\tvar FLG;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tself = this;\n\tbuffer = this._buffer;\n\tlen = this._length;\n\n\t// Initialize the iteration indices:\n\ti = -1;\n\tj = -2;\n\n\t// Create an iterator protocol-compliant object:\n\titer = {};\n\tsetReadOnly( iter, 'next', next );\n\tsetReadOnly( iter, 'return', end );\n\n\tif ( ITERATOR_SYMBOL ) {\n\t\tsetReadOnly( iter, ITERATOR_SYMBOL, factory );\n\t}\n\treturn iter;\n\n\t/**\n\t* Returns an iterator protocol-compliant object containing the next iterated value.\n\t*\n\t* @private\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction next() {\n\t\tvar z;\n\t\ti += 1;\n\t\tif ( FLG || i >= len ) {\n\t\t\treturn {\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\tj += 2;\n\t\tz = new Complex128( buffer[ j ], buffer[ j+1 ] );\n\t\treturn {\n\t\t\t'value': [ i, z ],\n\t\t\t'done': false\n\t\t};\n\t}\n\n\t/**\n\t* Finishes an iterator.\n\t*\n\t* @private\n\t* @param {*} [value] - value to return\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction end( value ) {\n\t\tFLG = true;\n\t\tif ( arguments.length ) {\n\t\t\treturn {\n\t\t\t\t'value': value,\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\t'done': true\n\t\t};\n\t}\n\n\t/**\n\t* Returns a new iterator.\n\t*\n\t* @private\n\t* @returns {Iterator} iterator\n\t*/\n\tfunction factory() {\n\t\treturn self.entries();\n\t}\n});\n\n/**\n* Tests whether all elements in an array pass a test implemented by a predicate function.\n*\n* @name every\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether all elements pass a test\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var bool = arr.every( predicate );\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'every', function every( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( !predicate.call( thisArg, getComplex128( buf, i ), i, this ) ) {\n\t\t\treturn false;\n\t\t}\n\t}\n\treturn true;\n});\n\n/**\n* Returns a modified typed array filled with a fill value.\n*\n* @name fill\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} value - fill value\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @throws {TypeError} third argument must be an integer\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.fill( new Complex128( 1.0, 1.0 ), 1 );\n*\n* var z = arr.get( 1 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns 1.0\n*\n* z = arr.get( 1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'fill', function fill( value, start, end ) {\n\tvar buf;\n\tvar len;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length > 2 ) {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Third argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t} else {\n\t\t\tend = len;\n\t\t}\n\t} else {\n\t\tstart = 0;\n\t\tend = len;\n\t}\n\tre = real( value );\n\tim = imag( value );\n\tfor ( i = start; i < end; i++ ) {\n\t\tidx = 2*i;\n\t\tbuf[ idx ] = re;\n\t\tbuf[ idx+1 ] = im;\n\t}\n\treturn this;\n});\n\n/**\n* Returns a new array containing the elements of an array which pass a test implemented by a predicate function.\n*\n* @name filter\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex128Array} complex number array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.filter( predicate );\n* // returns <Complex128Array>\n*\n* var len = out.length;\n* // returns 1\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 2.0\n*\n* var im = imag( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex128Array.prototype, 'filter', function filter( predicate, thisArg ) {\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tout = [];\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\tout.push( z );\n\t\t}\n\t}\n\treturn new this.constructor( out );\n});\n\n/**\n* Returns the first element in an array for which a predicate function returns a truthy value.\n*\n* @name find\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex128|void)} array element or undefined\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.find( predicate );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'find', function find( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the first element in an array for which a predicate function returns a truthy value.\n*\n* @name findIndex\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var idx = arr.findIndex( predicate );\n* // returns 2\n*/\nsetReadOnly( Complex128Array.prototype, 'findIndex', function findIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLast\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex128|void)} array element or undefined\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.findLast( predicate );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 3.0\n*\n* var im = imag( z );\n* // returns 3.0\n*/\nsetReadOnly( Complex128Array.prototype, 'findLast', function findLast( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLastIndex\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var idx = arr.findLastIndex( predicate );\n* // returns 1\n*/\nsetReadOnly( Complex128Array.prototype, 'findLastIndex', function findLastIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Invokes a function once for each array element.\n*\n* @name forEach\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} fcn - function to invoke\n* @param {*} [thisArg] - function invocation context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* function log( v, i ) {\n* console.log( '%s: %s', i, v.toString() );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* arr.forEach( log );\n*/\nsetReadOnly( Complex128Array.prototype, 'forEach', function forEach( fcn, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tfcn.call( thisArg, z, i, this );\n\t}\n});\n\n/**\n* Returns an array element.\n*\n* @name get\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {NonNegativeInteger} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide a nonnegative integer\n* @returns {(Complex128|void)} array element\n*\n* @example\n* var arr = new Complex128Array( 10 );\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var z = arr.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 0.0\n*\n* var im = imag( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns -1.0\n*\n* z = arr.get( 100 );\n* // returns undefined\n*/\nsetReadOnly( Complex128Array.prototype, 'get', function get( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isNonNegativeInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide a nonnegative integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex128( this._buffer, idx );\n});\n\n/**\n* Number of array elements.\n*\n* @name length\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var len = arr.length;\n* // returns 10\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'length', function get() {\n\treturn this._length;\n});\n\n/**\n* Returns a boolean indicating whether an array includes a provided value.\n*\n* @name includes\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - search element\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {boolean} boolean indicating whether an array includes a provided value\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var bool = arr.includes( new Complex128( 3.0, -3.0 ) );\n* // returns true\n*\n* bool = arr.includes( new Complex128( 3.0, -3.0 ), 3 );\n* // returns false\n*\n* bool = arr.includes( new Complex128( 4.0, -4.0 ), -3 );\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'includes', function includes( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = real( searchElement );\n\tim = imag( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Returns the first index at which a given element can be found.\n*\n* @name indexOf\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var idx = arr.indexOf( new Complex128( 3.0, -3.0 ) );\n* // returns 2\n*\n* idx = arr.indexOf( new Complex128( 3.0, -3.0 ), 3 );\n* // returns -1\n*\n* idx = arr.indexOf( new Complex128( 4.0, -4.0 ), -3 );\n* // returns 3\n*/\nsetReadOnly( Complex128Array.prototype, 'indexOf', function indexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = real( searchElement );\n\tim = imag( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns a new string by concatenating all array elements.\n*\n* @name join\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {string} [separator=','] - element separator\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a string\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex128Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.join();\n* // returns '1 + 1i,2 + 2i'\n*\n* str = arr.join( '/' );\n* // returns '1 + 1i/2 + 2i'\n*/\nsetReadOnly( Complex128Array.prototype, 'join', function join( separator ) {\n\tvar out;\n\tvar buf;\n\tvar sep;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( arguments.length === 0 ) {\n\t\tsep = ',';\n\t} else if ( isString( separator ) ) {\n\t\tsep = separator;\n\t} else {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a string. Value: `%s`.', separator ) );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex128( buf, i ).toString() );\n\t}\n\treturn out.join( sep );\n});\n\n/**\n* Returns the last index at which a given element can be found.\n*\n* @name lastIndexOf\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex] - index at which to start searching backward (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 3.0, -3.0 ], 4 );\n*\n* var idx = arr.lastIndexOf( new Complex128( 3.0, -3.0 ) );\n* // returns 4\n*\n* idx = arr.lastIndexOf( new Complex128( 3.0, -3.0 ), 3 );\n* // returns 2\n*\n* idx = arr.lastIndexOf( new Complex128( 5.0, -5.0 ), 3 );\n* // returns -1\n*\n* idx = arr.lastIndexOf( new Complex128( 2.0, -2.0 ), -3 );\n* // returns 1\n*/\nsetReadOnly( Complex128Array.prototype, 'lastIndexOf', function lastIndexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex >= this._length ) {\n\t\t\tfromIndex = this._length - 1;\n\t\t} else if ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t}\n\t} else {\n\t\tfromIndex = this._length - 1;\n\t}\n\tre = real( searchElement );\n\tim = imag( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i >= 0; i-- ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns a new array with each element being the result of a provided callback function.\n*\n* @name map\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} fcn - callback function\n* @param {*} [thisArg] - callback function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex128Array} complex number array\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function scale( v, i ) {\n* return new Complex128( 2.0*real( v ), 2.0*imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.map( scale );\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 2.0\n*\n* var im = imag( z );\n* // returns -2.0\n*/\nsetReadOnly( Complex128Array.prototype, 'map', function map( fcn, thisArg ) {\n\tvar outbuf;\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar v;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tout = new this.constructor( this._length );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tv = fcn.call( thisArg, getComplex128( buf, i ), i, this );\n\t\tif ( isComplexLike( v ) ) {\n\t\t\toutbuf[ 2*i ] = real( v );\n\t\t\toutbuf[ (2*i)+1 ] = imag( v );\n\t\t} else if ( isArrayLikeObject( v ) && v.length === 2 ) {\n\t\t\toutbuf[ 2*i ] = v[ 0 ];\n\t\t\toutbuf[ (2*i)+1 ] = v[ 1 ];\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t}\n\t}\n\treturn out;\n});\n\n/**\n* Applies a provided callback function to each element of the array, in order, passing in the return value from the calculation on the preceding element and returning the accumulated result upon completion.\n*\n* @name reduce\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} reducer - callback function\n* @param {*} [initialValue] - initial value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @throws {Error} if not provided an initial value, the array must have at least one element\n* @returns {*} accumulated result\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n* import cadd from '@stdlib/math-base-ops-cadd';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.reduce( cadd );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 6.0\n*\n* var im = imag( z );\n* // returns 6.0\n*/\nsetReadOnly( Complex128Array.prototype, 'reduce', function reduce( reducer, initialValue ) {\n\tvar buf;\n\tvar acc;\n\tvar len;\n\tvar v;\n\tvar i;\n\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( reducer ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', reducer ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tacc = initialValue;\n\t\ti = 0;\n\t} else {\n\t\tif ( len === 0 ) {\n\t\t\tthrow new Error( 'invalid operation. If not provided an initial value, an array must contain at least one element.' );\n\t\t}\n\t\tacc = getComplex128( buf, 0 );\n\t\ti = 1;\n\t}\n\tfor ( ; i < len; i++ ) {\n\t\tv = getComplex128( buf, i );\n\t\tacc = reducer( acc, v, i, this );\n\t}\n\treturn acc;\n});\n\n/**\n* Reverses an array in-place.\n*\n* @name reverse\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} reversed array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.reverse();\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 3.0\n*\n* var im = imag( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'reverse', function reverse() {\n\tvar buf;\n\tvar tmp;\n\tvar len;\n\tvar N;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tbuf = this._buffer;\n\tN = floor( len / 2 );\n\tfor ( i = 0; i < N; i++ ) {\n\t\tj = len - i - 1;\n\t\ttmp = buf[ (2*i) ];\n\t\tbuf[ (2*i) ] = buf[ (2*j) ];\n\t\tbuf[ (2*j) ] = tmp;\n\t\ttmp = buf[ (2*i)+1 ];\n\t\tbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t\tbuf[ (2*j)+1 ] = tmp;\n\t}\n\treturn this;\n});\n\n/**\n* Sets an array element.\n*\n* ## Notes\n*\n* - When provided a typed array, real or complex, we must check whether the source array shares the same buffer as the target array and whether the underlying memory overlaps. In particular, we are concerned with the following scenario:\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* In the above, as we copy values from `src`, we will overwrite values in the `src` view, resulting in duplicated values copied into the end of `buf`, which is not intended. Hence, to avoid overwriting source values, we must **copy** source values to a temporary array.\n*\n* In the other overlapping scenario,\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* by the time we begin copying into the overlapping region, we are copying from the end of `src`, a non-overlapping region, which means we don't run the risk of copying copied values, rather than the original `src` values as intended.\n*\n* @name set\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {(Collection|Complex|ComplexArray)} value - value(s)\n* @param {NonNegativeInteger} [i=0] - element index at which to start writing values\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be either a complex number, an array-like object, or a complex number array\n* @throws {TypeError} index argument must be a nonnegative integer\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {RangeError} target array lacks sufficient storage to accommodate source values\n* @returns {void}\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 10 );\n*\n* var z = arr.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 0.0\n*\n* var im = imag( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns -1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'set', function set( value ) {\n\t/* eslint-disable no-underscore-dangle */\n\tvar sbuf;\n\tvar idx;\n\tvar buf;\n\tvar tmp;\n\tvar flg;\n\tvar N;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tif ( arguments.length > 1 ) {\n\t\tidx = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( idx ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Index argument must be a nonnegative integer. Value: `%s`.', idx ) );\n\t\t}\n\t} else {\n\t\tidx = 0;\n\t}\n\tif ( isComplexLike( value ) ) {\n\t\tif ( idx >= this._length ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%u`.', idx ) );\n\t\t}\n\t\tidx *= 2;\n\t\tbuf[ idx ] = real( value );\n\t\tbuf[ idx+1 ] = imag( value );\n\t\treturn;\n\t}\n\tif ( isComplexArray( value ) ) {\n\t\tN = value._length;\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tsbuf = value._buffer;\n\n\t\t// Check for overlapping memory...\n\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\tif (\n\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t(\n\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t)\n\t\t) {\n\t\t\t// We need to copy source values...\n\t\t\ttmp = new Float64Array( sbuf.length );\n\t\t\tfor ( i = 0; i < sbuf.length; i++ ) {\n\t\t\t\ttmp[ i ] = sbuf[ i ];\n\t\t\t}\n\t\t\tsbuf = tmp;\n\t\t}\n\t\tidx *= 2;\n\t\tj = 0;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\tidx += 2; // stride\n\t\t\tj += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tif ( isCollection( value ) ) {\n\t\t// Detect whether we've been provided an array of complex numbers...\n\t\tN = value.length;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tif ( !isComplexLike( value[ i ] ) ) {\n\t\t\t\tflg = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// If an array does not contain only complex numbers, then we assume interleaved real and imaginary components...\n\t\tif ( flg ) {\n\t\t\tif ( !isEven( N ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', N ) );\n\t\t\t}\n\t\t\tif ( idx+(N/2) > this._length ) {\n\t\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t\t}\n\t\t\tsbuf = value;\n\n\t\t\t// Check for overlapping memory...\n\t\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\t\tif (\n\t\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t\t(\n\t\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\t// We need to copy source values...\n\t\t\t\ttmp = new Float64Array( N );\n\t\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\t\ttmp[ i ] = sbuf[ i ];\n\t\t\t\t}\n\t\t\t\tsbuf = tmp;\n\t\t\t}\n\t\t\tidx *= 2;\n\t\t\tN /= 2;\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\t\tidx += 2; // stride\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t\t// If an array contains only complex numbers, then we need to extract real and imaginary components...\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tidx *= 2;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tv = value[ i ];\n\t\t\tbuf[ idx ] = real( v );\n\t\t\tbuf[ idx+1 ] = imag( v );\n\t\t\tidx += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.', value ) );\n\n\t/* eslint-enable no-underscore-dangle */\n});\n\n/**\n* Copies a portion of a typed array to a new typed array.\n*\n* @name slice\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex128Array} complex number array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var out = arr.slice();\n* // returns <Complex128Array>\n*\n* var len = out.length;\n* // returns 5\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns -1.0\n*\n* z = out.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 5.0\n*\n* im = imag( z );\n* // returns -5.0\n*\n* out = arr.slice( 1, -2 );\n* // returns <Complex128Array>\n*\n* len = out.length;\n* // returns 2\n*\n* z = out.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns -2.0\n*\n* z = out.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 3.0\n*\n* im = imag( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex128Array.prototype, 'slice', function slice( start, end ) {\n\tvar outlen;\n\tvar outbuf;\n\tvar out;\n\tvar idx;\n\tvar buf;\n\tvar len;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tstart = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( start < end ) {\n\t\toutlen = end - start;\n\t} else {\n\t\toutlen = 0;\n\t}\n\tout = new this.constructor( outlen );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < outlen; i++ ) {\n\t\tidx = 2*(i+start);\n\t\toutbuf[ 2*i ] = buf[ idx ];\n\t\toutbuf[ (2*i)+1 ] = buf[ idx+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Tests whether at least one element in an array passes a test implemented by a predicate function.\n*\n* @name some\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether at least one element passes a test\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var bool = arr.some( predicate );\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'some', function some( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( predicate.call( thisArg, getComplex128( buf, i ), i, this ) ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Creates a new typed array view over the same underlying `ArrayBuffer` and with the same underlying data type as the host array.\n*\n* @name subarray\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} [begin=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex64Array} subarray\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var subarr = arr.subarray();\n* // returns <Complex128Array>\n*\n* var len = subarr.length;\n* // returns 5\n*\n* var z = subarr.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns -1.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 5.0\n*\n* im = imag( z );\n* // returns -5.0\n*\n* subarr = arr.subarray( 1, -2 );\n* // returns <Complex128Array>\n*\n* len = subarr.length;\n* // returns 2\n*\n* z = subarr.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns -2.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 3.0\n*\n* im = imag( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex128Array.prototype, 'subarray', function subarray( begin, end ) {\n\tvar offset;\n\tvar buf;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tbegin = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( begin ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', begin ) );\n\t\t}\n\t\tif ( begin < 0 ) {\n\t\t\tbegin += len;\n\t\t\tif ( begin < 0 ) {\n\t\t\t\tbegin = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( begin >= len ) {\n\t\tlen = 0;\n\t\toffset = buf.byteLength;\n\t} else if ( begin >= end ) {\n\t\tlen = 0;\n\t\toffset = buf.byteOffset + ( begin*BYTES_PER_ELEMENT );\n\t} else {\n\t\tlen = end - begin;\n\t\toffset = buf.byteOffset + ( begin*BYTES_PER_ELEMENT );\n\t}\n\treturn new this.constructor( buf.buffer, offset, ( len < 0 ) ? 0 : len );\n});\n\n/**\n* Returns a new typed array containing the elements in reversed order.\n*\n* @name toReversed\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} reversed array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.toReversed();\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 3.0\n*\n* var im = imag( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'toReversed', function toReversed() {\n\tvar outbuf;\n\tvar out;\n\tvar len;\n\tvar buf;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tout = new this.constructor( len );\n\tbuf = this._buffer;\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < len; i++ ) {\n\t\tj = len - i - 1;\n\t\toutbuf[ (2*i) ] = buf[ (2*j) ];\n\t\toutbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Serializes an array as a string.\n*\n* @name toString\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex128Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.toString();\n* // returns '1 + 1i,2 + 2i'\n*/\nsetReadOnly( Complex128Array.prototype, 'toString', function toString() {\n\tvar out;\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex128( buf, i ).toString() );\n\t}\n\treturn out.join( ',' );\n});\n\n/**\n* Returns a new typed array with the element at a provided index replaced with a provided value.\n*\n* @name with\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} index - element index\n* @param {ComplexLike} value - new value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {TypeError} second argument must be a complex number\n* @returns {Complex128Array} new typed array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.with( 0, new Complex128( 4.0, 4.0 ) );\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 4.0\n*\n* var im = imag( z );\n* // returns 4.0\n*/\nsetReadOnly( Complex128Array.prototype, 'with', function copyWith( index, value ) {\n\tvar buf;\n\tvar out;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( index ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', index ) );\n\t}\n\tlen = this._length;\n\tif ( index < 0 ) {\n\t\tindex += len;\n\t}\n\tif ( index < 0 || index >= len ) {\n\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%s`.', index ) );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tout = new this.constructor( this._buffer );\n\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tbuf[ 2*index ] = real( value );\n\tbuf[ (2*index)+1 ] = imag( value );\n\treturn out;\n});\n\n\n// EXPORTS //\n\nexport default Complex128Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\n\n\n// MAIN //\n\n/**\n* Returns a strided array of real and imaginary components.\n*\n* @private\n* @param {Float64Array} buf - output array\n* @param {Array} arr - array containing complex numbers\n* @returns {(Float64Array|null)} output array or null\n*/\nfunction fromArray( buf, arr ) {\n\tvar len;\n\tvar v;\n\tvar i;\n\tvar j;\n\n\tlen = arr.length;\n\tj = 0;\n\tfor ( i = 0; i < len; i++ ) {\n\t\tv = arr[ i ];\n\t\tif ( !isComplexLike( v ) ) {\n\t\t\treturn null;\n\t\t}\n\t\tbuf[ j ] = real( v );\n\t\tbuf[ j+1 ] = imag( v );\n\t\tj += 2; // stride\n\t}\n\treturn buf;\n}\n\n\n// EXPORTS //\n\nexport default fromArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport format from '@stdlib/string-format';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @param {Function} clbk - callback to invoke for each iterated value\n* @param {*} thisArg - invocation context\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIteratorMap( it, clbk, thisArg ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\tvar i;\n\n\tout = [];\n\ti = -1;\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\ti += 1;\n\t\tz = clbk.call( thisArg, v.value, i );\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( real( z ), imag( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIteratorMap;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float64Array from '@stdlib/array-float64';\nimport Float32Array from '@stdlib/array-float32';\nimport Uint32Array from '@stdlib/array-uint32';\nimport Int32Array from '@stdlib/array-int32';\nimport Uint16Array from '@stdlib/array-uint16';\nimport Int16Array from '@stdlib/array-int16';\nimport Uint8Array from '@stdlib/array-uint8';\nimport Uint8ClampedArray from '@stdlib/array-uint8c';\nimport Int8Array from '@stdlib/array-int8';\nimport Complex64Array from '@stdlib/array-complex64';\nimport Complex128Array from '@stdlib/array-complex128';\n\n\n// MAIN //\n\n// Note: order should match `dtypes` order\nvar CTORS = [\n\tFloat64Array,\n\tFloat32Array,\n\tInt32Array,\n\tUint32Array,\n\tInt16Array,\n\tUint16Array,\n\tInt8Array,\n\tUint8Array,\n\tUint8ClampedArray,\n\tComplex64Array,\n\tComplex128Array\n];\n\n\n// EXPORTS //\n\nexport default CTORS;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n// Note: order should match `ctors` order\nvar DTYPES = [\n\t'float64',\n\t'float32',\n\t'int32',\n\t'uint32',\n\t'int16',\n\t'uint16',\n\t'int8',\n\t'uint8',\n\t'uint8c',\n\t'complex64',\n\t'complex128'\n];\n\n\n// EXPORTS //\n\nexport default DTYPES;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isBuffer from '@stdlib/assert-is-buffer';\nimport isArray from '@stdlib/assert-is-array';\nimport constructorName from '@stdlib/utils-constructor-name';\nimport ctor2dtype from './ctor2dtype.js';\nimport CTORS from './ctors.js';\nimport DTYPES from './dtypes.js';\n\n\n// VARIABLES //\n\nvar NTYPES = DTYPES.length;\n\n\n// MAIN //\n\n/**\n* Returns the data type of an array.\n*\n* @param {*} value - input value\n* @returns {(string|null)} data type\n*\n* @example\n* var dt = dtype( [ 1, 2, 3 ] );\n* // returns 'generic'\n*\n* var dt = dtype( 'beep' );\n* // returns null\n*/\nfunction dtype( value ) {\n\tvar i;\n\tif ( isArray( value ) ) {\n\t\treturn 'generic';\n\t}\n\tif ( isBuffer( value ) ) {\n\t\treturn null;\n\t}\n\tfor ( i = 0; i < NTYPES; i++ ) {\n\t\tif ( value instanceof CTORS[ i ] ) {\n\t\t\treturn DTYPES[ i ];\n\t\t}\n\t}\n\t// If the above failed, fall back to a more robust (and significantly slower) means for resolving underlying data types:\n\treturn ctor2dtype[ constructorName( value ) ] || null;\n}\n\n\n// EXPORTS //\n\nexport default dtype;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2023 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isAccessorArray from '@stdlib/array-base-assert-is-accessor-array';\nimport accessorGetter from '@stdlib/array-base-accessor-getter';\nimport getter from '@stdlib/array-base-getter';\nimport dtype from '@stdlib/array-dtype';\n\n\n// MAIN //\n\n/**\n* Returns an accessor function for retrieving an element from an array-like object.\n*\n* @param {Collection} x - input array\n* @returns {Function} accessor\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var get = resolveGetter( arr );\n* var v = get( arr, 2 );\n* // returns 3\n*/\nfunction resolveGetter( x ) {\n\tvar dt = dtype( x );\n\tif ( isAccessorArray( x ) ) {\n\t\treturn accessorGetter( dt );\n\t}\n\treturn getter( dt );\n}\n\n\n// EXPORTS //\n\nexport default resolveGetter;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2023 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\nimport format from '@stdlib/error-tools-fmtprodmsg';\n\n// MODULES //\n\nimport isArray from '@stdlib/assert-is-array';\n\nimport resolveGetter from '@stdlib/array-base-resolve-getter';\n\n// MAIN //\n\n/**\n* Groups element entries as arrays associated with distinct keys.\n*\n* @param {Collection} x - input array\n* @param {Collection} groups - array defining which group an element in the input array belongs to\n* @throws {RangeError} must provide arrays having the same length\n* @returns {Object} group results\n*\n* @example\n* var x = [ 'beep', 'boop', 'foo', 'bar' ];\n* var groups = [ 'b', 'b', 'f', 'b' ];\n*\n* var out = groupEntries( x, groups );\n* // returns { 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], 'f': [ [ 2, 'foo' ] ] }\n*/\nfunction groupEntries( x, groups ) {\n\tvar xget;\n\tvar gget;\n\tvar len;\n\tvar out;\n\tvar g;\n\tvar o;\n\tvar v;\n\tvar i;\n\n\t// Get the number of elements to group:\n\tlen = x.length;\n\tif ( groups.length !== len ) {\n\t\tthrow new RangeError( format('1nHFI') );\n\t}\n\t// Resolve accessors for retrieving array elements:\n\txget = resolveGetter( x );\n\tgget = resolveGetter( groups );\n\n\t// Loop over the elements and assign each to a group...\n\tout = {};\n\tfor ( i = 0; i < len; i++ ) {\n\t\tv = xget( x, i );\n\t\tg = gget( groups, i ).toString();\n\t\to = out[ g ];\n\t\tif ( isArray( o ) ) {\n\t\t\to.push( [ i, v ] );\n\t\t} else {\n\t\t\tout[ g ] = [ [ i, v ] ];\n\t\t}\n\t}\n\treturn out;\n}\n\n// EXPORTS //\n\nexport default groupEntries;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Formats an error message for production.\n*\n* @param {string} code - error code\n* @param {*} ...args - error message arguments\n* @returns {string} formatted error message\n*\n* @example\n* var msg = fmtprodmsg( '3', 'wrong_type' );\n* // returns 'https://stdlib.io/e/3?&arg[]=wrong_type'\n*/\nfunction fmtprodmsg() {\n\tvar a = arguments;\n\tvar c = a[ 0 ];\n\tvar u = 'https://stdlib.io/e/'+c+'?';\n\tvar i;\n\tfor ( i = 1; i < a.length; i++ ) {\n\t\tu += '&arg[]=' + encodeURIComponent( a[ i ] );\n\t}\n\treturn u;\n}\n\n\n// EXPORTS //\n\nexport default fmtprodmsg;\n"],"names":["FLG","Symbol","hasToStringTagSupport","toStringTag","toStr","Object","prototype","toString","has","hasOwnProperty","hasOwnProp","value","property","call","Sym","toStrTag","nativeClass","hasToStringTag","v","isOwn","tag","out","err","main$c","Array","isArray","TYPE","GETTERS","complex128","arr","idx","get","complex64","default","getter","dtype","f","float64","float32","int32","int16","int8","uint32","uint16","uint8","uint8c","generic","main","defineProperty","isNumber","zeros","n","i","zeroPad","str","width","right","negative","pad","length","startsWithMinus","substr","lowercase","String","toLowerCase","uppercase","toUpperCase","formatInteger","token","base","specifier","arg","parseInt","isFinite","Error","precision","padRight","sign","alternate","charAt","abs","Math","replace","RE_EXP_POS_DIGITS","RE_EXP_NEG_DIGITS","RE_ONLY_DIGITS","RE_DIGITS_BEFORE_EXP","RE_TRAILING_PERIOD_ZERO","RE_PERIOD_ZERO_EXP","RE_ZERO_BEFORE_EXP","formatDouble","digits","parseFloat","toExponential","toFixed","toPrecision","spaces","fromCharCode","isnan","initialize","flags","mapping","formatInterpolate","tokens","hasPeriod","flag","num","pos","j","TypeError","padZeros","indexOf","arguments","maxWidth","substring","RE","parse","match","formatTokenize","content","prev","exec","slice","lastIndex","push","format","args","tokenize","interpolate","apply","objectProtoype","defineGetter","__defineGetter__","defineSetter","__defineSetter__","lookupGetter","__lookupGetter__","lookupSetter","__lookupSetter__","hasDefinePropertySupport","builtin","obj","prop","descriptor","hasValue","hasGet","hasSet","__proto__","set","defineProperty$1","setNonEnumerableReadOnly","configurable","enumerable","writable","isObjectLike","isBuffer","_isBuffer","constructor","reFunctionName","setReadOnly","predicate","len","arrayfun","RE_FUNCTION_NAME","constructorName","name","ctor","REGEXP","ctor2dtypes","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray","Complex64Array","Complex128Array","hasFloat64Array","Float64Array$1","bool","GlobalFloat64Array","NaN","hasFloat64ArraySupport","hasFloat32Array","FLOAT64_PINF","Number","POSITIVE_INFINITY","Float32Array$1","GlobalFloat32Array","PINF","hasFloat32ArraySupport","hasUint32Array","Uint32Array$1","GlobalUint32Array","UINT32_MAX","hasUint32ArraySupport","hasInt32Array","Int32Array$1","GlobalInt32Array","INT32_MAX","hasInt32ArraySupport","hasUint16Array","Uint16Array$1","GlobalUint16Array","UINT16_MAX","hasUint16ArraySupport","hasInt16Array","Int16Array$1","GlobalInt16Array","INT16_MAX","hasInt16ArraySupport","hasUint8Array","Uint8Array$1","GlobalUint8Array","UINT8_MAX","hasUint8ArraySupport","hasUint8ClampedArray","Uint8ClampedArray$1","GlobalUint8ClampedArray","hasUint8ClampedArraySupport","hasInt8Array","Int8Array$1","GlobalInt8Array","INT8_MAX","hasInt8ArraySupport","main$1","test","isPrimitive","isObject","FLOAT64_NINF","NEGATIVE_INFINITY","floor","isInteger","x","NINF","isInt","valueOf","isNonNegativeInteger","MAX_ARRAY_LENGTH","isArrayLikeObject","MAX_LENGTH","MAX_TYPED_ARRAY_LENGTH","isCollection","hasArrayBuffer","ArrayBuffer","isArrayBuffer","isString","isBoolean","Bool","Boolean","self","window","globalThis","root","codegen","Function","GlobalThis","Self","Win","getGlobal","nodeList","document","childNodes","typedarray","ctorName","type","isFunction","typeOf","Complex128","real","imag","this","re","im","fround","FLOAT32_VIEW","float64ToFloat32$1","Complex64","float64ToFloat32","isComplexLike","isEven","BYTES_PER_ELEMENT","isComplex64Array","isComplex128Array","hasIteratorSymbolSupport","iterator","IteratorSymbol","setNonEnumerableReadOnlyAccessor","realf","z","imagf","reinterpret","offset","buffer","byteOffset","fromIterator","it","next","done","HAS_ITERATOR_SYMBOL","isComplexArray","_length","_buffer","isComplexArrayConstructor","getComplex64","buf","nargs","fromArray","RangeError","reinterpret64","reinterpret128","byteLength","ITERATOR_SYMBOL","src","thisArg","clbk","tmp","flg","accessorGetter","fromIteratorMap","target","start","copyWithin","iter","entries","end","fcn","searchElement","fromIndex","separator","sep","join","outbuf","reducer","initialValue","acc","N","sbuf","outlen","begin","index","getComplex128","CTORS","DTYPES","NTYPES","resolveGetter","dt","ctor2dtype","groups","xget","gget","g","o","a","u","encodeURIComponent"],"mappings":";yCA2BA,IAAIA,ECMgB,mBAAXC,QACoB,iBAApBA,OAAQ,ODOjB,SAASC,IACR,OAASF,GAAqC,iBAAvBC,OAAOE,WAC/B,CErBA,IAAIC,EAAQC,OAAOC,UAAUC,SCAzBC,EAAMH,OAAOC,UAAUG,eA4B3B,SAASC,EAAYC,EAAOC,GAC3B,OACCD,SAKMH,EAAIK,KAAMF,EAAOC,EACzB,CCpCA,IAAIE,EAA0B,mBAAXb,OAA0BA,YAAS,ECKlDc,EAA+B,mBAAXd,EAA0BA,EAAOE,YAAc,GCiCvEa,EATKC,ICDL,SAAsBC,GACrB,IAAIC,EACAC,EACAC,EAEJ,GAAKH,QACJ,OAAOd,EAAMS,KAAMK,GAEpBE,EAAMF,EAAGf,GACTgB,EAAQT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AEjC,IAAMhT,EAAI,EAAGA,EAAIgT,EAAEzS,OAAQP,IAC1BiT,GAAK,UAAYC,mBAAoBF,EAAGhT,IAEzC,OAAOiT,CACR,CDgBwBxO,CAAO,UAQ9B,IALAmO,EAAOJ,GAAehH,GACtBqH,EAAOL,GAAeG,GAGtB1U,EAAM,CAAA,EACA+B,EAAI,EAAGA,EAAI6G,EAAK7G,IACrBlC,EAAI8U,EAAMpH,EAAGxL,GAEb+S,EAAI9U,EADJ6U,EAAID,EAAMF,EAAQ3S,GAAI7C,YAEjBkB,EAAS0U,GACbA,EAAEvO,KAAM,CAAExE,EAAGlC,IAEbG,EAAK6U,GAAM,CAAE,CAAE9S,EAAGlC,IAGpB,OAAOG,CACR","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,188]} \ No newline at end of file diff --git a/dist/index.d.ts b/dist/index.d.ts deleted file mode 100644 index abee466..0000000 --- a/dist/index.d.ts +++ /dev/null @@ -1,3 +0,0 @@ -/// <reference path="../docs/types/index.d.ts" /> -import groupEntries from '../docs/types/index'; -export = groupEntries; \ No newline at end of file diff --git a/dist/index.js b/dist/index.js deleted file mode 100644 index 6dd3b60..0000000 --- a/dist/index.js +++ /dev/null @@ -1,19 +0,0 @@ -"use strict";var f=function(t,r){return function(){return r||t((r={exports:{}}).exports,r),r.exports}};var l=f(function(p,h){"use strict";var m=require("@stdlib/assert-is-array"),o=require("@stdlib/array-base-resolve-getter");function c(t,r){var u,g,n,a,i,v,s,e;if(n=t.length,r.length!==n)throw new RangeError("invalid argument. The first and second arguments must have the same length.");for(u=o(t),g=o(r),a={},e=0;e<n;e++)s=u(t,e),i=g(r,e).toString(),v=a[i],m(v)?v.push([e,s]):a[i]=[[e,s]];return a}h.exports=c});var d=l();module.exports=d; -/** -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ -//# sourceMappingURL=index.js.map diff --git a/dist/index.js.map b/dist/index.js.map deleted file mode 100644 index 2287cca..0000000 --- a/dist/index.js.map +++ /dev/null @@ -1,7 +0,0 @@ -{ - "version": 3, - "sources": ["../lib/main.js", "../lib/index.js"], - "sourcesContent": ["/**\n* @license Apache-2.0\n*\n* Copyright (c) 2023 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar isArray = require( '@stdlib/assert-is-array' );\nvar resolveGetter = require( '@stdlib/array-base-resolve-getter' );\n\n\n// MAIN //\n\n/**\n* Groups element entries as arrays associated with distinct keys.\n*\n* @param {Collection} x - input array\n* @param {Collection} groups - array defining which group an element in the input array belongs to\n* @throws {RangeError} must provide arrays having the same length\n* @returns {Object} group results\n*\n* @example\n* var x = [ 'beep', 'boop', 'foo', 'bar' ];\n* var groups = [ 'b', 'b', 'f', 'b' ];\n*\n* var out = groupEntries( x, groups );\n* // returns { 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], 'f': [ [ 2, 'foo' ] ] }\n*/\nfunction groupEntries( x, groups ) {\n\tvar xget;\n\tvar gget;\n\tvar len;\n\tvar out;\n\tvar g;\n\tvar o;\n\tvar v;\n\tvar i;\n\n\t// Get the number of elements to group:\n\tlen = x.length;\n\tif ( groups.length !== len ) {\n\t\tthrow new RangeError( 'invalid argument. The first and second arguments must have the same length.' );\n\t}\n\t// Resolve accessors for retrieving array elements:\n\txget = resolveGetter( x );\n\tgget = resolveGetter( groups );\n\n\t// Loop over the elements and assign each to a group...\n\tout = {};\n\tfor ( i = 0; i < len; i++ ) {\n\t\tv = xget( x, i );\n\t\tg = gget( groups, i ).toString();\n\t\to = out[ g ];\n\t\tif ( isArray( o ) ) {\n\t\t\to.push( [ i, v ] );\n\t\t} else {\n\t\t\tout[ g ] = [ [ i, v ] ];\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nmodule.exports = groupEntries;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2023 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Group element entries as arrays associated with distinct keys.\n*\n* @module @stdlib/array-base-group-entries\n*\n* @example\n* var groupEntries = require( '@stdlib/array-base-group-entries' );\n*\n* var x = [ 'beep', 'boop', 'foo', 'bar' ];\n* var groups = [ 'b', 'b', 'f', 'b' ];\n*\n* var out = groupEntries( x, groups );\n* // returns { 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], 'f': [ [ 2, 'foo' ] ] }\n*/\n\n// MODULES //\n\nvar main = require( './main.js' );\n\n\n// EXPORTS //\n\nmodule.exports = main;\n"], - "mappings": "uGAAA,IAAAA,EAAAC,EAAA,SAAAC,EAAAC,EAAA,cAsBA,IAAIC,EAAU,QAAS,yBAA0B,EAC7CC,EAAgB,QAAS,mCAAoC,EAoBjE,SAASC,EAAcC,EAAGC,EAAS,CAClC,IAAIC,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EAIJ,GADAL,EAAMJ,EAAE,OACHC,EAAO,SAAWG,EACtB,MAAM,IAAI,WAAY,6EAA8E,EAQrG,IALAF,EAAOJ,EAAeE,CAAE,EACxBG,EAAOL,EAAeG,CAAO,EAG7BI,EAAM,CAAC,EACDI,EAAI,EAAGA,EAAIL,EAAKK,IACrBD,EAAIN,EAAMF,EAAGS,CAAE,EACfH,EAAIH,EAAMF,EAAQQ,CAAE,EAAE,SAAS,EAC/BF,EAAIF,EAAKC,CAAE,EACNT,EAASU,CAAE,EACfA,EAAE,KAAM,CAAEE,EAAGD,CAAE,CAAE,EAEjBH,EAAKC,CAAE,EAAI,CAAE,CAAEG,EAAGD,CAAE,CAAE,EAGxB,OAAOH,CACR,CAKAT,EAAO,QAAUG,IC3CjB,IAAIW,EAAO,IAKX,OAAO,QAAUA", - "names": ["require_main", "__commonJSMin", "exports", "module", "isArray", "resolveGetter", "groupEntries", "x", "groups", "xget", "gget", "len", "out", "g", "o", "v", "i", "main"] -} diff --git a/docs/repl.txt b/docs/repl.txt deleted file mode 100644 index bf36658..0000000 --- a/docs/repl.txt +++ /dev/null @@ -1,34 +0,0 @@ - -{{alias}}( x, groups ) - Groups element entries as arrays associated with distinct keys. - - If provided an empty array, the function returns an empty object. - - Parameters - ---------- - x: ArrayLike - Input array. - - groups: ArrayLike - An array defining which group an element in the input array belongs to. - Each value in `groups` should resolve to a value which can be serialized - as an object key. - - Returns - ------- - out: Object - Group results. - - Examples - -------- - > var x = [ 'beep', 'boop', 'foo', 'bar' ]; - > var g = [ 'b', 'b', 'f', 'b' ]; - > var out = {{alias}}( x, g ) - { 'b': [ [0,'beep'], [1,'boop'], [3,'bar'] ], 'f': [ [2,'foo'] ] } - > g = [ 1, 1, 2, 1 ]; - > out = {{alias}}( x, g ) - { '1': [ [0,'beep'], [1,'boop'], [3,'bar'] ], '2': [ [2,'foo'] ] } - - See Also - -------- - diff --git a/docs/types/index.d.ts b/docs/types/index.d.ts deleted file mode 100644 index 08ca886..0000000 --- a/docs/types/index.d.ts +++ /dev/null @@ -1,59 +0,0 @@ -/* -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -// TypeScript Version: 4.1 - -/// <reference types="@stdlib/types"/> - -import { Collection, AccessorArrayLike } from '@stdlib/types/array'; - -/** -* Object key. -*/ -type Key = string | symbol | number; - -/** -* Interface describing returned group results. -*/ -interface EntriesResults<T> { - /** - * Object properties. - */ - [key: Key]: Array<[ number, T ]>; -} - -/** -* Groups element entries as arrays associated with distinct keys. -* -* @param x - input array -* @param groups - array defining which group an element in the input array belongs to -* @returns group results -* -* @example -* var x = [ 'beep', 'boop', 'foo', 'bar' ]; -* var groups = [ 'b', 'b', 'f', 'b' ]; -* -* var out = groupEntries( x, groups ); -* // returns { 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], 'f': [ [ 2, 'foo' ] ] } -*/ -declare function groupEntries<T = unknown>( x: Collection<T> | AccessorArrayLike<T>, groups: Collection<Key> | AccessorArrayLike<Key> ): EntriesResults<T>; - - -// EXPORTS // - -export = groupEntries; diff --git a/docs/types/test.ts b/docs/types/test.ts deleted file mode 100644 index 3b7fec6..0000000 --- a/docs/types/test.ts +++ /dev/null @@ -1,66 +0,0 @@ -/* -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -import groupEntries = require( './index' ); - - -// TESTS // - -// The function returns group results... -{ - const x = [ 1, 2, 3 ]; - const g = [ 0, 0, 0 ]; - - groupEntries( x, g ); // $ExpectType EntriesResults<Key, number> -} - -// The compiler throws an error if the function is provided a first argument which is not an array... -{ - const g = [ 0, 0, 0 ]; - - groupEntries( 5, g ); // $ExpectError - groupEntries( true, g ); // $ExpectError - groupEntries( false, g ); // $ExpectError - groupEntries( null, g ); // $ExpectError - groupEntries( void 0, g ); // $ExpectError - groupEntries( {}, g ); // $ExpectError - groupEntries( ( x: number ): number => x, g ); // $ExpectError -} - -// The compiler throws an error if the function is provided a second argument which is not an array... -{ - const x = [ 1, 2, 3 ]; - - groupEntries( x, 5 ); // $ExpectError - groupEntries( x, true ); // $ExpectError - groupEntries( x, false ); // $ExpectError - groupEntries( x, null ); // $ExpectError - groupEntries( x, void 0 ); // $ExpectError - groupEntries( x, {} ); // $ExpectError - groupEntries( x, ( x: number ): number => x ); // $ExpectError -} - -// The compiler throws an error if the function is provided an unsupported number of arguments... -{ - const x = [ 1, 2, 3 ]; - const g = [ 0, 0, 0 ]; - - groupEntries(); // $ExpectError - groupEntries( x ); // $ExpectError - groupEntries( x, g, {} ); // $ExpectError -} diff --git a/examples/index.js b/examples/index.js deleted file mode 100644 index 9f5dd36..0000000 --- a/examples/index.js +++ /dev/null @@ -1,44 +0,0 @@ -/** -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -'use strict'; - -var discreteUniform = require( '@stdlib/random-array-discrete-uniform' ); -var take = require( '@stdlib/array-base-take-indexed' ); -var groupEntries = require( './../lib' ); - -// Define an initial array of values: -var values = [ 'beep', 'boop', 'foo', 'bar', 'woot', 'woot' ]; - -// Sample from the initial array to generate a random collection: -var indices = discreteUniform( 100, 0, values.length-1, { - 'dtype': 'generic' -}); -var x = take( values, indices ); -// returns [...] - -// Randomly assign collection values to groups: -var groups = discreteUniform( x.length, 0, values.length, { - 'dtype': 'generic' -}); - -// Group the values: -var out = groupEntries( x, groups ); -// returns {...} - -console.log( out ); diff --git a/index.js b/index.js new file mode 100644 index 0000000..280a2c0 --- /dev/null +++ b/index.js @@ -0,0 +1,3 @@ +// Copyright (c) 2025 The Stdlib Authors. License is Apache-2.0: http://www.apache.org/licenses/LICENSE-2.0 +!function(r,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(r="undefined"!=typeof globalThis?globalThis:r||self).groupEntries=e()}(this,(function(){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol("foo");function e(){return r&&"symbol"==typeof Symbol.toStringTag}var t=Object.prototype.toString;var n=Object.prototype.hasOwnProperty;function i(r,e){return null!=r&&n.call(r,e)}var o="function"==typeof Symbol?Symbol:void 0,a="function"==typeof o?o.toStringTag:"";var u=e()?function(r){var e,n,o;if(null==r)return t.call(r);n=r[a],e=i(r,a);try{r[a]=void 0}catch(e){return t.call(r)}return o=t.call(r),e?r[a]=n:delete r[a],o}:function(r){return t.call(r)};var f=Array.isArray?Array.isArray:function(r){return"[object Array]"===u(r)},l="function";var s={complex128:function(r,e){return r.get(e)},complex64:function(r,e){return r.get(e)},default:function(r,e){return r.get(e)}};function h(r){var e=s[r];return"function"==typeof e?e:s.default}var c={float64:function(r,e){return r[e]},float32:function(r,e){return r[e]},int32:function(r,e){return r[e]},int16:function(r,e){return r[e]},int8:function(r,e){return r[e]},uint32:function(r,e){return r[e]},uint16:function(r,e){return r[e]},uint8:function(r,e){return r[e]},uint8c:function(r,e){return r[e]},generic:function(r,e){return r[e]},default:function(r,e){return r[e]}};function p(r){var e=c[r];return"function"==typeof e?e:c.default}var m="function"==typeof Object.defineProperty?Object.defineProperty:null;var y=Object.defineProperty;function g(r){return"number"==typeof r}function w(r){var e,t="";for(e=0;e<r;e++)t+="0";return t}function v(r,e,t){var n=!1,i=e-r.length;return i<0||(function(r){return"-"===r[0]}(r)&&(n=!0,r=r.substr(1)),r=t?r+w(i):w(i)+r,n&&(r="-"+r)),r}var b=String.prototype.toLowerCase,d=String.prototype.toUpperCase;function E(r){var e,t,n;switch(r.specifier){case"b":e=2;break;case"o":e=8;break;case"x":case"X":e=16;break;default:e=10}if(t=r.arg,n=parseInt(t,10),!isFinite(n)){if(!g(t))throw new Error("invalid integer. Value: "+t);n=0}return n<0&&("u"===r.specifier||10!==e)&&(n=4294967295+n+1),n<0?(t=(-n).toString(e),r.precision&&(t=v(t,r.precision,r.padRight)),t="-"+t):(t=n.toString(e),n||r.precision?r.precision&&(t=v(t,r.precision,r.padRight)):t="",r.sign&&(t=r.sign+t)),16===e&&(r.alternate&&(t="0x"+t),t=r.specifier===d.call(r.specifier)?d.call(t):b.call(t)),8===e&&r.alternate&&"0"!==t.charAt(0)&&(t="0"+t),t}var _=Math.abs,T=String.prototype.toLowerCase,x=String.prototype.toUpperCase,A=String.prototype.replace,V=/e\+(\d)$/,S=/e-(\d)$/,j=/^(\d+)$/,F=/^(\d+)e/,k=/\.0$/,I=/\.0*e/,L=/(\..*[^0])0*e/;function R(r){var e,t,n=parseFloat(r.arg);if(!isFinite(n)){if(!g(r.arg))throw new Error("invalid floating-point number. Value: "+t);n=r.arg}switch(r.specifier){case"e":case"E":t=n.toExponential(r.precision);break;case"f":case"F":t=n.toFixed(r.precision);break;case"g":case"G":_(n)<1e-4?((e=r.precision)>0&&(e-=1),t=n.toExponential(e)):t=n.toPrecision(r.precision),r.alternate||(t=A.call(t,L,"$1e"),t=A.call(t,I,"e"),t=A.call(t,k,""));break;default:throw new Error("invalid double notation. Value: "+r.specifier)}return t=A.call(t,V,"e+0$1"),t=A.call(t,S,"e-0$1"),r.alternate&&(t=A.call(t,j,"$1."),t=A.call(t,F,"$1.e")),n>=0&&r.sign&&(t=r.sign+t),t=r.specifier===x.call(r.specifier)?x.call(t):T.call(t)}function B(r){var e,t="";for(e=0;e<r;e++)t+=" ";return t}var O=String.fromCharCode,C=Array.isArray;function M(r){return r!=r}function U(r){var e={};return e.specifier=r.specifier,e.precision=void 0===r.precision?1:r.precision,e.width=r.width,e.flags=r.flags||"",e.mapping=r.mapping,e}function N(r){var e,t,n,i,o,a,u,f,l,s,h,c,p;if(!C(r))throw new TypeError("invalid argument. First argument must be an array. Value: `"+r+"`.");for(a="",u=1,f=0;f<r.length;f++)if(n=r[f],"string"==typeof n)a+=n;else{if(e=void 0!==n.precision,!(n=U(n)).specifier)throw new TypeError("invalid argument. Token is missing `specifier` property. Index: `"+f+"`. Value: `"+n+"`.");for(n.mapping&&(u=n.mapping),t=n.flags,l=0;l<t.length;l++)switch(i=t.charAt(l)){case" ":n.sign=" ";break;case"+":n.sign="+";break;case"-":n.padRight=!0,n.padZeros=!1;break;case"0":n.padZeros=t.indexOf("-")<0;break;case"#":n.alternate=!0;break;default:throw new Error("invalid flag: "+i)}if("*"===n.width){if(n.width=parseInt(arguments[u],10),u+=1,M(n.width))throw new TypeError("the argument for * width at position "+u+" is not a number. Value: `"+n.width+"`.");n.width<0&&(n.padRight=!0,n.width=-n.width)}if(e&&"*"===n.precision){if(n.precision=parseInt(arguments[u],10),u+=1,M(n.precision))throw new TypeError("the argument for * precision at position "+u+" is not a number. Value: `"+n.precision+"`.");n.precision<0&&(n.precision=1,e=!1)}switch(n.arg=arguments[u],n.specifier){case"b":case"o":case"x":case"X":case"d":case"i":case"u":e&&(n.padZeros=!1),n.arg=E(n);break;case"s":n.maxWidth=e?n.precision:-1,n.arg=String(n.arg);break;case"c":if(!M(n.arg)){if((o=parseInt(n.arg,10))<0||o>127)throw new Error("invalid character code. Value: "+n.arg);n.arg=M(o)?String(n.arg):O(o)}break;case"e":case"E":case"f":case"F":case"g":case"G":e||(n.precision=6),n.arg=R(n);break;default:throw new Error("invalid specifier: "+n.specifier)}n.maxWidth>=0&&n.arg.length>n.maxWidth&&(n.arg=n.arg.substring(0,n.maxWidth)),n.padZeros?n.arg=v(n.arg,n.width||n.precision,n.padRight):n.width&&(n.arg=(s=n.arg,h=n.width,c=n.padRight,p=void 0,(p=h-s.length)<0?s:s=c?s+B(p):B(p)+s)),a+=n.arg||"",u+=1}return a}var P=/%(?:([1-9]\d*)\$)?([0 +\-#]*)(\*|\d+)?(?:(\.)(\*|\d+)?)?[hlL]?([%A-Za-z])/g;function Y(r){var e={mapping:r[1]?parseInt(r[1],10):void 0,flags:r[2],width:r[3],precision:r[5],specifier:r[6]};return"."===r[4]&&void 0===r[5]&&(e.precision="1"),e}function W(r){var e,t,n,i;for(t=[],i=0,n=P.exec(r);n;)(e=r.slice(i,P.lastIndex-n[0].length)).length&&t.push(e),t.push(Y(n)),i=P.lastIndex,n=P.exec(r);return(e=r.slice(i)).length&&t.push(e),t}function $(r){var e,t;if("string"!=typeof r)throw new TypeError($("invalid argument. First argument must be a string. Value: `%s`.",r));for(e=[W(r)],t=1;t<arguments.length;t++)e.push(arguments[t]);return N.apply(null,e)}var G,Z=Object.prototype,J=Z.toString,X=Z.__defineGetter__,z=Z.__defineSetter__,H=Z.__lookupGetter__,q=Z.__lookupSetter__;G=function(){try{return m({},"x",{}),!0}catch(r){return!1}}()?y:function(r,e,t){var n,i,o,a;if("object"!=typeof r||null===r||"[object Array]"===J.call(r))throw new TypeError($("invalid argument. First argument must be an object. Value: `%s`.",r));if("object"!=typeof t||null===t||"[object Array]"===J.call(t))throw new TypeError($("invalid argument. Property descriptor must be an object. Value: `%s`.",t));if((i="value"in t)&&(H.call(r,e)||q.call(r,e)?(n=r.__proto__,r.__proto__=Z,delete r[e],r[e]=t.value,r.__proto__=n):r[e]=t.value),o="get"in t,a="set"in t,i&&(o||a))throw new Error("invalid argument. Cannot specify one or more accessors and a value or writable attribute in the property descriptor.");return o&&X&&X.call(r,e,t.get),a&&z&&z.call(r,e,t.set),r};var D=G;function K(r,e,t){D(r,e,{configurable:!1,enumerable:!1,writable:!1,value:t})}function Q(r){return null!==r&&"object"==typeof r}function rr(r){return Q(r)&&(r._isBuffer||r.constructor&&"function"==typeof r.constructor.isBuffer&&r.constructor.isBuffer(r))}function er(){return/^\s*function\s*([^(]*)/i}K(Q,"isObjectLikeArray",function(r){if("function"!=typeof r)throw new TypeError($("invalid argument. Must provide a function. Value: `%s`.",r));return function(e){var t,n;if(!f(e))return!1;if(0===(t=e.length))return!1;for(n=0;n<t;n++)if(!1===r(e[n]))return!1;return!0}}(Q));var tr=/^\s*function\s*([^(]*)/i;function nr(r){var e,t,n;if(("Object"===(t=u(r).slice(8,-1))||"Error"===t)&&r.constructor){if("string"==typeof(n=r.constructor).name)return n.name;if(e=tr.exec(n.toString()))return e[1]}return rr(r)?"Buffer":t}K(er,"REGEXP",tr);var ir={Float32Array:"float32",Float64Array:"float64",Array:"generic",Int16Array:"int16",Int32Array:"int32",Int8Array:"int8",Uint16Array:"uint16",Uint32Array:"uint32",Uint8Array:"uint8",Uint8ClampedArray:"uint8c",Complex64Array:"complex64",Complex128Array:"complex128"},or="function"==typeof Float64Array;var ar="function"==typeof Float64Array?Float64Array:null;var ur="function"==typeof Float64Array?Float64Array:void 0;var fr=function(){var r,e,t;if("function"!=typeof ar)return!1;try{e=new ar([1,3.14,-3.14,NaN]),t=e,r=(or&&t instanceof Float64Array||"[object Float64Array]"===u(t))&&1===e[0]&&3.14===e[1]&&-3.14===e[2]&&e[3]!=e[3]}catch(e){r=!1}return r}()?ur:function(){throw new Error("not implemented")},lr="function"==typeof Float32Array;var sr=Number.POSITIVE_INFINITY,hr="function"==typeof Float32Array?Float32Array:null;var cr="function"==typeof Float32Array?Float32Array:void 0;var pr=function(){var r,e,t;if("function"!=typeof hr)return!1;try{e=new hr([1,3.14,-3.14,5e40]),t=e,r=(lr&&t instanceof Float32Array||"[object Float32Array]"===u(t))&&1===e[0]&&3.140000104904175===e[1]&&-3.140000104904175===e[2]&&e[3]===sr}catch(e){r=!1}return r}()?cr:function(){throw new Error("not implemented")},mr="function"==typeof Uint32Array;var yr="function"==typeof Uint32Array?Uint32Array:null;var gr="function"==typeof Uint32Array?Uint32Array:void 0;var wr=function(){var r,e,t;if("function"!=typeof yr)return!1;try{e=new yr(e=[1,3.14,-3.14,4294967296,4294967297]),t=e,r=(mr&&t instanceof Uint32Array||"[object Uint32Array]"===u(t))&&1===e[0]&&3===e[1]&&4294967293===e[2]&&0===e[3]&&1===e[4]}catch(e){r=!1}return r}()?gr:function(){throw new Error("not implemented")},vr="function"==typeof Int32Array;var br="function"==typeof Int32Array?Int32Array:null;var dr="function"==typeof Int32Array?Int32Array:void 0;var Er=function(){var r,e,t;if("function"!=typeof br)return!1;try{e=new br([1,3.14,-3.14,2147483648]),t=e,r=(vr&&t instanceof Int32Array||"[object Int32Array]"===u(t))&&1===e[0]&&3===e[1]&&-3===e[2]&&-2147483648===e[3]}catch(e){r=!1}return r}()?dr:function(){throw new Error("not implemented")},_r="function"==typeof Uint16Array;var Tr="function"==typeof Uint16Array?Uint16Array:null;var xr="function"==typeof Uint16Array?Uint16Array:void 0;var Ar=function(){var r,e,t;if("function"!=typeof Tr)return!1;try{e=new Tr(e=[1,3.14,-3.14,65536,65537]),t=e,r=(_r&&t instanceof Uint16Array||"[object Uint16Array]"===u(t))&&1===e[0]&&3===e[1]&&65533===e[2]&&0===e[3]&&1===e[4]}catch(e){r=!1}return r}()?xr:function(){throw new Error("not implemented")},Vr="function"==typeof Int16Array;var Sr="function"==typeof Int16Array?Int16Array:null;var jr="function"==typeof Int16Array?Int16Array:void 0;var Fr=function(){var r,e,t;if("function"!=typeof Sr)return!1;try{e=new Sr([1,3.14,-3.14,32768]),t=e,r=(Vr&&t instanceof Int16Array||"[object Int16Array]"===u(t))&&1===e[0]&&3===e[1]&&-3===e[2]&&-32768===e[3]}catch(e){r=!1}return r}()?jr:function(){throw new Error("not implemented")},kr="function"==typeof Uint8Array;var Ir="function"==typeof Uint8Array?Uint8Array:null;var Lr="function"==typeof Uint8Array?Uint8Array:void 0;var Rr=function(){var r,e,t;if("function"!=typeof Ir)return!1;try{e=new Ir(e=[1,3.14,-3.14,256,257]),t=e,r=(kr&&t instanceof Uint8Array||"[object Uint8Array]"===u(t))&&1===e[0]&&3===e[1]&&253===e[2]&&0===e[3]&&1===e[4]}catch(e){r=!1}return r}()?Lr:function(){throw new Error("not implemented")},Br="function"==typeof Uint8ClampedArray;var Or="function"==typeof Uint8ClampedArray?Uint8ClampedArray:null;var Cr="function"==typeof Uint8ClampedArray?Uint8ClampedArray:void 0;var Mr=function(){var r,e,t;if("function"!=typeof Or)return!1;try{e=new Or([-1,0,1,3.14,4.99,255,256]),t=e,r=(Br&&t instanceof Uint8ClampedArray||"[object Uint8ClampedArray]"===u(t))&&0===e[0]&&0===e[1]&&1===e[2]&&3===e[3]&&5===e[4]&&255===e[5]&&255===e[6]}catch(e){r=!1}return r}()?Cr:function(){throw new Error("not implemented")},Ur="function"==typeof Int8Array;var Nr="function"==typeof Int8Array?Int8Array:null;var Pr="function"==typeof Int8Array?Int8Array:void 0;var Yr=function(){var r,e,t;if("function"!=typeof Nr)return!1;try{e=new Nr([1,3.14,-3.14,128]),t=e,r=(Ur&&t instanceof Int8Array||"[object Int8Array]"===u(t))&&1===e[0]&&3===e[1]&&-3===e[2]&&-128===e[3]}catch(e){r=!1}return r}()?Pr:function(){throw new Error("not implemented")};function Wr(r){return"number"==typeof r}var $r=Number,Gr=$r.prototype.toString;var Zr=e();function Jr(r){return"object"==typeof r&&(r instanceof $r||(Zr?function(r){try{return Gr.call(r),!0}catch(r){return!1}}(r):"[object Number]"===u(r)))}function Xr(r){return Wr(r)||Jr(r)}K(Xr,"isPrimitive",Wr),K(Xr,"isObject",Jr);var zr=$r.NEGATIVE_INFINITY,Hr=Math.floor;function qr(r){return Hr(r)===r}function Dr(r){return r<sr&&r>zr&&qr(r)}function Kr(r){return Wr(r)&&Dr(r)}function Qr(r){return Jr(r)&&Dr(r.valueOf())}function re(r){return Kr(r)||Qr(r)}function ee(r){return Kr(r)&&r>=0}function te(r){return Qr(r)&&r.valueOf()>=0}function ne(r){return ee(r)||te(r)}K(re,"isPrimitive",Kr),K(re,"isObject",Qr),K(ne,"isPrimitive",ee),K(ne,"isObject",te);var ie=4294967295;function oe(r){return"object"==typeof r&&null!==r&&"number"==typeof r.length&&qr(r.length)&&r.length>=0&&r.length<=ie}var ae=9007199254740991;function ue(r){return"object"==typeof r&&null!==r&&"number"==typeof r.length&&qr(r.length)&&r.length>=0&&r.length<=ae}var fe="function"==typeof ArrayBuffer;function le(r){return fe&&r instanceof ArrayBuffer||"[object ArrayBuffer]"===u(r)}function se(r){return"object"==typeof r&&null!==r&&!f(r)}function he(r){return"string"==typeof r}var ce=String.prototype.valueOf;var pe=e();function me(r){return"object"==typeof r&&(r instanceof String||(pe?function(r){try{return ce.call(r),!0}catch(r){return!1}}(r):"[object String]"===u(r)))}function ye(r){return he(r)||me(r)}K(ye,"isPrimitive",he),K(ye,"isObject",me);var ge=/./;function we(r){return"boolean"==typeof r}var ve=Boolean,be=Boolean.prototype.toString;var de=e();function Ee(r){return"object"==typeof r&&(r instanceof ve||(de?function(r){try{return be.call(r),!0}catch(r){return!1}}(r):"[object Boolean]"===u(r)))}function _e(r){return we(r)||Ee(r)}K(_e,"isPrimitive",we),K(_e,"isObject",Ee);var Te="object"==typeof self?self:null,xe="object"==typeof window?window:null,Ae="object"==typeof global?global:null,Ve="object"==typeof globalThis?globalThis:null;var Se=function(r){if(arguments.length){if(!we(r))throw new TypeError($("invalid argument. Must provide a boolean. Value: `%s`.",r));if(r)return new Function("return this;")()}if(Ve)return Ve;if(Te)return Te;if(xe)return xe;if(Ae)return Ae;throw new Error("unexpected error. Unable to resolve global object.")}(),je=Se.document&&Se.document.childNodes,Fe=Int8Array;var ke="function"==typeof ge||"object"==typeof Fe||"function"==typeof je?function(r){return nr(r).toLowerCase()}:function(r){var e;return null===r?"null":"object"===(e=typeof r)?nr(r).toLowerCase():e};function Ie(r){return"function"===ke(r)}function Le(r,e){if(!(this instanceof Le))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:r}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:e}),this}K(Le,"BYTES_PER_ELEMENT",8),K(Le.prototype,"BYTES_PER_ELEMENT",8),K(Le.prototype,"byteLength",16),K(Le.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(Le.prototype,"toJSON",(function(){var r={type:"Complex128"};return r.re=this.re,r.im=this.im,r}));var Re="function"==typeof Math.fround?Math.fround:null,Be=new pr(1);var Oe="function"==typeof Re?Re:function(r){return Be[0]=r,Be[0]};function Ce(r,e){if(!(this instanceof Ce))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:Oe(r)}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:Oe(e)}),this}function Me(r){return r instanceof Le||r instanceof Ce||"object"==typeof r&&null!==r&&"number"==typeof r.re&&"number"==typeof r.im}function Ue(r){return qr(r/2)}K(Ce,"BYTES_PER_ELEMENT",4),K(Ce.prototype,"BYTES_PER_ELEMENT",4),K(Ce.prototype,"byteLength",8),K(Ce.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(Ce.prototype,"toJSON",(function(){var r={type:"Complex64"};return r.re=this.re,r.im=this.im,r}));var Ne=8;function Pe(r){return"object"==typeof r&&null!==r&&"Complex64Array"===r.constructor.name&&r.BYTES_PER_ELEMENT===Ne}var Ye=16;function We(r){return"object"==typeof r&&null!==r&&"Complex128Array"===r.constructor.name&&r.BYTES_PER_ELEMENT===Ye}function $e(){return"function"==typeof o&&"symbol"==typeof o("foo")&&i(o,"iterator")&&"symbol"==typeof o.iterator}var Ge=$e()?Symbol.iterator:null;function Ze(r,e,t){D(r,e,{configurable:!1,enumerable:!1,get:t})}function Je(r,e){if(!(this instanceof Je))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:Oe(r)}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:Oe(e)}),this}function Xe(r){return r.re}function ze(r){return r.im}function He(r,e){return new pr(r.buffer,r.byteOffset+r.BYTES_PER_ELEMENT*e,2*(r.length-e))}function qe(r,e){return new fr(r.buffer,r.byteOffset+r.BYTES_PER_ELEMENT*e,2*(r.length-e))}function De(r){var e,t,n;for(e=[];!(t=r.next()).done;)if(oe(n=t.value)&&n.length>=2)e.push(n[0],n[1]);else{if(!Me(n))return new TypeError($("invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",n));e.push(Xe(n),ze(n))}return e}K(Je,"BYTES_PER_ELEMENT",4),K(Je.prototype,"BYTES_PER_ELEMENT",4),K(Je.prototype,"byteLength",8),K(Je.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(Je.prototype,"toJSON",(function(){var r={type:"Complex64"};return r.re=this.re,r.im=this.im,r}));var Ke=2*pr.BYTES_PER_ELEMENT,Qe=$e();function rt(r){return r instanceof nt||"object"==typeof r&&null!==r&&("Complex64Array"===r.constructor.name||"Complex128Array"===r.constructor.name)&&"number"==typeof r._length&&"object"==typeof r._buffer}function et(r){return r===nt||"Complex128Array"===r.name}function tt(r,e){return new Je(r[e*=2],r[e+1])}function nt(){var r,e,t,n;if(e=arguments.length,!(this instanceof nt))return 0===e?new nt:1===e?new nt(arguments[0]):2===e?new nt(arguments[0],arguments[1]):new nt(arguments[0],arguments[1],arguments[2]);if(0===e)t=new pr(0);else if(1===e)if(ee(arguments[0]))t=new pr(2*arguments[0]);else if(ue(arguments[0]))if((n=(t=arguments[0]).length)&&f(t)&&Me(t[0])){if(t=function(r,e){var t,n,i,o;for(t=e.length,o=0,i=0;i<t;i++){if(!Me(n=e[i]))return null;r[o]=Xe(n),r[o+1]=ze(n),o+=2}return r}(new pr(2*n),t),null===t){if(!Ue(n))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new pr(arguments[0])}}else{if(Pe(t))t=He(t,0);else if(We(t))t=qe(t,0);else if(!Ue(n))throw new RangeError($("invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new pr(t)}else if(le(arguments[0])){if(!qr((t=arguments[0]).byteLength/Ke))throw new RangeError($("invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.",Ke,t.byteLength));t=new pr(t)}else{if(!se(arguments[0]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",arguments[0]));if(t=arguments[0],!1===Qe)throw new TypeError($("invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.",t));if(!Ie(t[Ge]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if(!Ie((t=t[Ge]()).next))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if((t=De(t))instanceof Error)throw t;t=new pr(t)}else{if(!le(t=arguments[0]))throw new TypeError($("invalid argument. First argument must be an ArrayBuffer. Value: `%s`.",t));if(!ee(r=arguments[1]))throw new TypeError($("invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.",r));if(!qr(r/Ke))throw new RangeError($("invalid argument. Byte offset must be a multiple of %u. Value: `%u`.",Ke,r));if(2===e){if(!qr((n=t.byteLength-r)/Ke))throw new RangeError($("invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.",Ke,n));t=new pr(t,r)}else{if(!ee(n=arguments[2]))throw new TypeError($("invalid argument. Length must be a nonnegative integer. Value: `%s`.",n));if(n*Ke>t.byteLength-r)throw new RangeError($("invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.",n*Ke));t=new pr(t,r,2*n)}}return K(this,"_buffer",t),K(this,"_length",t.length/2),this}function it(r,e){if(!(this instanceof it))throw new TypeError("invalid invocation. Constructor must be called with the `new` keyword.");if(!Wr(r))throw new TypeError($("invalid argument. Real component must be a number. Value: `%s`.",r));if(!Wr(e))throw new TypeError($("invalid argument. Imaginary component must be a number. Value: `%s`.",e));return D(this,"re",{configurable:!1,enumerable:!0,writable:!1,value:r}),D(this,"im",{configurable:!1,enumerable:!0,writable:!1,value:e}),this}function ot(r){return r.re}function at(r){return r.im}function ut(r){var e,t,n;for(e=[];!(t=r.next()).done;)if(oe(n=t.value)&&n.length>=2)e.push(n[0],n[1]);else{if(!Me(n))return new TypeError($("invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",n));e.push(ot(n),at(n))}return e}K(nt,"BYTES_PER_ELEMENT",Ke),K(nt,"name","Complex64Array"),K(nt,"from",(function(r){var e,t,n,i,o,a,u,f,l,s,c,m;if(!Ie(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!et(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if((t=arguments.length)>1){if(!Ie(n=arguments[1]))throw new TypeError($("invalid argument. Second argument must be a function. Value: `%s`.",n));t>2&&(e=arguments[2])}if(rt(r)){if(f=r.length,n){for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Me(s=n.call(e,r.get(c),c)))o[m]=Xe(s),o[m+1]=ze(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(ue(r)){if(n){for(f=r.length,u=r.get&&r.set?h("default"):p("default"),c=0;c<f;c++)if(!Me(u(r,c))){l=!0;break}if(l){if(!Ue(f))throw new RangeError($("invalid argument. First argument must have a length which is a multiple of %u. Length: `%u`.",2,f));for(o=(i=new this(f/2))._buffer,c=0;c<f;c++)o[c]=n.call(e,u(r,c),c);return i}for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Me(s=n.call(e,u(r,c),c)))o[m]=Xe(s),o[m+1]=ze(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(se(r)&&Qe&&Ie(r[Ge])){if(!Ie((o=r[Ge]()).next))throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r));if(a=n?function(r,e,t){var n,i,o,a;for(n=[],a=-1;!(i=r.next()).done;)if(a+=1,oe(o=e.call(t,i.value,a))&&o.length>=2)n.push(o[0],o[1]);else{if(!Me(o))return new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",o));n.push(Xe(o),ze(o))}return n}(o,n,e):De(o),a instanceof Error)throw a;for(o=(i=new this(f=a.length/2))._buffer,c=0;c<f;c++)o[c]=a[c];return i}throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r))})),K(nt,"of",(function(){var r,e;if(!Ie(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!et(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=0;e<arguments.length;e++)r.push(arguments[e]);return new this(r)})),K(nt.prototype,"at",(function(r){if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. Must provide an integer. Value: `%s`.",r));if(r<0&&(r+=this._length),!(r<0||r>=this._length))return tt(this._buffer,r)})),Ze(nt.prototype,"buffer",(function(){return this._buffer.buffer})),Ze(nt.prototype,"byteLength",(function(){return this._buffer.byteLength})),Ze(nt.prototype,"byteOffset",(function(){return this._buffer.byteOffset})),K(nt.prototype,"BYTES_PER_ELEMENT",nt.BYTES_PER_ELEMENT),K(nt.prototype,"copyWithin",(function(r,e){if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return 2===arguments.length?this._buffer.copyWithin(2*r,2*e):this._buffer.copyWithin(2*r,2*e,2*arguments[2]),this})),K(nt.prototype,"entries",(function(){var r,e,t,n,i,o,a;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return e=this,r=this._buffer,n=this._length,o=-1,a=-2,K(t={},"next",(function(){var e;if(o+=1,i||o>=n)return{done:!0};return e=new Je(r[a+=2],r[a+1]),{value:[o,e],done:!1}})),K(t,"return",(function(r){if(i=!0,arguments.length)return{value:r,done:!0};return{done:!0}})),Ge&&K(t,Ge,(function(){return e.entries()})),t})),K(nt.prototype,"every",(function(r,e){var t,n;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(!r.call(e,tt(t,n),n,this))return!1;return!0})),K(nt.prototype,"fill",(function(r,e,t){var n,i,o,a,u,f;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(n=this._buffer,i=this._length,arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));if(e<0&&(e+=i)<0&&(e=0),arguments.length>2){if(!qr(t))throw new TypeError($("invalid argument. Third argument must be an integer. Value: `%s`.",t));t<0&&(t+=i)<0&&(t=0),t>i&&(t=i)}else t=i}else e=0,t=i;for(a=Xe(r),u=ze(r),f=e;f<t;f++)n[o=2*f]=a,n[o+1]=u;return this})),K(nt.prototype,"filter",(function(r,e){var t,n,i,o;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=[],i=0;i<this._length;i++)o=tt(t,i),r.call(e,o,i,this)&&n.push(o);return new this.constructor(n)})),K(nt.prototype,"find",(function(r,e){var t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=tt(t,n),r.call(e,i,n,this))return i})),K(nt.prototype,"findIndex",(function(r,e){var t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=tt(t,n),r.call(e,i,n,this))return n;return-1})),K(nt.prototype,"findLast",(function(r,e){var t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=tt(t,n),r.call(e,i,n,this))return i})),K(nt.prototype,"findLastIndex",(function(r,e){var t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=tt(t,n),r.call(e,i,n,this))return n;return-1})),K(nt.prototype,"forEach",(function(r,e){var t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)i=tt(t,n),r.call(e,i,n,this)})),K(nt.prototype,"get",(function(r){if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ee(r))throw new TypeError($("invalid argument. Must provide a nonnegative integer. Value: `%s`.",r));if(!(r>=this._length))return tt(this._buffer,r)})),K(nt.prototype,"includes",(function(r,e){var t,n,i,o,a;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=Xe(r),o=ze(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return!0;return!1})),K(nt.prototype,"indexOf",(function(r,e){var t,n,i,o,a;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=Xe(r),o=ze(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),K(nt.prototype,"join",(function(r){var e,t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(0===arguments.length)n=",";else{if(!he(r))throw new TypeError($("invalid argument. First argument must be a string. Value: `%s`.",r));n=r}for(e=[],t=this._buffer,i=0;i<this._length;i++)e.push(tt(t,i).toString());return e.join(n)})),K(nt.prototype,"lastIndexOf",(function(r,e){var t,n,i,o,a;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e>=this._length?e=this._length-1:e<0&&(e+=this._length)}else e=this._length-1;for(i=Xe(r),o=ze(r),t=this._buffer,a=e;a>=0;a--)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),Ze(nt.prototype,"length",(function(){return this._length})),K(nt.prototype,"map",(function(r,e){var t,n,i,o,a;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(n=this._buffer,t=(i=new this.constructor(this._length))._buffer,o=0;o<this._length;o++)if(Me(a=r.call(e,tt(n,o),o,this)))t[2*o]=Xe(a),t[2*o+1]=ze(a);else{if(!oe(a)||2!==a.length)throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",a));t[2*o]=a[0],t[2*o+1]=a[1]}return i})),K(nt.prototype,"reduce",(function(r,e){var t,n,i,o;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));if(t=this._buffer,i=this._length,arguments.length>1)n=e,o=0;else{if(0===i)throw new Error("invalid operation. If not provided an initial value, an array must contain at least one element.");n=tt(t,0),o=1}for(;o<i;o++)n=r(n,tt(t,o),o,this);return n})),K(nt.prototype,"reverse",(function(){var r,e,t,n,i,o;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,r=this._buffer,n=Hr(t/2),i=0;i<n;i++)o=t-i-1,e=r[2*i],r[2*i]=r[2*o],r[2*o]=e,e=r[2*i+1],r[2*i+1]=r[2*o+1],r[2*o+1]=e;return this})),K(nt.prototype,"set",(function(r){var e,t,n,i,o,a,u,f,l;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,arguments.length>1){if(!ee(t=arguments[1]))throw new TypeError($("invalid argument. Index argument must be a nonnegative integer. Value: `%s`.",t))}else t=0;if(Me(r)){if(t>=this._length)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%u`.",t));return n[t*=2]=Xe(r),void(n[t+1]=ze(r))}if(rt(r)){if(t+(a=r._length)>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r._buffer,l=n.byteOffset+t*Ke,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new pr(e.length),f=0;f<e.length;f++)i[f]=e[f];e=i}for(t*=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2}else{if(!ue(r))throw new TypeError($("invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.",r));for(a=r.length,f=0;f<a;f++)if(!Me(r[f])){o=!0;break}if(o){if(!Ue(a))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",a));if(t+a/2>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r,l=n.byteOffset+t*Ke,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new pr(a),f=0;f<a;f++)i[f]=e[f];e=i}for(t*=2,a/=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2;return}if(t+a>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");for(t*=2,f=0;f<a;f++)u=r[f],n[t]=Xe(u),n[t+1]=ze(u),t+=2}})),K(nt.prototype,"slice",(function(r,e){var t,n,i,o,a,u,f;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(a=this._buffer,u=this._length,0===arguments.length)r=0,e=u;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=u)<0&&(r=0),1===arguments.length)e=u;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=u)<0&&(e=0):e>u&&(e=u)}}for(t=r<e?e-r:0,n=(i=new this.constructor(t))._buffer,f=0;f<t;f++)o=2*(f+r),n[2*f]=a[o],n[2*f+1]=a[o+1];return i})),K(nt.prototype,"some",(function(r,e){var t,n;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(r.call(e,tt(t,n),n,this))return!0;return!1})),K(nt.prototype,"subarray",(function(r,e){var t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,i=this._length,0===arguments.length)r=0,e=i;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=i)<0&&(r=0),1===arguments.length)e=i;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=i)<0&&(e=0):e>i&&(e=i)}}return r>=i?(i=0,t=n.byteLength):r>=e?(i=0,t=n.byteOffset+r*Ke):(i=e-r,t=n.byteOffset+r*Ke),new this.constructor(n.buffer,t,i<0?0:i)})),K(nt.prototype,"toReversed",(function(){var r,e,t,n,i,o;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,e=new this.constructor(t),n=this._buffer,r=e._buffer,i=0;i<t;i++)o=t-i-1,r[2*i]=n[2*o],r[2*i+1]=n[2*o+1];return e})),K(nt.prototype,"toString",(function(){var r,e,t;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=this._buffer,t=0;t<this._length;t++)r.push(tt(e,t).toString());return r.join(",")})),K(nt.prototype,"with",(function(r,e){var t,n,i;if(!rt(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(i=this._length,r<0&&(r+=i),r<0||r>=i)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%s`.",r));if(!Me(e))throw new TypeError($("invalid argument. Second argument must be a complex number. Value: `%s`.",e));return(t=(n=new this.constructor(this._buffer))._buffer)[2*r]=Xe(e),t[2*r+1]=ze(e),n})),K(it,"BYTES_PER_ELEMENT",8),K(it.prototype,"BYTES_PER_ELEMENT",8),K(it.prototype,"byteLength",16),K(it.prototype,"toString",(function(){var r=""+this.re;return this.im<0?r+=" - "+-this.im:r+=" + "+this.im,r+="i"})),K(it.prototype,"toJSON",(function(){var r={type:"Complex128"};return r.re=this.re,r.im=this.im,r}));var ft=2*fr.BYTES_PER_ELEMENT,lt=$e();function st(r){return r instanceof pt||"object"==typeof r&&null!==r&&("Complex64Array"===r.constructor.name||"Complex128Array"===r.constructor.name)&&"number"==typeof r._length&&"object"==typeof r._buffer}function ht(r){return r===pt||"Complex64Array"===r.name}function ct(r,e){return new it(r[e*=2],r[e+1])}function pt(){var r,e,t,n;if(e=arguments.length,!(this instanceof pt))return 0===e?new pt:1===e?new pt(arguments[0]):2===e?new pt(arguments[0],arguments[1]):new pt(arguments[0],arguments[1],arguments[2]);if(0===e)t=new fr(0);else if(1===e)if(ee(arguments[0]))t=new fr(2*arguments[0]);else if(ue(arguments[0]))if((n=(t=arguments[0]).length)&&f(t)&&Me(t[0])){if(t=function(r,e){var t,n,i,o;for(t=e.length,o=0,i=0;i<t;i++){if(!Me(n=e[i]))return null;r[o]=ot(n),r[o+1]=at(n),o+=2}return r}(new fr(2*n),t),null===t){if(!Ue(n))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new fr(arguments[0])}}else{if(Pe(t))t=He(t,0);else if(We(t))t=qe(t,0);else if(!Ue(n))throw new RangeError($("invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.",n));t=new fr(t)}else if(le(arguments[0])){if(!qr((t=arguments[0]).byteLength/ft))throw new RangeError($("invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.",ft,t.byteLength));t=new fr(t)}else{if(!se(arguments[0]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",arguments[0]));if(t=arguments[0],!1===lt)throw new TypeError($("invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.",t));if(!Ie(t[Ge]))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if(!Ie((t=t[Ge]()).next))throw new TypeError($("invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.",t));if((t=ut(t))instanceof Error)throw t;t=new fr(t)}else{if(!le(t=arguments[0]))throw new TypeError($("invalid argument. First argument must be an ArrayBuffer. Value: `%s`.",t));if(!ee(r=arguments[1]))throw new TypeError($("invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.",r));if(!qr(r/ft))throw new RangeError($("invalid argument. Byte offset must be a multiple of %u. Value: `%u`.",ft,r));if(2===e){if(!qr((n=t.byteLength-r)/ft))throw new RangeError($("invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.",ft,n));t=new fr(t,r)}else{if(!ee(n=arguments[2]))throw new TypeError($("invalid argument. Length must be a nonnegative integer. Value: `%s`.",n));if(n*ft>t.byteLength-r)throw new RangeError($("invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.",n*ft));t=new fr(t,r,2*n)}}return K(this,"_buffer",t),K(this,"_length",t.length/2),this}K(pt,"BYTES_PER_ELEMENT",ft),K(pt,"name","Complex128Array"),K(pt,"from",(function(r){var e,t,n,i,o,a,u,f,l,s,c,m;if(!Ie(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!ht(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if((t=arguments.length)>1){if(!Ie(n=arguments[1]))throw new TypeError($("invalid argument. Second argument must be a function. Value: `%s`.",n));t>2&&(e=arguments[2])}if(st(r)){if(f=r.length,n){for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Me(s=n.call(e,r.get(c),c)))o[m]=ot(s),o[m+1]=at(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(ue(r)){if(n){for(f=r.length,u=r.get&&r.set?h("default"):p("default"),c=0;c<f;c++)if(!Me(u(r,c))){l=!0;break}if(l){if(!Ue(f))throw new RangeError($("invalid argument. First argument must have a length which is a multiple of two. Length: `%u`.",f));for(o=(i=new this(f/2))._buffer,c=0;c<f;c++)o[c]=n.call(e,u(r,c),c);return i}for(o=(i=new this(f))._buffer,m=0,c=0;c<f;c++){if(Me(s=n.call(e,u(r,c),c)))o[m]=ot(s),o[m+1]=at(s);else{if(!(oe(s)&&s.length>=2))throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",s));o[m]=s[0],o[m+1]=s[1]}m+=2}return i}return new this(r)}if(se(r)&<&&Ie(r[Ge])){if(!Ie((o=r[Ge]()).next))throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r));if(a=n?function(r,e,t){var n,i,o,a;for(n=[],a=-1;!(i=r.next()).done;)if(a+=1,oe(o=e.call(t,i.value,a))&&o.length>=2)n.push(o[0],o[1]);else{if(!Me(o))return new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",o));n.push(ot(o),at(o))}return n}(o,n,e):ut(o),a instanceof Error)throw a;for(o=(i=new this(f=a.length/2))._buffer,c=0;c<f;c++)o[c]=a[c];return i}throw new TypeError($("invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.",r))})),K(pt,"of",(function(){var r,e;if(!Ie(this))throw new TypeError("invalid invocation. `this` context must be a constructor.");if(!ht(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=0;e<arguments.length;e++)r.push(arguments[e]);return new this(r)})),K(pt.prototype,"at",(function(r){if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. Must provide an integer. Value: `%s`.",r));if(r<0&&(r+=this._length),!(r<0||r>=this._length))return ct(this._buffer,r)})),Ze(pt.prototype,"buffer",(function(){return this._buffer.buffer})),Ze(pt.prototype,"byteLength",(function(){return this._buffer.byteLength})),Ze(pt.prototype,"byteOffset",(function(){return this._buffer.byteOffset})),K(pt.prototype,"BYTES_PER_ELEMENT",pt.BYTES_PER_ELEMENT),K(pt.prototype,"copyWithin",(function(r,e){if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return 2===arguments.length?this._buffer.copyWithin(2*r,2*e):this._buffer.copyWithin(2*r,2*e,2*arguments[2]),this})),K(pt.prototype,"entries",(function(){var r,e,t,n,i,o,a;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");return e=this,r=this._buffer,n=this._length,o=-1,a=-2,K(t={},"next",(function(){var e;if(o+=1,i||o>=n)return{done:!0};return e=new it(r[a+=2],r[a+1]),{value:[o,e],done:!1}})),K(t,"return",(function(r){if(i=!0,arguments.length)return{value:r,done:!0};return{done:!0}})),Ge&&K(t,Ge,(function(){return e.entries()})),t})),K(pt.prototype,"every",(function(r,e){var t,n;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(!r.call(e,ct(t,n),n,this))return!1;return!0})),K(pt.prototype,"fill",(function(r,e,t){var n,i,o,a,u,f;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(n=this._buffer,i=this._length,arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));if(e<0&&(e+=i)<0&&(e=0),arguments.length>2){if(!qr(t))throw new TypeError($("invalid argument. Third argument must be an integer. Value: `%s`.",t));t<0&&(t+=i)<0&&(t=0),t>i&&(t=i)}else t=i}else e=0,t=i;for(a=ot(r),u=at(r),f=e;f<t;f++)n[o=2*f]=a,n[o+1]=u;return this})),K(pt.prototype,"filter",(function(r,e){var t,n,i,o;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=[],i=0;i<this._length;i++)o=ct(t,i),r.call(e,o,i,this)&&n.push(o);return new this.constructor(n)})),K(pt.prototype,"find",(function(r,e){var t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=ct(t,n),r.call(e,i,n,this))return i})),K(pt.prototype,"findIndex",(function(r,e){var t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(i=ct(t,n),r.call(e,i,n,this))return n;return-1})),K(pt.prototype,"findLast",(function(r,e){var t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=ct(t,n),r.call(e,i,n,this))return i})),K(pt.prototype,"findLastIndex",(function(r,e){var t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=this._length-1;n>=0;n--)if(i=ct(t,n),r.call(e,i,n,this))return n;return-1})),K(pt.prototype,"forEach",(function(r,e){var t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)i=ct(t,n),r.call(e,i,n,this)})),K(pt.prototype,"get",(function(r){if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!ee(r))throw new TypeError($("invalid argument. Must provide a nonnegative integer. Value: `%s`.",r));if(!(r>=this._length))return ct(this._buffer,r)})),Ze(pt.prototype,"length",(function(){return this._length})),K(pt.prototype,"includes",(function(r,e){var t,n,i,o,a;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=ot(r),o=at(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return!0;return!1})),K(pt.prototype,"indexOf",(function(r,e){var t,n,i,o,a;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0&&(e+=this._length)<0&&(e=0)}else e=0;for(i=ot(r),o=at(r),t=this._buffer,a=e;a<this._length;a++)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),K(pt.prototype,"join",(function(r){var e,t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(0===arguments.length)n=",";else{if(!ye(r))throw new TypeError($("invalid argument. First argument must be a string. Value: `%s`.",r));n=r}for(e=[],t=this._buffer,i=0;i<this._length;i++)e.push(ct(t,i).toString());return e.join(n)})),K(pt.prototype,"lastIndexOf",(function(r,e){var t,n,i,o,a;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Me(r))throw new TypeError($("invalid argument. First argument must be a complex number. Value: `%s`.",r));if(arguments.length>1){if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e>=this._length?e=this._length-1:e<0&&(e+=this._length)}else e=this._length-1;for(i=ot(r),o=at(r),t=this._buffer,a=e;a>=0;a--)if(i===t[n=2*a]&&o===t[n+1])return a;return-1})),K(pt.prototype,"map",(function(r,e){var t,n,i,o,a;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(n=this._buffer,t=(i=new this.constructor(this._length))._buffer,o=0;o<this._length;o++)if(Me(a=r.call(e,ct(n,o),o,this)))t[2*o]=ot(a),t[2*o+1]=at(a);else{if(!oe(a)||2!==a.length)throw new TypeError($("invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.",a));t[2*o]=a[0],t[2*o+1]=a[1]}return i})),K(pt.prototype,"reduce",(function(r,e){var t,n,i,o;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));if(t=this._buffer,i=this._length,arguments.length>1)n=e,o=0;else{if(0===i)throw new Error("invalid operation. If not provided an initial value, an array must contain at least one element.");n=ct(t,0),o=1}for(;o<i;o++)n=r(n,ct(t,o),o,this);return n})),K(pt.prototype,"reverse",(function(){var r,e,t,n,i,o;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,r=this._buffer,n=Hr(t/2),i=0;i<n;i++)o=t-i-1,e=r[2*i],r[2*i]=r[2*o],r[2*o]=e,e=r[2*i+1],r[2*i+1]=r[2*o+1],r[2*o+1]=e;return this})),K(pt.prototype,"set",(function(r){var e,t,n,i,o,a,u,f,l;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,arguments.length>1){if(!ee(t=arguments[1]))throw new TypeError($("invalid argument. Index argument must be a nonnegative integer. Value: `%s`.",t))}else t=0;if(Me(r)){if(t>=this._length)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%u`.",t));return n[t*=2]=ot(r),void(n[t+1]=at(r))}if(st(r)){if(t+(a=r._length)>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r._buffer,l=n.byteOffset+t*ft,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new fr(e.length),f=0;f<e.length;f++)i[f]=e[f];e=i}for(t*=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2}else{if(!ue(r))throw new TypeError($("invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.",r));for(a=r.length,f=0;f<a;f++)if(!Me(r[f])){o=!0;break}if(o){if(!Ue(a))throw new RangeError($("invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.",a));if(t+a/2>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");if(e=r,l=n.byteOffset+t*ft,e.buffer===n.buffer&&e.byteOffset<l&&e.byteOffset+e.byteLength>l){for(i=new fr(a),f=0;f<a;f++)i[f]=e[f];e=i}for(t*=2,a/=2,l=0,f=0;f<a;f++)n[t]=e[l],n[t+1]=e[l+1],t+=2,l+=2;return}if(t+a>this._length)throw new RangeError("invalid arguments. Target array lacks sufficient storage to accommodate source values.");for(t*=2,f=0;f<a;f++)u=r[f],n[t]=ot(u),n[t+1]=at(u),t+=2}})),K(pt.prototype,"slice",(function(r,e){var t,n,i,o,a,u,f;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(a=this._buffer,u=this._length,0===arguments.length)r=0,e=u;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=u)<0&&(r=0),1===arguments.length)e=u;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=u)<0&&(e=0):e>u&&(e=u)}}for(t=r<e?e-r:0,n=(i=new this.constructor(t))._buffer,f=0;f<t;f++)o=2*(f+r),n[2*f]=a[o],n[2*f+1]=a[o+1];return i})),K(pt.prototype,"some",(function(r,e){var t,n;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!Ie(r))throw new TypeError($("invalid argument. First argument must be a function. Value: `%s`.",r));for(t=this._buffer,n=0;n<this._length;n++)if(r.call(e,ct(t,n),n,this))return!0;return!1})),K(pt.prototype,"subarray",(function(r,e){var t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(n=this._buffer,i=this._length,0===arguments.length)r=0,e=i;else{if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(r<0&&(r+=i)<0&&(r=0),1===arguments.length)e=i;else{if(!qr(e))throw new TypeError($("invalid argument. Second argument must be an integer. Value: `%s`.",e));e<0?(e+=i)<0&&(e=0):e>i&&(e=i)}}return r>=i?(i=0,t=n.byteLength):r>=e?(i=0,t=n.byteOffset+r*ft):(i=e-r,t=n.byteOffset+r*ft),new this.constructor(n.buffer,t,i<0?0:i)})),K(pt.prototype,"toReversed",(function(){var r,e,t,n,i,o;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(t=this._length,e=new this.constructor(t),n=this._buffer,r=e._buffer,i=0;i<t;i++)o=t-i-1,r[2*i]=n[2*o],r[2*i+1]=n[2*o+1];return e})),K(pt.prototype,"toString",(function(){var r,e,t;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");for(r=[],e=this._buffer,t=0;t<this._length;t++)r.push(ct(e,t).toString());return r.join(",")})),K(pt.prototype,"with",(function(r,e){var t,n,i;if(!st(this))throw new TypeError("invalid invocation. `this` is not a complex number array.");if(!qr(r))throw new TypeError($("invalid argument. First argument must be an integer. Value: `%s`.",r));if(i=this._length,r<0&&(r+=i),r<0||r>=i)throw new RangeError($("invalid argument. Index argument is out-of-bounds. Value: `%s`.",r));if(!Me(e))throw new TypeError($("invalid argument. Second argument must be a complex number. Value: `%s`.",e));return(t=(n=new this.constructor(this._buffer))._buffer)[2*r]=ot(e),t[2*r+1]=at(e),n}));var mt=[fr,pr,Er,wr,Fr,Ar,Yr,Rr,Mr,nt,pt],yt=["float64","float32","int32","uint32","int16","uint16","int8","uint8","uint8c","complex64","complex128"],gt=yt.length;function wt(r){var e,t=function(r){var e;if(f(r))return"generic";if(rr(r))return null;for(e=0;e<gt;e++)if(r instanceof mt[e])return yt[e];return ir[nr(r)]||null}(r);return typeof(e=r).get===l&&typeof e.set===l?h(t):p(t)}return function(r,e){var t,n,i,o,a,u,l,s;if(i=r.length,e.length!==i)throw new RangeError(function(){var r,e=arguments,t="https://stdlib.io/e/"+e[0]+"?";for(r=1;r<e.length;r++)t+="&arg[]="+encodeURIComponent(e[r]);return t}("1nHFI"));for(t=wt(r),n=wt(e),o={},s=0;s<i;s++)l=t(r,s),u=o[a=n(e,s).toString()],f(u)?u.push([s,l]):o[a]=[[s,l]];return o}})); +//# sourceMappingURL=index.js.map diff --git a/index.js.map b/index.js.map new file mode 100644 index 0000000..b564c24 --- /dev/null +++ b/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"index.js","sources":["../node_modules/@stdlib/assert-has-tostringtag-support/lib/main.js","../node_modules/@stdlib/assert-has-symbol-support/lib/main.js","../node_modules/@stdlib/utils-native-class/lib/tostring.js","../node_modules/@stdlib/assert-has-own-property/lib/main.js","../node_modules/@stdlib/symbol-ctor/lib/main.js","../node_modules/@stdlib/utils-native-class/lib/tostringtag.js","../node_modules/@stdlib/utils-native-class/lib/index.js","../node_modules/@stdlib/utils-native-class/lib/polyfill.js","../node_modules/@stdlib/utils-native-class/lib/main.js","../node_modules/@stdlib/assert-is-array/lib/main.js","../node_modules/@stdlib/array-base-assert-is-accessor-array/lib/main.js","../node_modules/@stdlib/array-base-accessor-getter/lib/main.js","../node_modules/@stdlib/array-base-getter/lib/main.js","../node_modules/@stdlib/utils-define-property/lib/define_property.js","../node_modules/@stdlib/utils-define-property/lib/builtin.js","../node_modules/@stdlib/string-base-format-interpolate/lib/is_number.js","../node_modules/@stdlib/string-base-format-interpolate/lib/zero_pad.js","../node_modules/@stdlib/string-base-format-interpolate/lib/format_integer.js","../node_modules/@stdlib/string-base-format-interpolate/lib/format_double.js","../node_modules/@stdlib/string-base-format-interpolate/lib/space_pad.js","../node_modules/@stdlib/string-base-format-interpolate/lib/main.js","../node_modules/@stdlib/string-base-format-interpolate/lib/is_string.js","../node_modules/@stdlib/string-base-format-tokenize/lib/main.js","../node_modules/@stdlib/string-format/lib/main.js","../node_modules/@stdlib/string-format/lib/is_string.js","../node_modules/@stdlib/utils-define-property/lib/polyfill.js","../node_modules/@stdlib/utils-define-property/lib/index.js","../node_modules/@stdlib/utils-define-property/lib/has_define_property_support.js","../node_modules/@stdlib/utils-define-nonenumerable-read-only-property/lib/main.js","../node_modules/@stdlib/assert-is-object-like/lib/main.js","../node_modules/@stdlib/assert-is-buffer/lib/main.js","../node_modules/@stdlib/regexp-function-name/lib/main.js","../node_modules/@stdlib/assert-is-object-like/lib/index.js","../node_modules/@stdlib/assert-tools-array-function/lib/main.js","../node_modules/@stdlib/regexp-function-name/lib/regexp.js","../node_modules/@stdlib/utils-constructor-name/lib/main.js","../node_modules/@stdlib/regexp-function-name/lib/index.js","../node_modules/@stdlib/array-dtype/lib/ctor2dtype.js","../node_modules/@stdlib/assert-is-float64array/lib/main.js","../node_modules/@stdlib/assert-has-float64array-support/lib/float64array.js","../node_modules/@stdlib/array-float64/lib/main.js","../node_modules/@stdlib/array-float64/lib/index.js","../node_modules/@stdlib/assert-has-float64array-support/lib/main.js","../node_modules/@stdlib/array-float64/lib/polyfill.js","../node_modules/@stdlib/assert-is-float32array/lib/main.js","../node_modules/@stdlib/constants-float64-pinf/lib/index.js","../node_modules/@stdlib/assert-has-float32array-support/lib/float32array.js","../node_modules/@stdlib/array-float32/lib/main.js","../node_modules/@stdlib/array-float32/lib/index.js","../node_modules/@stdlib/assert-has-float32array-support/lib/main.js","../node_modules/@stdlib/array-float32/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint32array/lib/main.js","../node_modules/@stdlib/constants-uint32-max/lib/index.js","../node_modules/@stdlib/assert-has-uint32array-support/lib/uint32array.js","../node_modules/@stdlib/array-uint32/lib/main.js","../node_modules/@stdlib/array-uint32/lib/index.js","../node_modules/@stdlib/assert-has-uint32array-support/lib/main.js","../node_modules/@stdlib/array-uint32/lib/polyfill.js","../node_modules/@stdlib/assert-is-int32array/lib/main.js","../node_modules/@stdlib/constants-int32-max/lib/index.js","../node_modules/@stdlib/assert-has-int32array-support/lib/int32array.js","../node_modules/@stdlib/array-int32/lib/main.js","../node_modules/@stdlib/array-int32/lib/index.js","../node_modules/@stdlib/assert-has-int32array-support/lib/main.js","../node_modules/@stdlib/constants-int32-min/lib/index.js","../node_modules/@stdlib/array-int32/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint16array/lib/main.js","../node_modules/@stdlib/constants-uint16-max/lib/index.js","../node_modules/@stdlib/assert-has-uint16array-support/lib/uint16array.js","../node_modules/@stdlib/array-uint16/lib/main.js","../node_modules/@stdlib/array-uint16/lib/index.js","../node_modules/@stdlib/assert-has-uint16array-support/lib/main.js","../node_modules/@stdlib/array-uint16/lib/polyfill.js","../node_modules/@stdlib/assert-is-int16array/lib/main.js","../node_modules/@stdlib/constants-int16-max/lib/index.js","../node_modules/@stdlib/assert-has-int16array-support/lib/int16array.js","../node_modules/@stdlib/array-int16/lib/main.js","../node_modules/@stdlib/array-int16/lib/index.js","../node_modules/@stdlib/assert-has-int16array-support/lib/main.js","../node_modules/@stdlib/constants-int16-min/lib/index.js","../node_modules/@stdlib/array-int16/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint8array/lib/main.js","../node_modules/@stdlib/constants-uint8-max/lib/index.js","../node_modules/@stdlib/assert-has-uint8array-support/lib/uint8array.js","../node_modules/@stdlib/array-uint8/lib/main.js","../node_modules/@stdlib/array-uint8/lib/index.js","../node_modules/@stdlib/assert-has-uint8array-support/lib/main.js","../node_modules/@stdlib/array-uint8/lib/polyfill.js","../node_modules/@stdlib/assert-is-uint8clampedarray/lib/main.js","../node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/uint8clampedarray.js","../node_modules/@stdlib/array-uint8c/lib/main.js","../node_modules/@stdlib/array-uint8c/lib/index.js","../node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/main.js","../node_modules/@stdlib/array-uint8c/lib/polyfill.js","../node_modules/@stdlib/assert-is-int8array/lib/main.js","../node_modules/@stdlib/constants-int8-max/lib/index.js","../node_modules/@stdlib/assert-has-int8array-support/lib/int8array.js","../node_modules/@stdlib/array-int8/lib/main.js","../node_modules/@stdlib/array-int8/lib/index.js","../node_modules/@stdlib/assert-has-int8array-support/lib/main.js","../node_modules/@stdlib/constants-int8-min/lib/index.js","../node_modules/@stdlib/array-int8/lib/polyfill.js","../node_modules/@stdlib/assert-is-number/lib/primitive.js","../node_modules/@stdlib/number-ctor/lib/main.js","../node_modules/@stdlib/assert-is-number/lib/tostring.js","../node_modules/@stdlib/assert-is-number/lib/object.js","../node_modules/@stdlib/assert-is-number/lib/try2serialize.js","../node_modules/@stdlib/assert-is-number/lib/main.js","../node_modules/@stdlib/assert-is-number/lib/index.js","../node_modules/@stdlib/constants-float64-ninf/lib/index.js","../node_modules/@stdlib/math-base-special-floor/lib/main.js","../node_modules/@stdlib/math-base-assert-is-integer/lib/main.js","../node_modules/@stdlib/assert-is-integer/lib/integer.js","../node_modules/@stdlib/assert-is-integer/lib/primitive.js","../node_modules/@stdlib/assert-is-integer/lib/object.js","../node_modules/@stdlib/assert-is-integer/lib/main.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/primitive.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/object.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/main.js","../node_modules/@stdlib/assert-is-integer/lib/index.js","../node_modules/@stdlib/assert-is-nonnegative-integer/lib/index.js","../node_modules/@stdlib/constants-array-max-array-length/lib/index.js","../node_modules/@stdlib/assert-is-array-like-object/lib/main.js","../node_modules/@stdlib/constants-array-max-typed-array-length/lib/index.js","../node_modules/@stdlib/assert-is-collection/lib/main.js","../node_modules/@stdlib/assert-is-arraybuffer/lib/main.js","../node_modules/@stdlib/assert-is-object/lib/main.js","../node_modules/@stdlib/assert-is-string/lib/primitive.js","../node_modules/@stdlib/assert-is-string/lib/valueof.js","../node_modules/@stdlib/assert-is-string/lib/object.js","../node_modules/@stdlib/assert-is-string/lib/try2valueof.js","../node_modules/@stdlib/assert-is-string/lib/main.js","../node_modules/@stdlib/assert-is-string/lib/index.js","../node_modules/@stdlib/utils-type-of/lib/fixtures/re.js","../node_modules/@stdlib/assert-is-boolean/lib/primitive.js","../node_modules/@stdlib/boolean-ctor/lib/main.js","../node_modules/@stdlib/assert-is-boolean/lib/tostring.js","../node_modules/@stdlib/assert-is-boolean/lib/object.js","../node_modules/@stdlib/assert-is-boolean/lib/try2serialize.js","../node_modules/@stdlib/assert-is-boolean/lib/main.js","../node_modules/@stdlib/assert-is-boolean/lib/index.js","../node_modules/@stdlib/utils-global/lib/self.js","../node_modules/@stdlib/utils-global/lib/window.js","../node_modules/@stdlib/utils-global/lib/global.js","../node_modules/@stdlib/utils-global/lib/global_this.js","../node_modules/@stdlib/utils-type-of/lib/fixtures/nodelist.js","../node_modules/@stdlib/utils-global/lib/main.js","../node_modules/@stdlib/utils-global/lib/codegen.js","../node_modules/@stdlib/utils-type-of/lib/fixtures/typedarray.js","../node_modules/@stdlib/utils-type-of/lib/index.js","../node_modules/@stdlib/utils-type-of/lib/check.js","../node_modules/@stdlib/utils-type-of/lib/polyfill.js","../node_modules/@stdlib/utils-type-of/lib/main.js","../node_modules/@stdlib/assert-is-function/lib/main.js","../node_modules/@stdlib/complex-float64-ctor/lib/main.js","../node_modules/@stdlib/complex-float64-ctor/lib/tostring.js","../node_modules/@stdlib/complex-float64-ctor/lib/tojson.js","../node_modules/@stdlib/number-float64-base-to-float32/lib/main.js","../node_modules/@stdlib/number-float64-base-to-float32/lib/polyfill.js","../node_modules/@stdlib/number-float64-base-to-float32/lib/index.js","../node_modules/@stdlib/complex-float32-ctor/lib/main.js","../node_modules/@stdlib/assert-is-complex-like/lib/main.js","../node_modules/@stdlib/math-base-assert-is-even/lib/main.js","../node_modules/@stdlib/complex-float32-ctor/lib/tostring.js","../node_modules/@stdlib/complex-float32-ctor/lib/tojson.js","../node_modules/@stdlib/array-base-assert-is-complex64array/lib/main.js","../node_modules/@stdlib/array-base-assert-is-complex128array/lib/main.js","../node_modules/@stdlib/assert-has-iterator-symbol-support/lib/main.js","../node_modules/@stdlib/symbol-iterator/lib/main.js","../node_modules/@stdlib/utils-define-nonenumerable-read-only-accessor/lib/main.js","../node_modules/@stdlib/complex-float32/lib/main.js","../node_modules/@stdlib/complex-realf/lib/main.js","../node_modules/@stdlib/complex-imagf/lib/main.js","../node_modules/@stdlib/strided-base-reinterpret-complex64/lib/main.js","../node_modules/@stdlib/strided-base-reinterpret-complex128/lib/main.js","../node_modules/@stdlib/array-complex64/lib/from_iterator.js","../node_modules/@stdlib/complex-float32/lib/tostring.js","../node_modules/@stdlib/complex-float32/lib/tojson.js","../node_modules/@stdlib/array-complex64/lib/main.js","../node_modules/@stdlib/array-complex64/lib/from_array.js","../node_modules/@stdlib/complex-float64/lib/main.js","../node_modules/@stdlib/complex-real/lib/main.js","../node_modules/@stdlib/complex-imag/lib/main.js","../node_modules/@stdlib/array-complex128/lib/from_iterator.js","../node_modules/@stdlib/array-complex64/lib/from_iterator_map.js","../node_modules/@stdlib/complex-float64/lib/tostring.js","../node_modules/@stdlib/complex-float64/lib/tojson.js","../node_modules/@stdlib/array-complex128/lib/main.js","../node_modules/@stdlib/array-complex128/lib/from_array.js","../node_modules/@stdlib/array-complex128/lib/from_iterator_map.js","../node_modules/@stdlib/array-dtype/lib/ctors.js","../node_modules/@stdlib/array-dtype/lib/dtypes.js","../node_modules/@stdlib/array-dtype/lib/main.js","../node_modules/@stdlib/array-base-resolve-getter/lib/main.js","../lib/main.js","../node_modules/@stdlib/error-tools-fmtprodmsg/lib/main.js"],"sourcesContent":["/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasSymbols from '@stdlib/assert-has-symbol-support';\n\n\n// VARIABLES //\n\nvar FLG = hasSymbols();\n\n\n// MAIN //\n\n/**\n* Tests for native `toStringTag` support.\n*\n* @returns {boolean} boolean indicating if an environment has `toStringTag` support\n*\n* @example\n* var bool = hasToStringTagSupport();\n* // returns <boolean>\n*/\nfunction hasToStringTagSupport() {\n\treturn ( FLG && typeof Symbol.toStringTag === 'symbol' );\n}\n\n\n// EXPORTS //\n\nexport default hasToStringTagSupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Tests for native `Symbol` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Symbol` support\n*\n* @example\n* var bool = hasSymbolSupport();\n* // returns <boolean>\n*/\nfunction hasSymbolSupport() {\n\treturn (\n\t\ttypeof Symbol === 'function' &&\n\t\ttypeof Symbol( 'foo' ) === 'symbol'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default hasSymbolSupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar toStr = Object.prototype.toString;\n\n\n// EXPORTS //\n\nexport default toStr;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// FUNCTIONS //\n\nvar has = Object.prototype.hasOwnProperty;\n\n\n// MAIN //\n\n/**\n* Tests if an object has a specified property.\n*\n* @param {*} value - value to test\n* @param {*} property - property to test\n* @returns {boolean} boolean indicating if an object has a specified property\n*\n* @example\n* var beep = {\n* 'boop': true\n* };\n*\n* var bool = hasOwnProp( beep, 'boop' );\n* // returns true\n*\n* @example\n* var beep = {\n* 'boop': true\n* };\n*\n* var bool = hasOwnProp( beep, 'bap' );\n* // returns false\n*/\nfunction hasOwnProp( value, property ) {\n\tif (\n\t\tvalue === void 0 ||\n\t\tvalue === null\n\t) {\n\t\treturn false;\n\t}\n\treturn has.call( value, property );\n}\n\n\n// EXPORTS //\n\nexport default hasOwnProp;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar Sym = ( typeof Symbol === 'function' ) ? Symbol : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default Sym;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Symbol from '@stdlib/symbol-ctor';\n\n\n// MAIN //\n\nvar toStrTag = ( typeof Symbol === 'function' ) ? Symbol.toStringTag : '';\n\n\n// EXPORTS //\n\nexport default toStrTag;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Return a string value indicating a specification defined classification of an object.\n*\n* @module @stdlib/utils-native-class\n*\n* @example\n* import nativeClass from '@stdlib/utils-native-class';\n*\n* var str = nativeClass( 'a' );\n* // returns '[object String]'\n*\n* str = nativeClass( 5 );\n* // returns '[object Number]'\n*\n* function Beep() {\n* return this;\n* }\n* str = nativeClass( new Beep() );\n* // returns '[object Object]'\n*/\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar main;\nif ( hasToStringTag() ) {\n\tmain = polyfill;\n} else {\n\tmain = builtin;\n}\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasOwnProp from '@stdlib/assert-has-own-property';\nimport toStringTag from './tostringtag.js';\nimport toStr from './tostring.js';\n\n\n// MAIN //\n\n/**\n* Returns a string value indicating a specification defined classification of an object in environments supporting `Symbol.toStringTag`.\n*\n* @param {*} v - input value\n* @returns {string} string value indicating a specification defined classification of the input value\n*\n* @example\n* var str = nativeClass( 'a' );\n* // returns '[object String]'\n*\n* @example\n* var str = nativeClass( 5 );\n* // returns '[object Number]'\n*\n* @example\n* function Beep() {\n* return this;\n* }\n* var str = nativeClass( new Beep() );\n* // returns '[object Object]'\n*/\nfunction nativeClass( v ) {\n\tvar isOwn;\n\tvar tag;\n\tvar out;\n\n\tif ( v === null || v === void 0 ) {\n\t\treturn toStr.call( v );\n\t}\n\ttag = v[ toStringTag ];\n\tisOwn = hasOwnProp( v, toStringTag );\n\n\t// Attempt to override the `toStringTag` property. For built-ins having a `Symbol.toStringTag` property (e.g., `JSON`, `Math`, etc), the `Symbol.toStringTag` property is read-only (e.g., , so we need to wrap in a `try/catch`.\n\ttry {\n\t\tv[ toStringTag ] = void 0;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn toStr.call( v );\n\t}\n\tout = toStr.call( v );\n\n\tif ( isOwn ) {\n\t\tv[ toStringTag ] = tag;\n\t} else {\n\t\tdelete v[ toStringTag ];\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default nativeClass;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport toStr from './tostring.js';\n\n\n// MAIN //\n\n/**\n* Returns a string value indicating a specification defined classification (via the internal property `[[Class]]`) of an object.\n*\n* @param {*} v - input value\n* @returns {string} string value indicating a specification defined classification of the input value\n*\n* @example\n* var str = nativeClass( 'a' );\n* // returns '[object String]'\n*\n* @example\n* var str = nativeClass( 5 );\n* // returns '[object Number]'\n*\n* @example\n* function Beep() {\n* return this;\n* }\n* var str = nativeClass( new Beep() );\n* // returns '[object Object]'\n*/\nfunction nativeClass( v ) {\n\treturn toStr.call( v );\n}\n\n\n// EXPORTS //\n\nexport default nativeClass;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar f;\n\n\n// FUNCTIONS //\n\n/**\n* Tests if a value is an array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an array\n*\n* @example\n* var bool = isArray( [] );\n* // returns true\n*\n* @example\n* var bool = isArray( {} );\n* // returns false\n*/\nfunction isArray( value ) {\n\treturn ( nativeClass( value ) === '[object Array]' );\n}\n\n\n// MAIN //\n\nif ( Array.isArray ) {\n\tf = Array.isArray;\n} else {\n\tf = isArray;\n}\n\n\n// EXPORTS //\n\nexport default f;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar TYPE = 'function';\n\n\n// MAIN //\n\n/**\n* Tests if an array-like object supports the accessor (get/set) protocol.\n*\n* @param {Object} value - value to test\n* @returns {boolean} boolean indicating whether a value is an accessor array\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n*\n* var bool = isAccessorArray( new Complex128Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isAccessorArray( [] );\n* // returns false\n*/\nfunction isAccessorArray( value ) {\n\treturn ( typeof value.get === TYPE && typeof value.set === TYPE ); // eslint-disable-line valid-typeof\n}\n\n\n// EXPORTS //\n\nexport default isAccessorArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar GETTERS = {\n\t'complex128': getComplex128,\n\t'complex64': getComplex64,\n\t'default': getArrayLike\n};\n\n\n// FUNCTIONS //\n\n/**\n* Returns an element from a `Complex128Array`.\n*\n* @private\n* @param {Complex128Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n* import real from '@stdlib/complex-float64-real';\n* import imag from '@stdlib/complex-float64-imag';\n*\n* var arr = new Complex128Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getComplex128( arr, 1 );\n* // returns <Complex128>\n*\n* var re = real( v );\n* // returns 3.0\n*\n* var im = imag( v );\n* // returns 4.0\n*/\nfunction getComplex128( arr, idx ) {\n\treturn arr.get( idx );\n}\n\n/**\n* Returns an element from a `Complex64Array`.\n*\n* @private\n* @param {Complex64Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n* import realf from '@stdlib/complex-float32-real';\n* import imagf from '@stdlib/complex-float32-imag';\n*\n* var arr = new Complex64Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getComplex64( arr, 1 );\n* // returns <Complex64>\n*\n* var re = realf( v );\n* // returns 3.0\n*\n* var im = imagf( v );\n* // returns 4.0\n*/\nfunction getComplex64( arr, idx ) {\n\treturn arr.get( idx );\n}\n\n/**\n* Returns an element from an array-like object supporting the get/set protocol.\n*\n* @private\n* @param {Collection} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {*} element value\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* function get( idx ) {\n* return arr[ idx ];\n* }\n*\n* function set( value, idx ) {\n* arr[ idx ] = value;\n* }\n*\n* arr.get = get;\n* arr.set = set;\n*\n* var v = getArrayLike( arr, 2 );\n* // returns 3\n*/\nfunction getArrayLike( arr, idx ) {\n\treturn arr.get( idx );\n}\n\n\n// MAIN //\n\n/**\n* Returns an accessor function for retrieving an element from an array-like object supporting the get/set protocol.\n*\n* @param {string} dtype - array dtype\n* @returns {Function} accessor\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n* import realf from '@stdlib/complex-float32-real';\n* import imagf from '@stdlib/complex-float32-imag';\n* import dtype from '@stdlib/array-dtype';\n*\n* var arr = new Complex64Array( [ 1, 2, 3, 4 ] );\n*\n* var get = getter( dtype( arr ) );\n* var v = get( arr, 1 );\n* // returns <Complex64>\n*\n* var re = realf( v );\n* // returns 3.0\n*\n* var im = imagf( v );\n* // returns 4.0\n*/\nfunction getter( dtype ) {\n\tvar f = GETTERS[ dtype ];\n\tif ( typeof f === 'function' ) {\n\t\treturn f;\n\t}\n\treturn GETTERS.default;\n}\n\n\n// EXPORTS //\n\nexport default getter;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar GETTERS = {\n\t'float64': getFloat64,\n\t'float32': getFloat32,\n\t'int32': getInt32,\n\t'int16': getInt16,\n\t'int8': getInt8,\n\t'uint32': getUint32,\n\t'uint16': getUint16,\n\t'uint8': getUint8,\n\t'uint8c': getUint8c,\n\t'generic': getGeneric,\n\t'default': getArrayLike\n};\n\n\n// FUNCTIONS //\n\n/**\n* Returns an element from a `Float64Array`.\n*\n* @private\n* @param {Float64Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Float64Array from '@stdlib/array-float64';\n*\n* var arr = new Float64Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getFloat64( arr, 2 );\n* // returns 3.0\n*/\nfunction getFloat64( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Float32Array`.\n*\n* @private\n* @param {Float32Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Float32Array from '@stdlib/array-float32';\n*\n* var arr = new Float32Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getFloat32( arr, 2 );\n* // returns 3.0\n*/\nfunction getFloat32( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an `Int32Array`.\n*\n* @private\n* @param {Int32Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Int32Array from '@stdlib/array-int32';\n*\n* var arr = new Int32Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getInt32( arr, 2 );\n* // returns 3\n*/\nfunction getInt32( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an `Int16Array`.\n*\n* @private\n* @param {Int16Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Int16Array from '@stdlib/array-int16';\n*\n* var arr = new Int16Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getInt16( arr, 2 );\n* // returns 3\n*/\nfunction getInt16( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an `Int8Array`.\n*\n* @private\n* @param {Int8Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Int8Array from '@stdlib/array-int8';\n*\n* var arr = new Int8Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getInt8( arr, 2 );\n* // returns 3\n*/\nfunction getInt8( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint32Array`.\n*\n* @private\n* @param {Uint32Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint32Array from '@stdlib/array-uint32';\n*\n* var arr = new Uint32Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint32( arr, 2 );\n* // returns 3\n*/\nfunction getUint32( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint16Array`.\n*\n* @private\n* @param {Uint16Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint16Array from '@stdlib/array-uint16';\n*\n* var arr = new Uint16Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint16( arr, 2 );\n* // returns 3\n*/\nfunction getUint16( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint8Array`.\n*\n* @private\n* @param {Uint8Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint8Array from '@stdlib/array-uint8';\n*\n* var arr = new Uint8Array( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint8( arr, 2 );\n* // returns 3\n*/\nfunction getUint8( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a `Uint8ClampedArray`.\n*\n* @private\n* @param {Uint8ClampedArray} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {number} element value\n*\n* @example\n* import Uint8ClampedArray from '@stdlib/array-uint8c';\n*\n* var arr = new Uint8ClampedArray( [ 1, 2, 3, 4 ] );\n*\n* var v = getUint8c( arr, 2 );\n* // returns 3\n*/\nfunction getUint8c( arr, idx ) { // eslint-disable-line stdlib/jsdoc-doctest-decimal-point\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from a generic `Array`.\n*\n* @private\n* @param {Array} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {*} element value\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var v = getGeneric( arr, 2 );\n* // returns 3\n*/\nfunction getGeneric( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n/**\n* Returns an element from an indexed array-like object.\n*\n* @private\n* @param {Collection} arr - input array\n* @param {NonNegativeInteger} idx - element index\n* @returns {*} element value\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var v = getArrayLike( arr, 2 );\n* // returns 3\n*/\nfunction getArrayLike( arr, idx ) {\n\treturn arr[ idx ];\n}\n\n\n// MAIN //\n\n/**\n* Returns an accessor function for retrieving an element from an indexed array-like object.\n*\n* @param {string} dtype - array dtype\n* @returns {Function} accessor\n*\n* @example\n* import dtype from '@stdlib/array-dtype';\n*\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var get = getter( dtype( arr ) );\n* var v = get( arr, 2 );\n* // returns 3\n*/\nfunction getter( dtype ) {\n\tvar f = GETTERS[ dtype ];\n\tif ( typeof f === 'function' ) {\n\t\treturn f;\n\t}\n\treturn GETTERS.default;\n}\n\n\n// EXPORTS //\n\nexport default getter;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Object.defineProperty === 'function' ) ? Object.defineProperty : null;\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Defines (or modifies) an object property.\n*\n* ## Notes\n*\n* - Property descriptors come in two flavors: **data descriptors** and **accessor descriptors**. A data descriptor is a property that has a value, which may or may not be writable. An accessor descriptor is a property described by a getter-setter function pair. A descriptor must be one of these two flavors and cannot be both.\n*\n* @name defineProperty\n* @type {Function}\n* @param {Object} obj - object on which to define the property\n* @param {(string|symbol)} prop - property name\n* @param {Object} descriptor - property descriptor\n* @param {boolean} [descriptor.configurable=false] - boolean indicating if property descriptor can be changed and if the property can be deleted from the provided object\n* @param {boolean} [descriptor.enumerable=false] - boolean indicating if the property shows up when enumerating object properties\n* @param {boolean} [descriptor.writable=false] - boolean indicating if the value associated with the property can be changed with an assignment operator\n* @param {*} [descriptor.value] - property value\n* @param {(Function|void)} [descriptor.get=undefined] - function which serves as a getter for the property, or, if no getter, undefined. When the property is accessed, a getter function is called without arguments and with the `this` context set to the object through which the property is accessed (which may not be the object on which the property is defined due to inheritance). The return value will be used as the property value.\n* @param {(Function|void)} [descriptor.set=undefined] - function which serves as a setter for the property, or, if no setter, undefined. When assigning a property value, a setter function is called with one argument (the value being assigned to the property) and with the `this` context set to the object through which the property is assigned.\n* @throws {TypeError} first argument must be an object\n* @throws {TypeError} third argument must be an object\n* @throws {Error} property descriptor cannot have both a value and a setter and/or getter\n* @returns {Object} object with added property\n*\n* @example\n* var obj = {};\n*\n* defineProperty( obj, 'foo', {\n* 'value': 'bar'\n* });\n*\n* var str = obj.foo;\n* // returns 'bar'\n*/\nvar defineProperty = Object.defineProperty;\n\n\n// EXPORTS //\n\nexport default defineProperty;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a number primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* @example\n* var bool = isNumber( NaN );\n* // returns true\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns false\n*/\nfunction isNumber( value ) {\n\treturn ( typeof value === 'number' ); // NOTE: we inline the `isNumber.isPrimitive` function from `@stdlib/assert/is-number` in order to avoid circular dependencies.\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// FUNCTIONS //\n\n/**\n* Tests if a string starts with a minus sign (`-`).\n*\n* @private\n* @param {string} str - input string\n* @returns {boolean} boolean indicating if a string starts with a minus sign (`-`)\n*/\nfunction startsWithMinus( str ) {\n\treturn str[ 0 ] === '-';\n}\n\n/**\n* Returns a string of `n` zeros.\n*\n* @private\n* @param {number} n - number of zeros\n* @returns {string} string of zeros\n*/\nfunction zeros( n ) {\n\tvar out = '';\n\tvar i;\n\tfor ( i = 0; i < n; i++ ) {\n\t\tout += '0';\n\t}\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Pads a token with zeros to the specified width.\n*\n* @private\n* @param {string} str - token argument\n* @param {number} width - token width\n* @param {boolean} [right=false] - boolean indicating whether to pad to the right\n* @returns {string} padded token argument\n*/\nfunction zeroPad( str, width, right ) {\n\tvar negative = false;\n\tvar pad = width - str.length;\n\tif ( pad < 0 ) {\n\t\treturn str;\n\t}\n\tif ( startsWithMinus( str ) ) {\n\t\tnegative = true;\n\t\tstr = str.substr( 1 );\n\t}\n\tstr = ( right ) ?\n\t\tstr + zeros( pad ) :\n\t\tzeros( pad ) + str;\n\tif ( negative ) {\n\t\tstr = '-' + str;\n\t}\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default zeroPad;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isNumber from './is_number.js';\nimport zeroPad from './zero_pad.js';\n\n// NOTE: for the following, we explicitly avoid using stdlib packages in this particular package in order to avoid circular dependencies.\nvar lowercase = String.prototype.toLowerCase;\nvar uppercase = String.prototype.toUpperCase;\n\n\n// MAIN //\n\n/**\n* Formats a token object argument as an integer.\n*\n* @private\n* @param {Object} token - token object\n* @throws {Error} must provide a valid integer\n* @returns {string} formatted token argument\n*/\nfunction formatInteger( token ) {\n\tvar base;\n\tvar out;\n\tvar i;\n\n\tswitch ( token.specifier ) {\n\tcase 'b':\n\t\t// Case: %b (binary)\n\t\tbase = 2;\n\t\tbreak;\n\tcase 'o':\n\t\t// Case: %o (octal)\n\t\tbase = 8;\n\t\tbreak;\n\tcase 'x':\n\tcase 'X':\n\t\t// Case: %x, %X (hexadecimal)\n\t\tbase = 16;\n\t\tbreak;\n\tcase 'd':\n\tcase 'i':\n\tcase 'u':\n\tdefault:\n\t\t// Case: %d, %i, %u (decimal)\n\t\tbase = 10;\n\t\tbreak;\n\t}\n\tout = token.arg;\n\ti = parseInt( out, 10 );\n\tif ( !isFinite( i ) ) { // NOTE: We use the global `isFinite` function here instead of `@stdlib/math/base/assert/is-finite` in order to avoid circular dependencies.\n\t\tif ( !isNumber( out ) ) {\n\t\t\tthrow new Error( 'invalid integer. Value: ' + out );\n\t\t}\n\t\ti = 0;\n\t}\n\tif ( i < 0 && ( token.specifier === 'u' || base !== 10 ) ) {\n\t\ti = 0xffffffff + i + 1;\n\t}\n\tif ( i < 0 ) {\n\t\tout = ( -i ).toString( base );\n\t\tif ( token.precision ) {\n\t\t\tout = zeroPad( out, token.precision, token.padRight );\n\t\t}\n\t\tout = '-' + out;\n\t} else {\n\t\tout = i.toString( base );\n\t\tif ( !i && !token.precision ) {\n\t\t\tout = '';\n\t\t} else if ( token.precision ) {\n\t\t\tout = zeroPad( out, token.precision, token.padRight );\n\t\t}\n\t\tif ( token.sign ) {\n\t\t\tout = token.sign + out;\n\t\t}\n\t}\n\tif ( base === 16 ) {\n\t\tif ( token.alternate ) {\n\t\t\tout = '0x' + out;\n\t\t}\n\t\tout = ( token.specifier === uppercase.call( token.specifier ) ) ?\n\t\t\tuppercase.call( out ) :\n\t\t\tlowercase.call( out );\n\t}\n\tif ( base === 8 ) {\n\t\tif ( token.alternate && out.charAt( 0 ) !== '0' ) {\n\t\t\tout = '0' + out;\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default formatInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isNumber from './is_number.js';\n\n// NOTE: for the following, we explicitly avoid using stdlib packages in this particular package in order to avoid circular dependencies.\nvar abs = Math.abs; // eslint-disable-line stdlib/no-builtin-math\nvar lowercase = String.prototype.toLowerCase;\nvar uppercase = String.prototype.toUpperCase;\nvar replace = String.prototype.replace;\n\n\n// VARIABLES //\n\nvar RE_EXP_POS_DIGITS = /e\\+(\\d)$/;\nvar RE_EXP_NEG_DIGITS = /e-(\\d)$/;\nvar RE_ONLY_DIGITS = /^(\\d+)$/;\nvar RE_DIGITS_BEFORE_EXP = /^(\\d+)e/;\nvar RE_TRAILING_PERIOD_ZERO = /\\.0$/;\nvar RE_PERIOD_ZERO_EXP = /\\.0*e/;\nvar RE_ZERO_BEFORE_EXP = /(\\..*[^0])0*e/;\n\n\n// MAIN //\n\n/**\n* Formats a token object argument as a floating-point number.\n*\n* @private\n* @param {Object} token - token object\n* @throws {Error} must provide a valid floating-point number\n* @returns {string} formatted token argument\n*/\nfunction formatDouble( token ) {\n\tvar digits;\n\tvar out;\n\tvar f = parseFloat( token.arg );\n\tif ( !isFinite( f ) ) { // NOTE: We use the global `isFinite` function here instead of `@stdlib/math/base/assert/is-finite` in order to avoid circular dependencies.\n\t\tif ( !isNumber( token.arg ) ) {\n\t\t\tthrow new Error( 'invalid floating-point number. Value: ' + out );\n\t\t}\n\t\t// Case: NaN, Infinity, or -Infinity\n\t\tf = token.arg;\n\t}\n\tswitch ( token.specifier ) {\n\tcase 'e':\n\tcase 'E':\n\t\tout = f.toExponential( token.precision );\n\t\tbreak;\n\tcase 'f':\n\tcase 'F':\n\t\tout = f.toFixed( token.precision );\n\t\tbreak;\n\tcase 'g':\n\tcase 'G':\n\t\tif ( abs( f ) < 0.0001 ) {\n\t\t\tdigits = token.precision;\n\t\t\tif ( digits > 0 ) {\n\t\t\t\tdigits -= 1;\n\t\t\t}\n\t\t\tout = f.toExponential( digits );\n\t\t} else {\n\t\t\tout = f.toPrecision( token.precision );\n\t\t}\n\t\tif ( !token.alternate ) {\n\t\t\tout = replace.call( out, RE_ZERO_BEFORE_EXP, '$1e' );\n\t\t\tout = replace.call( out, RE_PERIOD_ZERO_EXP, 'e' );\n\t\t\tout = replace.call( out, RE_TRAILING_PERIOD_ZERO, '' );\n\t\t}\n\t\tbreak;\n\tdefault:\n\t\tthrow new Error( 'invalid double notation. Value: ' + token.specifier );\n\t}\n\tout = replace.call( out, RE_EXP_POS_DIGITS, 'e+0$1' );\n\tout = replace.call( out, RE_EXP_NEG_DIGITS, 'e-0$1' );\n\tif ( token.alternate ) {\n\t\tout = replace.call( out, RE_ONLY_DIGITS, '$1.' );\n\t\tout = replace.call( out, RE_DIGITS_BEFORE_EXP, '$1.e' );\n\t}\n\tif ( f >= 0 && token.sign ) {\n\t\tout = token.sign + out;\n\t}\n\tout = ( token.specifier === uppercase.call( token.specifier ) ) ?\n\t\tuppercase.call( out ) :\n\t\tlowercase.call( out );\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default formatDouble;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// FUNCTIONS //\n\n/**\n* Returns `n` spaces.\n*\n* @private\n* @param {number} n - number of spaces\n* @returns {string} string of spaces\n*/\nfunction spaces( n ) {\n\tvar out = '';\n\tvar i;\n\tfor ( i = 0; i < n; i++ ) {\n\t\tout += ' ';\n\t}\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Pads a token with spaces to the specified width.\n*\n* @private\n* @param {string} str - token argument\n* @param {number} width - token width\n* @param {boolean} [right=false] - boolean indicating whether to pad to the right\n* @returns {string} padded token argument\n*/\nfunction spacePad( str, width, right ) {\n\tvar pad = width - str.length;\n\tif ( pad < 0 ) {\n\t\treturn str;\n\t}\n\tstr = ( right ) ?\n\t\tstr + spaces( pad ) :\n\t\tspaces( pad ) + str;\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default spacePad;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport formatInteger from './format_integer.js';\nimport isString from './is_string.js';\nimport formatDouble from './format_double.js';\nimport spacePad from './space_pad.js';\nimport zeroPad from './zero_pad.js';\n\n\n// VARIABLES //\n\nvar fromCharCode = String.fromCharCode;\nvar isArray = Array.isArray; // NOTE: We use the global `Array.isArray` function here instead of `@stdlib/assert/is-array` to avoid circular dependencies.\n\n\n// FUNCTIONS //\n\n/**\n* Returns a boolean indicating whether a value is `NaN`.\n*\n* @private\n* @param {*} value - input value\n* @returns {boolean} boolean indicating whether a value is `NaN`\n*\n* @example\n* var bool = isnan( NaN );\n* // returns true\n*\n* @example\n* var bool = isnan( 4 );\n* // returns false\n*/\nfunction isnan( value ) { // explicitly define a function here instead of `@stdlib/math/base/assert/is-nan` in order to avoid circular dependencies\n\treturn ( value !== value );\n}\n\n/**\n* Initializes token object with properties of supplied format identifier object or default values if not present.\n*\n* @private\n* @param {Object} token - format identifier object\n* @returns {Object} token object\n*/\nfunction initialize( token ) {\n\tvar out = {};\n\tout.specifier = token.specifier;\n\tout.precision = ( token.precision === void 0 ) ? 1 : token.precision;\n\tout.width = token.width;\n\tout.flags = token.flags || '';\n\tout.mapping = token.mapping;\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Generates string from a token array by interpolating values.\n*\n* @param {Array} tokens - string parts and format identifier objects\n* @param {Array} ...args - variable values\n* @throws {TypeError} first argument must be an array\n* @throws {Error} invalid flags\n* @returns {string} formatted string\n*\n* @example\n* var tokens = [ 'beep ', { 'specifier': 's' } ];\n* var out = formatInterpolate( tokens, 'boop' );\n* // returns 'beep boop'\n*/\nfunction formatInterpolate( tokens ) {\n\tvar hasPeriod;\n\tvar flags;\n\tvar token;\n\tvar flag;\n\tvar num;\n\tvar out;\n\tvar pos;\n\tvar i;\n\tvar j;\n\n\tif ( !isArray( tokens ) ) {\n\t\tthrow new TypeError( 'invalid argument. First argument must be an array. Value: `' + tokens + '`.' );\n\t}\n\tout = '';\n\tpos = 1;\n\tfor ( i = 0; i < tokens.length; i++ ) {\n\t\ttoken = tokens[ i ];\n\t\tif ( isString( token ) ) {\n\t\t\tout += token;\n\t\t} else {\n\t\t\thasPeriod = token.precision !== void 0;\n\t\t\ttoken = initialize( token );\n\t\t\tif ( !token.specifier ) {\n\t\t\t\tthrow new TypeError( 'invalid argument. Token is missing `specifier` property. Index: `'+ i +'`. Value: `' + token + '`.' );\n\t\t\t}\n\t\t\tif ( token.mapping ) {\n\t\t\t\tpos = token.mapping;\n\t\t\t}\n\t\t\tflags = token.flags;\n\t\t\tfor ( j = 0; j < flags.length; j++ ) {\n\t\t\t\tflag = flags.charAt( j );\n\t\t\t\tswitch ( flag ) {\n\t\t\t\tcase ' ':\n\t\t\t\t\ttoken.sign = ' ';\n\t\t\t\t\tbreak;\n\t\t\t\tcase '+':\n\t\t\t\t\ttoken.sign = '+';\n\t\t\t\t\tbreak;\n\t\t\t\tcase '-':\n\t\t\t\t\ttoken.padRight = true;\n\t\t\t\t\ttoken.padZeros = false;\n\t\t\t\t\tbreak;\n\t\t\t\tcase '0':\n\t\t\t\t\ttoken.padZeros = flags.indexOf( '-' ) < 0; // NOTE: We use built-in `Array.prototype.indexOf` here instead of `@stdlib/assert/contains` in order to avoid circular dependencies.\n\t\t\t\t\tbreak;\n\t\t\t\tcase '#':\n\t\t\t\t\ttoken.alternate = true;\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new Error( 'invalid flag: ' + flag );\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( token.width === '*' ) {\n\t\t\t\ttoken.width = parseInt( arguments[ pos ], 10 );\n\t\t\t\tpos += 1;\n\t\t\t\tif ( isnan( token.width ) ) {\n\t\t\t\t\tthrow new TypeError( 'the argument for * width at position ' + pos + ' is not a number. Value: `' + token.width + '`.' );\n\t\t\t\t}\n\t\t\t\tif ( token.width < 0 ) {\n\t\t\t\t\ttoken.padRight = true;\n\t\t\t\t\ttoken.width = -token.width;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( hasPeriod ) {\n\t\t\t\tif ( token.precision === '*' ) {\n\t\t\t\t\ttoken.precision = parseInt( arguments[ pos ], 10 );\n\t\t\t\t\tpos += 1;\n\t\t\t\t\tif ( isnan( token.precision ) ) {\n\t\t\t\t\t\tthrow new TypeError( 'the argument for * precision at position ' + pos + ' is not a number. Value: `' + token.precision + '`.' );\n\t\t\t\t\t}\n\t\t\t\t\tif ( token.precision < 0 ) {\n\t\t\t\t\t\ttoken.precision = 1;\n\t\t\t\t\t\thasPeriod = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\ttoken.arg = arguments[ pos ];\n\t\t\tswitch ( token.specifier ) {\n\t\t\tcase 'b':\n\t\t\tcase 'o':\n\t\t\tcase 'x':\n\t\t\tcase 'X':\n\t\t\tcase 'd':\n\t\t\tcase 'i':\n\t\t\tcase 'u':\n\t\t\t\t// Case: %b (binary), %o (octal), %x, %X (hexadecimal), %d, %i (decimal), %u (unsigned decimal)\n\t\t\t\tif ( hasPeriod ) {\n\t\t\t\t\ttoken.padZeros = false;\n\t\t\t\t}\n\t\t\t\ttoken.arg = formatInteger( token );\n\t\t\t\tbreak;\n\t\t\tcase 's':\n\t\t\t\t// Case: %s (string)\n\t\t\t\ttoken.maxWidth = ( hasPeriod ) ? token.precision : -1;\n\t\t\t\ttoken.arg = String( token.arg );\n\t\t\t\tbreak;\n\t\t\tcase 'c':\n\t\t\t\t// Case: %c (character)\n\t\t\t\tif ( !isnan( token.arg ) ) {\n\t\t\t\t\tnum = parseInt( token.arg, 10 );\n\t\t\t\t\tif ( num < 0 || num > 127 ) {\n\t\t\t\t\t\tthrow new Error( 'invalid character code. Value: ' + token.arg );\n\t\t\t\t\t}\n\t\t\t\t\ttoken.arg = ( isnan( num ) ) ? String( token.arg ) : fromCharCode( num ); // eslint-disable-line max-len\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'e':\n\t\t\tcase 'E':\n\t\t\tcase 'f':\n\t\t\tcase 'F':\n\t\t\tcase 'g':\n\t\t\tcase 'G':\n\t\t\t\t// Case: %e, %E (scientific notation), %f, %F (decimal floating point), %g, %G (uses the shorter of %e/E or %f/F)\n\t\t\t\tif ( !hasPeriod ) {\n\t\t\t\t\ttoken.precision = 6;\n\t\t\t\t}\n\t\t\t\ttoken.arg = formatDouble( token );\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tthrow new Error( 'invalid specifier: ' + token.specifier );\n\t\t\t}\n\t\t\t// Fit argument into field width...\n\t\t\tif ( token.maxWidth >= 0 && token.arg.length > token.maxWidth ) {\n\t\t\t\ttoken.arg = token.arg.substring( 0, token.maxWidth );\n\t\t\t}\n\t\t\tif ( token.padZeros ) {\n\t\t\t\ttoken.arg = zeroPad( token.arg, token.width || token.precision, token.padRight ); // eslint-disable-line max-len\n\t\t\t} else if ( token.width ) {\n\t\t\t\ttoken.arg = spacePad( token.arg, token.width, token.padRight );\n\t\t\t}\n\t\t\tout += token.arg || '';\n\t\t\tpos += 1;\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default formatInterpolate;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a string primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string primitive\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns false\n*/\nfunction isString( value ) {\n\treturn ( typeof value === 'string' ); // NOTE: we inline the `isString.isPrimitive` function from `@stdlib/assert/is-string` in order to avoid circular dependencies.\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar RE = /%(?:([1-9]\\d*)\\$)?([0 +\\-#]*)(\\*|\\d+)?(?:(\\.)(\\*|\\d+)?)?[hlL]?([%A-Za-z])/g;\n\n\n// FUNCTIONS //\n\n/**\n* Parses a delimiter.\n*\n* @private\n* @param {Array} match - regular expression match\n* @returns {Object} delimiter token object\n*/\nfunction parse( match ) {\n\tvar token = {\n\t\t'mapping': ( match[ 1 ] ) ? parseInt( match[ 1 ], 10 ) : void 0,\n\t\t'flags': match[ 2 ],\n\t\t'width': match[ 3 ],\n\t\t'precision': match[ 5 ],\n\t\t'specifier': match[ 6 ]\n\t};\n\tif ( match[ 4 ] === '.' && match[ 5 ] === void 0 ) {\n\t\ttoken.precision = '1';\n\t}\n\treturn token;\n}\n\n\n// MAIN //\n\n/**\n* Tokenizes a string into an array of string parts and format identifier objects.\n*\n* @param {string} str - input string\n* @returns {Array} tokens\n*\n* @example\n* var tokens = formatTokenize( 'Hello %s!' );\n* // returns [ 'Hello ', {...}, '!' ]\n*/\nfunction formatTokenize( str ) {\n\tvar content;\n\tvar tokens;\n\tvar match;\n\tvar prev;\n\n\ttokens = [];\n\tprev = 0;\n\tmatch = RE.exec( str );\n\twhile ( match ) {\n\t\tcontent = str.slice( prev, RE.lastIndex - match[ 0 ].length );\n\t\tif ( content.length ) {\n\t\t\ttokens.push( content );\n\t\t}\n\t\ttokens.push( parse( match ) );\n\t\tprev = RE.lastIndex;\n\t\tmatch = RE.exec( str );\n\t}\n\tcontent = str.slice( prev );\n\tif ( content.length ) {\n\t\ttokens.push( content );\n\t}\n\treturn tokens;\n}\n\n\n// EXPORTS //\n\nexport default formatTokenize;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport interpolate from '@stdlib/string-base-format-interpolate';\nimport tokenize from '@stdlib/string-base-format-tokenize';\nimport isString from './is_string.js';\n\n\n// MAIN //\n\n/**\n* Inserts supplied variable values into a format string.\n*\n* @param {string} str - input string\n* @param {Array} ...args - variable values\n* @throws {TypeError} first argument must be a string\n* @throws {Error} invalid flags\n* @returns {string} formatted string\n*\n* @example\n* var str = format( 'Hello %s!', 'world' );\n* // returns 'Hello world!'\n*\n* @example\n* var str = format( 'Pi: ~%.2f', 3.141592653589793 );\n* // returns 'Pi: ~3.14'\n*/\nfunction format( str ) {\n\tvar args;\n\tvar i;\n\n\tif ( !isString( str ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a string. Value: `%s`.', str ) );\n\t}\n\targs = [ tokenize( str ) ];\n\tfor ( i = 1; i < arguments.length; i++ ) {\n\t\targs.push( arguments[ i ] );\n\t}\n\treturn interpolate.apply( null, args );\n}\n\n\n// EXPORTS //\n\nexport default format;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a string primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string primitive\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns false\n*/\nfunction isString( value ) {\n\treturn ( typeof value === 'string' ); // NOTE: we inline the `isString.isPrimitive` function from `@stdlib/assert/is-string` in order to avoid circular dependencies.\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n/* eslint-disable no-underscore-dangle, no-proto */\n\n'use strict';\n\n// MODULES //\n\nimport format from '@stdlib/string-format';\n\n\n// VARIABLES //\n\nvar objectProtoype = Object.prototype;\nvar toStr = objectProtoype.toString;\nvar defineGetter = objectProtoype.__defineGetter__;\nvar defineSetter = objectProtoype.__defineSetter__;\nvar lookupGetter = objectProtoype.__lookupGetter__;\nvar lookupSetter = objectProtoype.__lookupSetter__;\n\n\n// MAIN //\n\n/**\n* Defines (or modifies) an object property.\n*\n* ## Notes\n*\n* - Property descriptors come in two flavors: **data descriptors** and **accessor descriptors**. A data descriptor is a property that has a value, which may or may not be writable. An accessor descriptor is a property described by a getter-setter function pair. A descriptor must be one of these two flavors and cannot be both.\n*\n* @param {Object} obj - object on which to define the property\n* @param {string} prop - property name\n* @param {Object} descriptor - property descriptor\n* @param {boolean} [descriptor.configurable=false] - boolean indicating if property descriptor can be changed and if the property can be deleted from the provided object\n* @param {boolean} [descriptor.enumerable=false] - boolean indicating if the property shows up when enumerating object properties\n* @param {boolean} [descriptor.writable=false] - boolean indicating if the value associated with the property can be changed with an assignment operator\n* @param {*} [descriptor.value] - property value\n* @param {(Function|void)} [descriptor.get=undefined] - function which serves as a getter for the property, or, if no getter, undefined. When the property is accessed, a getter function is called without arguments and with the `this` context set to the object through which the property is accessed (which may not be the object on which the property is defined due to inheritance). The return value will be used as the property value.\n* @param {(Function|void)} [descriptor.set=undefined] - function which serves as a setter for the property, or, if no setter, undefined. When assigning a property value, a setter function is called with one argument (the value being assigned to the property) and with the `this` context set to the object through which the property is assigned.\n* @throws {TypeError} first argument must be an object\n* @throws {TypeError} third argument must be an object\n* @throws {Error} property descriptor cannot have both a value and a setter and/or getter\n* @returns {Object} object with added property\n*\n* @example\n* var obj = {};\n*\n* defineProperty( obj, 'foo', {\n* 'value': 'bar'\n* });\n*\n* var str = obj.foo;\n* // returns 'bar'\n*/\nfunction defineProperty( obj, prop, descriptor ) {\n\tvar prototype;\n\tvar hasValue;\n\tvar hasGet;\n\tvar hasSet;\n\n\tif ( typeof obj !== 'object' || obj === null || toStr.call( obj ) === '[object Array]' ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be an object. Value: `%s`.', obj ) );\n\t}\n\tif ( typeof descriptor !== 'object' || descriptor === null || toStr.call( descriptor ) === '[object Array]' ) {\n\t\tthrow new TypeError( format( 'invalid argument. Property descriptor must be an object. Value: `%s`.', descriptor ) );\n\t}\n\thasValue = ( 'value' in descriptor );\n\tif ( hasValue ) {\n\t\tif (\n\t\t\tlookupGetter.call( obj, prop ) ||\n\t\t\tlookupSetter.call( obj, prop )\n\t\t) {\n\t\t\t// Override `__proto__` to avoid touching inherited accessors:\n\t\t\tprototype = obj.__proto__;\n\t\t\tobj.__proto__ = objectProtoype;\n\n\t\t\t// Delete property as existing getters/setters prevent assigning value to specified property:\n\t\t\tdelete obj[ prop ];\n\t\t\tobj[ prop ] = descriptor.value;\n\n\t\t\t// Restore original prototype:\n\t\t\tobj.__proto__ = prototype;\n\t\t} else {\n\t\t\tobj[ prop ] = descriptor.value;\n\t\t}\n\t}\n\thasGet = ( 'get' in descriptor );\n\thasSet = ( 'set' in descriptor );\n\n\tif ( hasValue && ( hasGet || hasSet ) ) {\n\t\tthrow new Error( 'invalid argument. Cannot specify one or more accessors and a value or writable attribute in the property descriptor.' );\n\t}\n\n\tif ( hasGet && defineGetter ) {\n\t\tdefineGetter.call( obj, prop, descriptor.get );\n\t}\n\tif ( hasSet && defineSetter ) {\n\t\tdefineSetter.call( obj, prop, descriptor.set );\n\t}\n\treturn obj;\n}\n\n\n// EXPORTS //\n\nexport default defineProperty;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Define (or modify) an object property.\n*\n* @module @stdlib/utils-define-property\n*\n* @example\n* import defineProperty from '@stdlib/utils-define-property';\n*\n* var obj = {};\n* defineProperty( obj, 'foo', {\n* 'value': 'bar',\n* 'writable': false,\n* 'configurable': false,\n* 'enumerable': false\n* });\n* obj.foo = 'boop'; // => throws\n*/\n\n// MODULES //\n\nimport hasDefinePropertySupport from './has_define_property_support.js';\nimport builtin from './builtin.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar defineProperty;\nif ( hasDefinePropertySupport() ) {\n\tdefineProperty = builtin;\n} else {\n\tdefineProperty = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default defineProperty;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport defineProperty from './define_property.js';\n\n\n// MAIN //\n\n/**\n* Tests for `Object.defineProperty` support.\n*\n* @private\n* @returns {boolean} boolean indicating if an environment has `Object.defineProperty` support\n*\n* @example\n* var bool = hasDefinePropertySupport();\n* // returns <boolean>\n*/\nfunction hasDefinePropertySupport() {\n\t// Test basic support...\n\ttry {\n\t\tdefineProperty( {}, 'x', {} );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default hasDefinePropertySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport defineProperty from '@stdlib/utils-define-property';\n\n\n// MAIN //\n\n/**\n* Defines a non-enumerable read-only property.\n*\n* @param {Object} obj - object on which to define the property\n* @param {(string|symbol)} prop - property name\n* @param {*} value - value to set\n*\n* @example\n* var obj = {};\n*\n* setNonEnumerableReadOnly( obj, 'foo', 'bar' );\n*\n* try {\n* obj.foo = 'boop';\n* } catch ( err ) {\n* console.error( err.message );\n* }\n*/\nfunction setNonEnumerableReadOnly( obj, prop, value ) {\n\tdefineProperty( obj, prop, {\n\t\t'configurable': false,\n\t\t'enumerable': false,\n\t\t'writable': false,\n\t\t'value': value\n\t});\n}\n\n\n// EXPORTS //\n\nexport default setNonEnumerableReadOnly;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is object-like.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether a value is object-like\n*\n* @example\n* var bool = isObjectLike( {} );\n* // returns true\n*\n* @example\n* var bool = isObjectLike( [] );\n* // returns true\n*\n* @example\n* var bool = isObjectLike( null );\n* // returns false\n*/\nfunction isObjectLike( value ) {\n\treturn (\n\t\tvalue !== null &&\n\t\ttypeof value === 'object'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isObjectLike;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isObjectLike from '@stdlib/assert-is-object-like';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Buffer instance.\n*\n* @param {*} value - value to validate\n* @returns {boolean} boolean indicating if a value is a Buffer instance\n*\n* @example\n* var v = isBuffer( new Buffer( 'beep' ) );\n* // returns true\n*\n* @example\n* var v = isBuffer( new Buffer( [1,2,3,4] ) );\n* // returns true\n*\n* @example\n* var v = isBuffer( {} );\n* // returns false\n*\n* @example\n* var v = isBuffer( [] );\n* // returns false\n*/\nfunction isBuffer( value ) {\n\treturn (\n\t\tisObjectLike( value ) &&\n\t\t(\n\t\t\t// eslint-disable-next-line no-underscore-dangle\n\t\t\tvalue._isBuffer || // for envs missing Object.prototype.constructor (e.g., Safari 5-7)\n\t\t\t(\n\t\t\t\tvalue.constructor &&\n\n\t\t\t\t// WARNING: `typeof` is not a foolproof check, as certain envs consider RegExp and NodeList instances to be functions\n\t\t\t\ttypeof value.constructor.isBuffer === 'function' &&\n\t\t\t\tvalue.constructor.isBuffer( value )\n\t\t\t)\n\t\t)\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isBuffer;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Returns a regular expression to capture everything that is not a space immediately after the `function` keyword and before the first left parenthesis.\n*\n* @returns {RegExp} regular expression\n*\n* @example\n* var RE_FUNCTION_NAME = reFunctionName();\n*\n* function fname( fcn ) {\n* return RE_FUNCTION_NAME.exec( fcn.toString() )[ 1 ];\n* }\n*\n* var fn = fname( Math.sqrt );\n* // returns 'sqrt'\n*\n* fn = fname( Int8Array );\n* // returns 'Int8Array'\n*\n* fn = fname( Object.prototype.toString );\n* // returns 'toString'\n*\n* fn = fname( function(){} );\n* // returns ''\n*/\nfunction reFunctionName() {\n\treturn /^\\s*function\\s*([^(]*)/i;\n}\n\n\n// EXPORTS //\n\nexport default reFunctionName;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is object-like.\n*\n* @module @stdlib/assert-is-object-like\n*\n* @example\n* import isObjectLike from '@stdlib/assert-is-object-like';\n*\n* var bool = isObjectLike( {} );\n* // returns true\n*\n* bool = isObjectLike( [] );\n* // returns true\n*\n* bool = isObjectLike( null );\n* // returns false\n*\n* @example\n* import { isObjectLikeArray as isObjectLike } from '@stdlib/assert-is-object-like';\n*\n* var bool = isObjectLike( [ {}, [] ] );\n* // returns true\n*\n* bool = isObjectLike( [ {}, '3.0' ] );\n* // returns false\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport arrayfun from '@stdlib/assert-tools-array-function';\nimport main from './main.js';\n\n\n// VARIABLES //\n\nvar isObjectLikeArray = arrayfun( main );\n\n\n// MAIN //\n\nsetReadOnly( main, 'isObjectLikeArray', isObjectLikeArray );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArray from '@stdlib/assert-is-array';\nimport format from '@stdlib/string-format';\n\n\n// MAIN //\n\n/**\n* Returns a function which tests if every element in an array passes a test condition.\n*\n* @param {Function} predicate - function to apply\n* @throws {TypeError} must provide a function\n* @returns {Function} an array function\n*\n* @example\n* import isOdd from '@stdlib/assert-is-odd';\n*\n* var arr1 = [ 1, 3, 5, 7 ];\n* var arr2 = [ 3, 5, 8 ];\n*\n* var validate = arrayfcn( isOdd );\n*\n* var bool = validate( arr1 );\n* // returns true\n*\n* bool = validate( arr2 );\n* // returns false\n*/\nfunction arrayfcn( predicate ) {\n\tif ( typeof predicate !== 'function' ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide a function. Value: `%s`.', predicate ) );\n\t}\n\treturn every;\n\n\t/**\n\t* Tests if every element in an array passes a test condition.\n\t*\n\t* @private\n\t* @param {*} value - value to test\n\t* @returns {boolean} boolean indicating whether a value is an array for which all elements pass a test condition\n\t*/\n\tfunction every( value ) {\n\t\tvar len;\n\t\tvar i;\n\t\tif ( !isArray( value ) ) {\n\t\t\treturn false;\n\t\t}\n\t\tlen = value.length;\n\t\tif ( len === 0 ) {\n\t\t\treturn false;\n\t\t}\n\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\tif ( predicate( value[ i ] ) === false ) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default arrayfcn;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport reFunctionName from './main.js';\n\n\n// MAIN //\n\n/**\n* Captures everything that is not a space immediately after the `function` keyword and before the first left parenthesis.\n*\n* Regular expression: `/^\\s*function\\s*([^(]*)/i`\n*\n* - `/^\\s*`\n* - Match zero or more spaces at beginning\n*\n* - `function`\n* - Match the word `function`\n*\n* - `\\s*`\n* - Match zero or more spaces after the word `function`\n*\n* - `()`\n* - Capture\n*\n* - `[^(]*`\n* - Match anything except a left parenthesis `(` zero or more times\n*\n* - `/i`\n* - ignore case\n*\n* @constant\n* @type {RegExp}\n* @default /^\\s*function\\s*([^(]*)/i\n*/\nvar RE_FUNCTION_NAME = reFunctionName();\n\n\n// EXPORTS //\n\nexport default RE_FUNCTION_NAME;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\nimport { REGEXP as RE } from '@stdlib/regexp-function-name';\nimport isBuffer from '@stdlib/assert-is-buffer';\n\n\n// MAIN //\n\n/**\n* Determines the name of a value's constructor.\n*\n* @param {*} v - input value\n* @returns {string} name of a value's constructor\n*\n* @example\n* var v = constructorName( 'a' );\n* // returns 'String'\n*\n* @example\n* var v = constructorName( 5 );\n* // returns 'Number'\n*\n* @example\n* var v = constructorName( null );\n* // returns 'Null'\n*\n* @example\n* var v = constructorName( undefined );\n* // returns 'Undefined'\n*\n* @example\n* var v = constructorName( function noop() {} );\n* // returns 'Function'\n*/\nfunction constructorName( v ) {\n\tvar match;\n\tvar name;\n\tvar ctor;\n\tname = nativeClass( v ).slice( 8, -1 );\n\tif ( (name === 'Object' || name === 'Error') && v.constructor ) {\n\t\tctor = v.constructor;\n\t\tif ( typeof ctor.name === 'string' ) {\n\t\t\treturn ctor.name;\n\t\t}\n\t\tmatch = RE.exec( ctor.toString() );\n\t\tif ( match ) {\n\t\t\treturn match[ 1 ];\n\t\t}\n\t}\n\tif ( isBuffer( v ) ) {\n\t\treturn 'Buffer';\n\t}\n\treturn name;\n}\n\n\n// EXPORTS //\n\nexport default constructorName;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Regular expression to capture everything that is not a space immediately after the `function` keyword and before the first left parenthesis.\n*\n* @module @stdlib/regexp-function-name\n*\n* @example\n* import reFunctionName from '@stdlib/regexp-function-name';\n* var RE_FUNCTION_NAME = reFunctionName();\n*\n* function fname( fcn ) {\n* return RE_FUNCTION_NAME.exec( fcn.toString() )[ 1 ];\n* }\n*\n* var fn = fname( Math.sqrt );\n* // returns 'sqrt'\n*\n* fn = fname( Int8Array );\n* // returns 'Int8Array'\n*\n* fn = fname( Object.prototype.toString );\n* // returns 'toString'\n*\n* fn = fname( function(){} );\n* // returns ''\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport REGEXP from './regexp.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'REGEXP', REGEXP );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n// Mapping from array constructors to data types...\nvar ctor2dtypes = {\n\t'Float32Array': 'float32',\n\t'Float64Array': 'float64',\n\t'Array': 'generic',\n\t'Int16Array': 'int16',\n\t'Int32Array': 'int32',\n\t'Int8Array': 'int8',\n\t'Uint16Array': 'uint16',\n\t'Uint32Array': 'uint32',\n\t'Uint8Array': 'uint8',\n\t'Uint8ClampedArray': 'uint8c',\n\t'Complex64Array': 'complex64',\n\t'Complex128Array': 'complex128'\n};\n\n\n// EXPORTS //\n\nexport default ctor2dtypes;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasFloat64Array = ( typeof Float64Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Float64Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Float64Array\n*\n* @example\n* var bool = isFloat64Array( new Float64Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isFloat64Array( [] );\n* // returns false\n*/\nfunction isFloat64Array( value ) {\n\treturn (\n\t\t( hasFloat64Array && value instanceof Float64Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Float64Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isFloat64Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Float64Array === 'function' ) ? Float64Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Float64Array === 'function' ) ? Float64Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of double-precision floating-point numbers in the platform byte order.\n*\n* @module @stdlib/array-float64\n*\n* @example\n* import ctor from '@stdlib/array-float64';\n*\n* var arr = new ctor( 10 );\n* // returns <Float64Array>\n*/\n\n// MODULES //\n\nimport hasFloat64ArraySupport from '@stdlib/assert-has-float64array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasFloat64ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isFloat64Array from '@stdlib/assert-is-float64array';\nimport GlobalFloat64Array from './float64array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Float64Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Float64Array` support\n*\n* @example\n* var bool = hasFloat64ArraySupport();\n* // returns <boolean>\n*/\nfunction hasFloat64ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalFloat64Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalFloat64Array( [ 1.0, 3.14, -3.14, NaN ] );\n\t\tbool = (\n\t\t\tisFloat64Array( arr ) &&\n\t\t\tarr[ 0 ] === 1.0 &&\n\t\t\tarr[ 1 ] === 3.14 &&\n\t\t\tarr[ 2 ] === -3.14 &&\n\t\t\tarr[ 3 ] !== arr[ 3 ]\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasFloat64ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of double-precision floating-point numbers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasFloat32Array = ( typeof Float32Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Float32Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Float32Array\n*\n* @example\n* var bool = isFloat32Array( new Float32Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isFloat32Array( [] );\n* // returns false\n*/\nfunction isFloat32Array( value ) {\n\treturn (\n\t\t( hasFloat32Array && value instanceof Float32Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Float32Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isFloat32Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Double-precision floating-point positive infinity.\n*\n* @module @stdlib/constants-float64-pinf\n* @type {number}\n*\n* @example\n* import FLOAT64_PINF from '@stdlib/constants-float64-pinf';\n* // returns Infinity\n*/\n\n\n// MAIN //\n\n/**\n* Double-precision floating-point positive infinity.\n*\n* ## Notes\n*\n* Double-precision floating-point positive infinity has the bit sequence\n*\n* ```binarystring\n* 0 11111111111 00000000000000000000 00000000000000000000000000000000\n* ```\n*\n* @constant\n* @type {number}\n* @default Number.POSITIVE_INFINITY\n* @see [IEEE 754]{@link https://en.wikipedia.org/wiki/IEEE_754-1985}\n*/\nvar FLOAT64_PINF = Number.POSITIVE_INFINITY; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default FLOAT64_PINF;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Float32Array === 'function' ) ? Float32Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Float32Array === 'function' ) ? Float32Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of single-precision floating-point numbers in the platform byte order.\n*\n* @module @stdlib/array-float32\n*\n* @example\n* import ctor from '@stdlib/array-float32';\n*\n* var arr = new ctor( 10 );\n* // returns <Float32Array>\n*/\n\n// MODULES //\n\nimport hasFloat32ArraySupport from '@stdlib/assert-has-float32array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasFloat32ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isFloat32Array from '@stdlib/assert-is-float32array';\nimport PINF from '@stdlib/constants-float64-pinf';\nimport GlobalFloat32Array from './float32array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Float32Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Float32Array` support\n*\n* @example\n* var bool = hasFloat32ArraySupport();\n* // returns <boolean>\n*/\nfunction hasFloat32ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalFloat32Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalFloat32Array( [ 1.0, 3.14, -3.14, 5.0e40 ] );\n\t\tbool = (\n\t\t\tisFloat32Array( arr ) &&\n\t\t\tarr[ 0 ] === 1.0 &&\n\t\t\tarr[ 1 ] === 3.140000104904175 &&\n\t\t\tarr[ 2 ] === -3.140000104904175 &&\n\t\t\tarr[ 3 ] === PINF\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasFloat32ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of single-precision floating-point numbers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint32Array = ( typeof Uint32Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint32Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint32Array\n*\n* @example\n* var bool = isUint32Array( new Uint32Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint32Array( [] );\n* // returns false\n*/\nfunction isUint32Array( value ) {\n\treturn (\n\t\t( hasUint32Array && value instanceof Uint32Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint32Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint32Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum unsigned 32-bit integer.\n*\n* @module @stdlib/constants-uint32-max\n* @type {uinteger32}\n*\n* @example\n* import UINT32_MAX from '@stdlib/constants-uint32-max';\n* // returns 4294967295\n*/\n\n\n// MAIN //\n\n/**\n* Maximum unsigned 32-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* 2^{32} - 1\n* ```\n*\n* which corresponds to the bit sequence\n*\n* ```binarystring\n* 11111111111111111111111111111111\n* ```\n*\n* @constant\n* @type {uinteger32}\n* @default 4294967295\n*/\nvar UINT32_MAX = 4294967295;\n\n\n// EXPORTS //\n\nexport default UINT32_MAX;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint32Array === 'function' ) ? Uint32Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint32Array === 'function' ) ? Uint32Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 32-bit unsigned integers in the platform byte order.\n*\n* @module @stdlib/array-uint32\n*\n* @example\n* import ctor from '@stdlib/array-uint32';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint32Array>\n*/\n\n// MODULES //\n\nimport hasUint32ArraySupport from '@stdlib/assert-has-uint32array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint32ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint32Array from '@stdlib/assert-is-uint32array';\nimport UINT32_MAX from '@stdlib/constants-uint32-max';\nimport GlobalUint32Array from './uint32array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint32Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint32Array` support\n*\n* @example\n* var bool = hasUint32ArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint32ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint32Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = [ 1, 3.14, -3.14, UINT32_MAX+1, UINT32_MAX+2 ];\n\t\tarr = new GlobalUint32Array( arr );\n\t\tbool = (\n\t\t\tisUint32Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === UINT32_MAX-2 && // truncation and wrap around\n\t\t\tarr[ 3 ] === 0 && // wrap around\n\t\t\tarr[ 4 ] === 1 // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint32ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 32-bit unsigned integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasInt32Array = ( typeof Int32Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an Int32Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an Int32Array\n*\n* @example\n* var bool = isInt32Array( new Int32Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isInt32Array( [] );\n* // returns false\n*/\nfunction isInt32Array( value ) {\n\treturn (\n\t\t( hasInt32Array && value instanceof Int32Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Int32Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInt32Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum signed 32-bit integer.\n*\n* @module @stdlib/constants-int32-max\n* @type {integer32}\n*\n* @example\n* import INT32_MAX from '@stdlib/constants-int32-max';\n* // returns 2147483647\n*/\n\n\n// MAIN //\n\n/**\n* Maximum signed 32-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* 2^{31} - 1\n* ```\n*\n* which corresponds to the bit sequence\n*\n* ```binarystring\n* 01111111111111111111111111111111\n* ```\n*\n* @constant\n* @type {integer32}\n* @default 2147483647\n*/\nvar INT32_MAX = 2147483647|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT32_MAX;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Int32Array === 'function' ) ? Int32Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Int32Array === 'function' ) ? Int32Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of twos-complement 32-bit signed integers in the platform byte order.\n*\n* @module @stdlib/array-int32\n*\n* @example\n* import ctor from '@stdlib/array-int32';\n*\n* var arr = new ctor( 10 );\n* // returns <Int32Array>\n*/\n\n// MODULES //\n\nimport hasInt32ArraySupport from '@stdlib/assert-has-int32array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasInt32ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInt32Array from '@stdlib/assert-is-int32array';\nimport INT32_MAX from '@stdlib/constants-int32-max';\nimport INT32_MIN from '@stdlib/constants-int32-min';\nimport GlobalInt32Array from './int32array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Int32Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Int32Array` support\n*\n* @example\n* var bool = hasInt32ArraySupport();\n* // returns <boolean>\n*/\nfunction hasInt32ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalInt32Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalInt32Array( [ 1, 3.14, -3.14, INT32_MAX+1 ] );\n\t\tbool = (\n\t\t\tisInt32Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === -3 && // truncation\n\t\t\tarr[ 3 ] === INT32_MIN // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasInt32ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Minimum signed 32-bit integer.\n*\n* @module @stdlib/constants-int32-min\n* @type {integer32}\n*\n* @example\n* import INT32_MIN from '@stdlib/constants-int32-min';\n* // returns -2147483648\n*/\n\n\n// MAIN //\n\n/**\n* Minimum signed 32-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* -(2^{31})\n* ```\n*\n* which corresponds to the two's complement bit sequence\n*\n* ```binarystring\n* 10000000000000000000000000000000\n* ```\n*\n* @constant\n* @type {integer32}\n* @default -2147483648\n*/\nvar INT32_MIN = -2147483648|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT32_MIN;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of twos-complement 32-bit signed integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint16Array = ( typeof Uint16Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint16Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint16Array\n*\n* @example\n* var bool = isUint16Array( new Uint16Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint16Array( [] );\n* // returns false\n*/\nfunction isUint16Array( value ) {\n\treturn (\n\t\t( hasUint16Array && value instanceof Uint16Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint16Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint16Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum unsigned 16-bit integer.\n*\n* @module @stdlib/constants-uint16-max\n* @type {integer32}\n*\n* @example\n* import UINT16_MAX from '@stdlib/constants-uint16-max';\n* // returns 65535\n*/\n\n\n// MAIN //\n\n/**\n* Maximum unsigned 16-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* 2^{16} - 1\n* ```\n*\n* which corresponds to the bit sequence\n*\n* ```binarystring\n* 1111111111111111\n* ```\n*\n* @constant\n* @type {integer32}\n* @default 65535\n*/\nvar UINT16_MAX = 65535|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default UINT16_MAX;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint16Array === 'function' ) ? Uint16Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint16Array === 'function' ) ? Uint16Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 16-bit unsigned integers in the platform byte order.\n*\n* @module @stdlib/array-uint16\n*\n* @example\n* import ctor from '@stdlib/array-uint16';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint16Array>\n*/\n\n// MODULES //\n\nimport hasUint16ArraySupport from '@stdlib/assert-has-uint16array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint16ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint16Array from '@stdlib/assert-is-uint16array';\nimport UINT16_MAX from '@stdlib/constants-uint16-max';\nimport GlobalUint16Array from './uint16array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint16Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint16Array` support\n*\n* @example\n* var bool = hasUint16ArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint16ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint16Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = [ 1, 3.14, -3.14, UINT16_MAX+1, UINT16_MAX+2 ];\n\t\tarr = new GlobalUint16Array( arr );\n\t\tbool = (\n\t\t\tisUint16Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === UINT16_MAX-2 && // truncation and wrap around\n\t\t\tarr[ 3 ] === 0 && // wrap around\n\t\t\tarr[ 4 ] === 1 // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint16ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 16-bit unsigned integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasInt16Array = ( typeof Int16Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an Int16Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an Int16Array\n*\n* @example\n* var bool = isInt16Array( new Int16Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isInt16Array( [] );\n* // returns false\n*/\nfunction isInt16Array( value ) {\n\treturn (\n\t\t( hasInt16Array && value instanceof Int16Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Int16Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInt16Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum signed 16-bit integer.\n*\n* @module @stdlib/constants-int16-max\n* @type {integer32}\n*\n* @example\n* import INT16_MAX from '@stdlib/constants-int16-max';\n* // returns 32767\n*/\n\n\n// MAIN //\n\n/**\n* Maximum signed 16-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* 2^{15} - 1\n* ```\n*\n* which corresponds to the bit sequence\n*\n* ```binarystring\n* 0111111111111111\n* ```\n*\n* @constant\n* @type {integer32}\n* @default 32767\n*/\nvar INT16_MAX = 32767|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT16_MAX;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Int16Array === 'function' ) ? Int16Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Int16Array === 'function' ) ? Int16Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of twos-complement 16-bit signed integers in the platform byte order.\n*\n* @module @stdlib/array-int16\n*\n* @example\n* import ctor from '@stdlib/array-int16';\n*\n* var arr = new ctor( 10 );\n* // returns <Int16Array>\n*/\n\n// MODULES //\n\nimport hasInt16ArraySupport from '@stdlib/assert-has-int16array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasInt16ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInt16Array from '@stdlib/assert-is-int16array';\nimport INT16_MAX from '@stdlib/constants-int16-max';\nimport INT16_MIN from '@stdlib/constants-int16-min';\nimport GlobalInt16Array from './int16array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Int16Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Int16Array` support\n*\n* @example\n* var bool = hasInt16ArraySupport();\n* // returns <boolean>\n*/\nfunction hasInt16ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalInt16Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalInt16Array( [ 1, 3.14, -3.14, INT16_MAX+1 ] );\n\t\tbool = (\n\t\t\tisInt16Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === -3 && // truncation\n\t\t\tarr[ 3 ] === INT16_MIN // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasInt16ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Minimum signed 16-bit integer.\n*\n* @module @stdlib/constants-int16-min\n* @type {integer32}\n*\n* @example\n* import INT16_MIN from '@stdlib/constants-int16-min';\n* // returns -32768\n*/\n\n\n// MAIN //\n\n/**\n* Minimum signed 16-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* -(2^{15})\n* ```\n*\n* which corresponds to the two's complement bit sequence\n*\n* ```binarystring\n* 1000000000000000\n* ```\n*\n* @constant\n* @type {integer32}\n* @default -32768\n*/\nvar INT16_MIN = -32768|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT16_MIN;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of twos-complement 16-bit signed integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint8Array = ( typeof Uint8Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint8Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint8Array\n*\n* @example\n* var bool = isUint8Array( new Uint8Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint8Array( [] );\n* // returns false\n*/\nfunction isUint8Array( value ) {\n\treturn (\n\t\t( hasUint8Array && value instanceof Uint8Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint8Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint8Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum unsigned 8-bit integer.\n*\n* @module @stdlib/constants-uint8-max\n* @type {integer32}\n*\n* @example\n* import UINT8_MAX from '@stdlib/constants-uint8-max';\n* // returns 255\n*/\n\n\n// MAIN //\n\n/**\n* Maximum unsigned 8-bit integer.\n*\n* ## Notes\n*\n* The number has the value\n*\n* ```tex\n* 2^{8} - 1\n* ```\n*\n* which corresponds to the bit sequence\n*\n* ```binarystring\n* 11111111\n* ```\n*\n* @constant\n* @type {integer32}\n* @default 255\n*/\nvar UINT8_MAX = 255|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default UINT8_MAX;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint8Array === 'function' ) ? Uint8Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint8Array === 'function' ) ? Uint8Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 8-bit unsigned integers in the platform byte order.\n*\n* @module @stdlib/array-uint8\n*\n* @example\n* import ctor from '@stdlib/array-uint8';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint8Array>\n*/\n\n// MODULES //\n\nimport hasUint8ArraySupport from '@stdlib/assert-has-uint8array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint8ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint8Array from '@stdlib/assert-is-uint8array';\nimport UINT8_MAX from '@stdlib/constants-uint8-max';\nimport GlobalUint8Array from './uint8array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint8Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint8Array` support\n*\n* @example\n* var bool = hasUint8ArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint8ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint8Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = [ 1, 3.14, -3.14, UINT8_MAX+1, UINT8_MAX+2 ];\n\t\tarr = new GlobalUint8Array( arr );\n\t\tbool = (\n\t\t\tisUint8Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === UINT8_MAX-2 && // truncation and wrap around\n\t\t\tarr[ 3 ] === 0 && // wrap around\n\t\t\tarr[ 4 ] === 1 // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint8ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 8-bit unsigned integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasUint8ClampedArray = ( typeof Uint8ClampedArray === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is a Uint8ClampedArray.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a Uint8ClampedArray\n*\n* @example\n* var bool = isUint8ClampedArray( new Uint8ClampedArray( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isUint8ClampedArray( [] );\n* // returns false\n*/\nfunction isUint8ClampedArray( value ) {\n\treturn (\n\t\t( hasUint8ClampedArray && value instanceof Uint8ClampedArray ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Uint8ClampedArray]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isUint8ClampedArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Uint8ClampedArray === 'function' ) ? Uint8ClampedArray : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Uint8ClampedArray === 'function' ) ? Uint8ClampedArray : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 8-bit unsigned integers in the platform byte order clamped to 0-255.\n*\n* @module @stdlib/array-uint8c\n*\n* @example\n* import ctor from '@stdlib/array-uint8c';\n*\n* var arr = new ctor( 10 );\n* // returns <Uint8ClampedArray>\n*/\n\n// MODULES //\n\nimport hasUint8ClampedArraySupport from '@stdlib/assert-has-uint8clampedarray-support'; // eslint-disable-line id-length\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasUint8ClampedArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isUint8ClampedArray from '@stdlib/assert-is-uint8clampedarray';\nimport GlobalUint8ClampedArray from './uint8clampedarray.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Uint8ClampedArray` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Uint8ClampedArray` support\n*\n* @example\n* var bool = hasUint8ClampedArraySupport();\n* // returns <boolean>\n*/\nfunction hasUint8ClampedArraySupport() { // eslint-disable-line id-length\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalUint8ClampedArray !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalUint8ClampedArray( [ -1, 0, 1, 3.14, 4.99, 255, 256 ] );\n\t\tbool = (\n\t\t\tisUint8ClampedArray( arr ) &&\n\t\t\tarr[ 0 ] === 0 && // clamped\n\t\t\tarr[ 1 ] === 0 &&\n\t\t\tarr[ 2 ] === 1 &&\n\t\t\tarr[ 3 ] === 3 && // round to nearest\n\t\t\tarr[ 4 ] === 5 && // round to nearest\n\t\t\tarr[ 5 ] === 255 &&\n\t\t\tarr[ 6 ] === 255 // clamped\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasUint8ClampedArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of 8-bit unsigned integers in the platform byte order clamped to 0-255.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasInt8Array = ( typeof Int8Array === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an Int8Array.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an Int8Array\n*\n* @example\n* var bool = isInt8Array( new Int8Array( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isInt8Array( [] );\n* // returns false\n*/\nfunction isInt8Array( value ) {\n\treturn (\n\t\t( hasInt8Array && value instanceof Int8Array ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object Int8Array]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInt8Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum signed 8-bit integer.\n*\n* @module @stdlib/constants-int8-max\n* @type {integer32}\n*\n* @example\n* import INT8_MAX from '@stdlib/constants-int8-max';\n* // returns 127\n*/\n\n\n// MAIN //\n\n/**\n* Maximum signed 8-bit integer.\n*\n* ## Notes\n*\n* The number is given by\n*\n* ```tex\n* 2^{7} - 1\n* ```\n*\n* which corresponds to the bit sequence\n*\n* ```binarystring\n* 01111111\n* ```\n*\n* @constant\n* @type {integer32}\n* @default 127\n*/\nvar INT8_MAX = 127|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT8_MAX;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar main = ( typeof Int8Array === 'function' ) ? Int8Array : null; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar ctor = ( typeof Int8Array === 'function' ) ? Int8Array : void 0; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of twos-complement 8-bit signed integers in the platform byte order.\n*\n* @module @stdlib/array-int8\n*\n* @example\n* import ctor from '@stdlib/array-int8';\n*\n* var arr = new ctor( 10 );\n* // returns <Int8Array>\n*/\n\n// MODULES //\n\nimport hasInt8ArraySupport from '@stdlib/assert-has-int8array-support';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar ctor;\nif ( hasInt8ArraySupport() ) {\n\tctor = builtin;\n} else {\n\tctor = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default ctor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInt8Array from '@stdlib/assert-is-int8array';\nimport INT8_MAX from '@stdlib/constants-int8-max';\nimport INT8_MIN from '@stdlib/constants-int8-min';\nimport GlobalInt8Array from './int8array.js';\n\n\n// MAIN //\n\n/**\n* Tests for native `Int8Array` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Int8Array` support\n*\n* @example\n* var bool = hasInt8ArraySupport();\n* // returns <boolean>\n*/\nfunction hasInt8ArraySupport() {\n\tvar bool;\n\tvar arr;\n\n\tif ( typeof GlobalInt8Array !== 'function' ) {\n\t\treturn false;\n\t}\n\t// Test basic support...\n\ttry {\n\t\tarr = new GlobalInt8Array( [ 1, 3.14, -3.14, INT8_MAX+1 ] );\n\t\tbool = (\n\t\t\tisInt8Array( arr ) &&\n\t\t\tarr[ 0 ] === 1 &&\n\t\t\tarr[ 1 ] === 3 && // truncation\n\t\t\tarr[ 2 ] === -3 && // truncation\n\t\t\tarr[ 3 ] === INT8_MIN // wrap around\n\t\t);\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\tbool = false;\n\t}\n\treturn bool;\n}\n\n\n// EXPORTS //\n\nexport default hasInt8ArraySupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Minimum signed 8-bit integer.\n*\n* @module @stdlib/constants-int8-min\n* @type {integer32}\n*\n* @example\n* import INT8_MIN from '@stdlib/constants-int8-min';\n* // returns -128\n*/\n\n\n// MAIN //\n\n/**\n* Minimum signed 8-bit integer.\n*\n* ## Notes\n*\n* The number is given by\n*\n* ```tex\n* -(2^{7})\n* ```\n*\n* which corresponds to the two's complement bit sequence\n*\n* ```binarystring\n* 10000000\n* ```\n*\n* @constant\n* @type {integer32}\n* @default -128\n*/\nvar INT8_MIN = -128|0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default INT8_MIN;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: write polyfill\n\n// MAIN //\n\n/**\n* Typed array which represents an array of twos-complement 8-bit signed integers in the platform byte order.\n*\n* @throws {Error} not implemented\n*/\nfunction polyfill() {\n\tthrow new Error( 'not implemented' );\n}\n\n\n// EXPORTS //\n\nexport default polyfill;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a number primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* @example\n* var bool = isNumber( NaN );\n* // returns true\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns false\n*/\nfunction isNumber( value ) {\n\treturn ( typeof value === 'number' );\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// EXPORTS //\n\nexport default Number; // eslint-disable-line stdlib/require-globals\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Number from '@stdlib/number-ctor';\n\n\n// MAIN //\n\n// eslint-disable-next-line stdlib/no-redeclare\nvar toString = Number.prototype.toString; // non-generic\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport nativeClass from '@stdlib/utils-native-class';\nimport Number from '@stdlib/number-ctor';\nimport test from './try2serialize.js';\n\n\n// VARIABLES //\n\nvar FLG = hasToStringTag();\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number object\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns false\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*/\nfunction isNumber( value ) {\n\tif ( typeof value === 'object' ) {\n\t\tif ( value instanceof Number ) {\n\t\t\treturn true;\n\t\t}\n\t\tif ( FLG ) {\n\t\t\treturn test( value );\n\t\t}\n\t\treturn ( nativeClass( value ) === '[object Number]' );\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport toString from './tostring.js'; // eslint-disable-line stdlib/no-redeclare\n\n\n// MAIN //\n\n/**\n* Attempts to serialize a value to a string.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value can be serialized\n*/\nfunction test( value ) {\n\ttry {\n\t\ttoString.call( value );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default test;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a number\n*\n* @example\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* @example\n* var bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*\n* @example\n* var bool = isNumber( NaN );\n* // returns true\n*\n* @example\n* var bool = isNumber( null );\n* // returns false\n*/\nfunction isNumber( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isNumber;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a number.\n*\n* @module @stdlib/assert-is-number\n*\n* @example\n* import isNumber from '@stdlib/assert-is-number';\n*\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*\n* bool = isNumber( NaN );\n* // returns true\n*\n* bool = isNumber( null );\n* // returns false\n*\n* @example\n* import { isPrimitive as isNumber } from '@stdlib/assert-is-number';\n*\n* var bool = isNumber( 3.14 );\n* // returns true\n*\n* bool = isNumber( NaN );\n* // returns true\n*\n* bool = isNumber( new Number( 3.14 ) );\n* // returns false\n*\n* @example\n* import { isObject as isNumber } from '@stdlib/assert-is-number';\n*\n* var bool = isNumber( 3.14 );\n* // returns false\n*\n* bool = isNumber( new Number( 3.14 ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Double-precision floating-point negative infinity.\n*\n* @module @stdlib/constants-float64-ninf\n* @type {number}\n*\n* @example\n* import FLOAT64_NINF from '@stdlib/constants-float64-ninf';\n* // returns -Infinity\n*/\n\n// MODULES //\n\nimport Number from '@stdlib/number-ctor';\n\n\n// MAIN //\n\n/**\n* Double-precision floating-point negative infinity.\n*\n* ## Notes\n*\n* Double-precision floating-point negative infinity has the bit sequence\n*\n* ```binarystring\n* 1 11111111111 00000000000000000000 00000000000000000000000000000000\n* ```\n*\n* @constant\n* @type {number}\n* @default Number.NEGATIVE_INFINITY\n* @see [IEEE 754]{@link https://en.wikipedia.org/wiki/IEEE_754-1985}\n*/\nvar FLOAT64_NINF = Number.NEGATIVE_INFINITY;\n\n\n// EXPORTS //\n\nexport default FLOAT64_NINF;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// TODO: implementation (?)\n\n/**\n* Rounds a double-precision floating-point number toward negative infinity.\n*\n* @param {number} x - input value\n* @returns {number} rounded value\n*\n* @example\n* var v = floor( -4.2 );\n* // returns -5.0\n*\n* @example\n* var v = floor( 9.99999 );\n* // returns 9.0\n*\n* @example\n* var v = floor( 0.0 );\n* // returns 0.0\n*\n* @example\n* var v = floor( NaN );\n* // returns NaN\n*/\nvar floor = Math.floor; // eslint-disable-line stdlib/no-builtin-math\n\n\n// EXPORTS //\n\nexport default floor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport floor from '@stdlib/math-base-special-floor';\n\n\n// MAIN //\n\n/**\n* Tests if a finite double-precision floating-point number is an integer.\n*\n* @param {number} x - value to test\n* @returns {boolean} boolean indicating whether the value is an integer\n*\n* @example\n* var bool = isInteger( 1.0 );\n* // returns true\n*\n* @example\n* var bool = isInteger( 3.14 );\n* // returns false\n*/\nfunction isInteger( x ) {\n\treturn (floor(x) === x);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport PINF from '@stdlib/constants-float64-pinf';\nimport NINF from '@stdlib/constants-float64-ninf';\nimport isInt from '@stdlib/math-base-assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a number primitive is an integer value.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a number primitive is an integer value\n*/\nfunction isInteger( value ) {\n\treturn (\n\t\tvalue < PINF &&\n\t\tvalue > NINF &&\n\t\tisInt( value )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport isInt from './integer.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number primitive having an integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive having an integer value\n*\n* @example\n* var bool = isInteger( -3.0 );\n* // returns true\n*\n* @example\n* var bool = isInteger( new Number( -3.0 ) );\n* // returns false\n*/\nfunction isInteger( value ) {\n\treturn (\n\t\tisNumber( value ) &&\n\t\tisInt( value )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isObject as isNumber } from '@stdlib/assert-is-number';\nimport isInt from './integer.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number object having an integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number object having an integer value\n*\n* @example\n* var bool = isInteger( 3.0 );\n* // returns false\n*\n* @example\n* var bool = isInteger( new Number( 3.0 ) );\n* // returns true\n*/\nfunction isInteger( value ) {\n\treturn (\n\t\tisNumber( value ) &&\n\t\tisInt( value.valueOf() )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is an integer.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an integer\n*\n* @example\n* var bool = isInteger( 5.0 );\n* // returns true\n*\n* @example\n* var bool = isInteger( new Number( 5.0 ) );\n* // returns true\n*\n* @example\n* var bool = isInteger( -3.14 );\n* // returns false\n*\n* @example\n* var bool = isInteger( null );\n* // returns false\n*/\nfunction isInteger( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isInteger } from '@stdlib/assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number primitive having a nonnegative integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number primitive having a nonnegative integer value\n*\n* @example\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns true\n*\n* @example\n* var bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns false\n*/\nfunction isNonNegativeInteger( value ) {\n\treturn (\n\t\tisInteger( value ) &&\n\t\tvalue >= 0\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isNonNegativeInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isObject as isInteger } from '@stdlib/assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a number object having a nonnegative integer value.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a number object having a nonnegative integer value\n*\n* @example\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns false\n*\n* @example\n* var bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns true\n*/\nfunction isNonNegativeInteger( value ) {\n\treturn (\n\t\tisInteger( value ) &&\n\t\tvalue.valueOf() >= 0\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isNonNegativeInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a nonnegative integer.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a nonnegative integer\n*\n* @example\n* var bool = isNonNegativeInteger( 5.0 );\n* // returns true\n*\n* @example\n* var bool = isNonNegativeInteger( new Number( 5.0 ) );\n* // returns true\n*\n* @example\n* var bool = isNonNegativeInteger( -5.0 );\n* // returns false\n*\n* @example\n* var bool = isNonNegativeInteger( 3.14 );\n* // returns false\n*\n* @example\n* var bool = isNonNegativeInteger( null );\n* // returns false\n*/\nfunction isNonNegativeInteger( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isNonNegativeInteger;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is an integer.\n*\n* @module @stdlib/assert-is-integer\n*\n* @example\n* import isInteger from '@stdlib/assert-is-integer';\n*\n* var bool = isInteger( 5.0 );\n* // returns true\n*\n* bool = isInteger( new Number( 5.0 ) );\n* // returns true\n*\n* bool = isInteger( -3.14 );\n* // returns false\n*\n* bool = isInteger( null );\n* // returns false\n*\n* @example\n* // Use interface to check for integer primitives...\n* import { isPrimitive as isInteger } from '@stdlib/assert-is-integer';\n*\n* var bool = isInteger( -3.0 );\n* // returns true\n*\n* bool = isInteger( new Number( -3.0 ) );\n* // returns false\n*\n* @example\n* // Use interface to check for integer objects...\n* import { isObject as isInteger } from '@stdlib/assert-is-integer';\n*\n* var bool = isInteger( 3.0 );\n* // returns false\n*\n* bool = isInteger( new Number( 3.0 ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a nonnegative integer.\n*\n* @module @stdlib/assert-is-nonnegative-integer\n*\n* @example\n* import isNonNegativeInteger from '@stdlib/assert-is-nonnegative-integer';\n*\n* var bool = isNonNegativeInteger( 5.0 );\n* // returns true\n*\n* bool = isNonNegativeInteger( new Number( 5.0 ) );\n* // returns true\n*\n* bool = isNonNegativeInteger( -5.0 );\n* // returns false\n*\n* bool = isNonNegativeInteger( 3.14 );\n* // returns false\n*\n* bool = isNonNegativeInteger( null );\n* // returns false\n*\n* @example\n* import { isPrimitive as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\n*\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns true\n*\n* bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns false\n*\n* @example\n* import { isObject as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\n*\n* var bool = isNonNegativeInteger( 3.0 );\n* // returns false\n*\n* bool = isNonNegativeInteger( new Number( 3.0 ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum length of a generic array.\n*\n* @module @stdlib/constants-array-max-array-length\n*\n* @example\n* import MAX_ARRAY_LENGTH from '@stdlib/constants-array-max-array-length';\n* // returns 4294967295\n*/\n\n// MAIN //\n\n/**\n* Maximum length of a generic array.\n*\n* ```tex\n* 2^{32} - 1\n* ```\n*\n* @constant\n* @type {uinteger32}\n* @default 4294967295\n*/\nvar MAX_ARRAY_LENGTH = 4294967295>>>0; // asm type annotation\n\n\n// EXPORTS //\n\nexport default MAX_ARRAY_LENGTH;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport MAX_LENGTH from '@stdlib/constants-array-max-array-length';\n\n\n// MAIN //\n\n/**\n* Tests if a value is an array-like object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is an array-like object\n*\n* @example\n* var bool = isArrayLikeObject( [] );\n* // returns true\n*\n* @example\n* var bool = isArrayLikeObject( { 'length':10 } );\n* // returns true\n*\n* @example\n* var bool = isArrayLikeObject( 'beep' );\n* // returns false\n*/\nfunction isArrayLikeObject( value ) {\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\ttypeof value.length === 'number' &&\n\t\tisInteger( value.length ) &&\n\t\tvalue.length >= 0 &&\n\t\tvalue.length <= MAX_LENGTH\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isArrayLikeObject;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Maximum length of a typed array.\n*\n* @module @stdlib/constants-array-max-typed-array-length\n*\n* @example\n* import MAX_TYPED_ARRAY_LENGTH from '@stdlib/constants-array-max-typed-array-length';\n* // returns 9007199254740991\n*/\n\n// MAIN //\n\n/**\n* Maximum length of a typed array.\n*\n* ```tex\n* 2^{53} - 1\n* ```\n*\n* @constant\n* @type {number}\n* @default 9007199254740991\n*/\nvar MAX_TYPED_ARRAY_LENGTH = 9007199254740991;\n\n\n// EXPORTS //\n\nexport default MAX_TYPED_ARRAY_LENGTH;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport MAX_LENGTH from '@stdlib/constants-array-max-typed-array-length';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a collection.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether a value is a collection\n*\n* @example\n* var bool = isCollection( [] );\n* // returns true\n*\n* @example\n* var bool = isCollection( {} );\n* // returns false\n*/\nfunction isCollection( value ) {\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\ttypeof value.length === 'number' &&\n\t\tisInteger( value.length ) &&\n\t\tvalue.length >= 0 &&\n\t\tvalue.length <= MAX_LENGTH\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isCollection;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport nativeClass from '@stdlib/utils-native-class';\n\n\n// VARIABLES //\n\nvar hasArrayBuffer = ( typeof ArrayBuffer === 'function' ); // eslint-disable-line stdlib/require-globals\n\n\n// MAIN //\n\n/**\n* Tests if a value is an ArrayBuffer.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an ArrayBuffer\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var bool = isArrayBuffer( new ArrayBuffer( 10 ) );\n* // returns true\n*\n* @example\n* var bool = isArrayBuffer( [] );\n* // returns false\n*/\nfunction isArrayBuffer( value ) {\n\treturn (\n\t\t( hasArrayBuffer && value instanceof ArrayBuffer ) || // eslint-disable-line stdlib/require-globals\n\t\tnativeClass( value ) === '[object ArrayBuffer]'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isArrayBuffer;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArray from '@stdlib/assert-is-array';\n\n\n// MAIN //\n\n/**\n* Tests if a value is an object; e.g., `{}`.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is an object\n*\n* @example\n* var bool = isObject( {} );\n* // returns true\n*\n* @example\n* var bool = isObject( null );\n* // returns false\n*/\nfunction isObject( value ) {\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\t!isArray( value )\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isObject;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a string primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string primitive\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns false\n*/\nfunction isString( value ) {\n\treturn ( typeof value === 'string' );\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// eslint-disable-next-line stdlib/no-redeclare\nvar valueOf = String.prototype.valueOf; // non-generic\n\n\n// EXPORTS //\n\nexport default valueOf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport nativeClass from '@stdlib/utils-native-class';\nimport test from './try2valueof.js';\n\n\n// VARIABLES //\n\nvar FLG = hasToStringTag();\n\n\n// MAIN //\n\n/**\n* Tests if a value is a string object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a string object\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns false\n*/\nfunction isString( value ) {\n\tif ( typeof value === 'object' ) {\n\t\tif ( value instanceof String ) {\n\t\t\treturn true;\n\t\t}\n\t\tif ( FLG ) {\n\t\t\treturn test( value );\n\t\t}\n\t\treturn ( nativeClass( value ) === '[object String]' );\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport valueOf from './valueof.js'; // eslint-disable-line stdlib/no-redeclare\n\n\n// MAIN //\n\n/**\n* Attempts to extract a string value.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a string can be extracted\n*/\nfunction test( value ) {\n\ttry {\n\t\tvalueOf.call( value );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default test;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a string.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a string\n*\n* @example\n* var bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* @example\n* var bool = isString( 'beep' );\n* // returns true\n*/\nfunction isString( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a string.\n*\n* @module @stdlib/assert-is-string\n*\n* @example\n* import isString from '@stdlib/assert-is-string';\n*\n* var bool = isString( 'beep' );\n* // returns true\n*\n* bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* bool = isString( 5 );\n* // returns false\n*\n* @example\n* import { isObject as isString } from '@stdlib/assert-is-string';\n*\n* var bool = isString( new String( 'beep' ) );\n* // returns true\n*\n* bool = isString( 'beep' );\n* // returns false\n*\n* @example\n* import { isPrimitive as isString } from '@stdlib/assert-is-string';\n*\n* var bool = isString( 'beep' );\n* // returns true\n*\n* bool = isString( new String( 'beep' ) );\n* // returns false\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\nvar RE = /./;\n\n\n// EXPORTS //\n\nexport default RE;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Tests if a value is a boolean primitive.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a boolean primitive\n*\n* @example\n* var bool = isBoolean( true );\n* // returns true\n*\n* @example\n* var bool = isBoolean( false );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( true ) );\n* // returns false\n*/\nfunction isBoolean( value ) {\n\treturn ( typeof value === 'boolean' );\n}\n\n\n// EXPORTS //\n\nexport default isBoolean;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Returns a boolean.\n*\n* @name Boolean\n* @constructor\n* @type {Function}\n* @param {*} value - input value\n* @returns {(boolean|Boolean)} boolean\n*\n* @example\n* var b = Boolean( null );\n* // returns false\n*\n* b = Boolean( [] );\n* // returns true\n*\n* b = Boolean( {} );\n* // returns true\n*\n* @example\n* var b = new Boolean( false );\n* // returns <Boolean>\n*/\nvar Bool = Boolean; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default Bool;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// eslint-disable-next-line stdlib/no-redeclare\nvar toString = Boolean.prototype.toString; // non-generic\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasToStringTag from '@stdlib/assert-has-tostringtag-support';\nimport nativeClass from '@stdlib/utils-native-class';\nimport Boolean from '@stdlib/boolean-ctor';\nimport test from './try2serialize.js';\n\n\n// VARIABLES //\n\nvar FLG = hasToStringTag();\n\n\n// MAIN //\n\n/**\n* Tests if a value is a boolean object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a boolean object\n*\n* @example\n* var bool = isBoolean( true );\n* // returns false\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( false ) );\n* // returns true\n*/\nfunction isBoolean( value ) {\n\tif ( typeof value === 'object' ) {\n\t\tif ( value instanceof Boolean ) {\n\t\t\treturn true;\n\t\t}\n\t\tif ( FLG ) {\n\t\t\treturn test( value );\n\t\t}\n\t\treturn ( nativeClass( value ) === '[object Boolean]' );\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default isBoolean;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport toString from './tostring.js'; // eslint-disable-line stdlib/no-redeclare\n\n\n// MAIN //\n\n/**\n* Attempts to serialize a value to a string.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value can be serialized\n*/\nfunction test( value ) {\n\ttry {\n\t\ttoString.call( value );\n\t\treturn true;\n\t} catch ( err ) { // eslint-disable-line no-unused-vars\n\t\treturn false;\n\t}\n}\n\n\n// EXPORTS //\n\nexport default test;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a boolean.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a boolean\n*\n* @example\n* var bool = isBoolean( false );\n* // returns true\n*\n* @example\n* var bool = isBoolean( true );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( false ) );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n*\n* var bool = isBoolean( new Boolean( true ) );\n* // returns true\n*/\nfunction isBoolean( value ) {\n\treturn ( isPrimitive( value ) || isObject( value ) );\n}\n\n\n// EXPORTS //\n\nexport default isBoolean;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Test if a value is a boolean.\n*\n* @module @stdlib/assert-is-boolean\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n* import isBoolean from '@stdlib/assert-is-boolean';\n*\n* var bool = isBoolean( false );\n* // returns true\n*\n* bool = isBoolean( new Boolean( false ) );\n* // returns true\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n* import { isPrimitive as isBoolean } from '@stdlib/assert-is-boolean';\n*\n* var bool = isBoolean( false );\n* // returns true\n*\n* bool = isBoolean( new Boolean( true ) );\n* // returns false\n*\n* @example\n* import Boolean from '@stdlib/boolean-ctor';\n* import { isObject as isBoolean } from '@stdlib/assert-is-boolean';\n*\n* var bool = isBoolean( true );\n* // returns false\n*\n* bool = isBoolean( new Boolean( false ) );\n* // returns true\n*/\n\n// MODULES //\n\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport main from './main.js';\nimport isPrimitive from './primitive.js';\nimport isObject from './object.js';\n\n\n// MAIN //\n\nsetReadOnly( main, 'isPrimitive', isPrimitive );\nsetReadOnly( main, 'isObject', isObject );\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar obj = ( typeof self === 'object' ) ? self : null;\n\n\n// EXPORTS //\n\nexport default obj;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar obj = ( typeof window === 'object' ) ? window : null;\n\n\n// EXPORTS //\n\nexport default obj;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar obj = ( typeof global === 'object' ) ? global : null;\n\n\n// EXPORTS //\n\nexport default obj;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar obj = ( typeof globalThis === 'object' ) ? globalThis : null; // eslint-disable-line no-undef\n\n\n// EXPORTS //\n\nexport default obj;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport getGlobal from '@stdlib/utils-global';\n\n\n// MAIN //\n\nvar root = getGlobal();\nvar nodeList = root.document && root.document.childNodes;\n\n\n// EXPORTS //\n\nexport default nodeList;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isBoolean } from '@stdlib/assert-is-boolean';\nimport format from '@stdlib/string-format';\nimport getThis from './codegen.js';\nimport Self from './self.js';\nimport Win from './window.js';\nimport Global from './global.js';\nimport GlobalThis from './global_this.js';\n\n\n// MAIN //\n\n/**\n* Returns the global object.\n*\n* ## Notes\n*\n* - Using code generation is the **most** reliable way to resolve the global object; however, doing so is likely to violate content security policies (CSPs) in, e.g., Chrome Apps and elsewhere.\n*\n* @param {boolean} [codegen=false] - boolean indicating whether to use code generation to resolve the global object\n* @throws {TypeError} must provide a boolean\n* @throws {Error} unable to resolve global object\n* @returns {Object} global object\n*\n* @example\n* var g = getGlobal();\n* // returns {...}\n*/\nfunction getGlobal( codegen ) {\n\tif ( arguments.length ) {\n\t\tif ( !isBoolean( codegen ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a boolean. Value: `%s`.', codegen ) );\n\t\t}\n\t\tif ( codegen ) {\n\t\t\treturn getThis();\n\t\t}\n\t\t// Fall through...\n\t}\n\t// Case: 2020 revision of ECMAScript standard\n\tif ( GlobalThis ) {\n\t\treturn GlobalThis;\n\t}\n\t// Case: browsers and web workers\n\tif ( Self ) {\n\t\treturn Self;\n\t}\n\t// Case: browsers\n\tif ( Win ) {\n\t\treturn Win;\n\t}\n\t// Case: Node.js\n\tif ( Global ) {\n\t\treturn Global;\n\t}\n\t// Case: unknown\n\tthrow new Error( 'unexpected error. Unable to resolve global object.' );\n}\n\n\n// EXPORTS //\n\nexport default getGlobal;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Returns the global object using code generation.\n*\n* @private\n* @returns {Object} global object\n*/\nfunction getGlobal() {\n\treturn new Function( 'return this;' )(); // eslint-disable-line no-new-func, stdlib/require-globals\n}\n\n\n// EXPORTS //\n\nexport default getGlobal;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\nvar typedarray = Int8Array; // eslint-disable-line stdlib/require-globals\n\n\n// EXPORTS //\n\nexport default typedarray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Determine a value's type.\n*\n* @module @stdlib/utils-type-of\n*\n* @example\n* import typeOf from '@stdlib/utils-type-of';\n*\n* var str = typeOf( 'a' );\n* // returns 'string'\n*\n* str = typeOf( 5 );\n* // returns 'number'\n*/\n\n// MODULES //\n\nimport usePolyfill from './check.js';\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar main = ( usePolyfill() ) ? polyfill : builtin;\n\n\n// EXPORTS //\n\nexport default main;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport RE from './fixtures/re.js';\nimport nodeList from './fixtures/nodelist.js';\nimport typedarray from './fixtures/typedarray.js';\n\n\n// MAIN //\n\n/**\n* Checks whether a polyfill is needed when using the `typeof` operator.\n*\n* @private\n* @returns {boolean} boolean indicating whether a polyfill is needed\n*/\nfunction check() {\n\tif (\n\t\t// Chrome 1-12 returns 'function' for regular expression instances (see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/typeof):\n\t\ttypeof RE === 'function' ||\n\n\t\t// Safari 8 returns 'object' for typed array and weak map constructors (underscore #1929):\n\t\ttypeof typedarray === 'object' ||\n\n\t\t// PhantomJS 1.9 returns 'function' for `NodeList` instances (underscore #2236):\n\t\ttypeof nodeList === 'function'\n\t) {\n\t\treturn true;\n\t}\n\treturn false;\n}\n\n\n// EXPORTS //\n\nexport default check;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport ctorName from '@stdlib/utils-constructor-name';\n\n\n// MAIN //\n\n/**\n* Determines a value's type.\n*\n* @param {*} v - input value\n* @returns {string} string indicating the value's type\n*/\nfunction typeOf( v ) {\n\treturn ctorName( v ).toLowerCase();\n}\n\n\n// EXPORTS //\n\nexport default typeOf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport ctorName from '@stdlib/utils-constructor-name';\n\n\n// NOTES //\n\n/*\n* Built-in `typeof` operator behavior:\n*\n* ```text\n* typeof null => 'object'\n* typeof undefined => 'undefined'\n* typeof 'a' => 'string'\n* typeof 5 => 'number'\n* typeof NaN => 'number'\n* typeof true => 'boolean'\n* typeof false => 'boolean'\n* typeof {} => 'object'\n* typeof [] => 'object'\n* typeof function foo(){} => 'function'\n* typeof function* foo(){} => 'object'\n* typeof Symbol() => 'symbol'\n* ```\n*\n*/\n\n\n// MAIN //\n\n/**\n* Determines a value's type.\n*\n* @param {*} v - input value\n* @returns {string} string indicating the value's type\n*/\nfunction typeOf( v ) {\n\tvar type;\n\n\t// Address `typeof null` => `object` (see http://wiki.ecmascript.org/doku.php?id=harmony:typeof_null):\n\tif ( v === null ) {\n\t\treturn 'null';\n\t}\n\ttype = typeof v;\n\n\t// If the `typeof` operator returned something other than `object`, we are done. Otherwise, we need to check for an internal class name or search for a constructor.\n\tif ( type === 'object' ) {\n\t\treturn ctorName( v ).toLowerCase();\n\t}\n\treturn type;\n}\n\n\n// EXPORTS //\n\nexport default typeOf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport typeOf from '@stdlib/utils-type-of';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a function.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating whether value is a function\n*\n* @example\n* function beep() {\n* return 'beep';\n* }\n*\n* var bool = isFunction( beep );\n* // returns true\n*/\nfunction isFunction( value ) {\n\t// Note: cannot use `typeof` directly, as various browser engines incorrectly return `'function'` when operating on non-function objects, such as regular expressions and NodeLists.\n\treturn ( typeOf( value ) === 'function' );\n}\n\n\n// EXPORTS //\n\nexport default isFunction;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 128-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex128} 128-bit complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n* // returns <Complex128>\n*/\nfunction Complex128( real, imag ) {\n\tif ( !( this instanceof Complex128 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': real\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': imag\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex128.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128.prototype, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 16\n*/\nsetReadOnly( Complex128.prototype, 'byteLength', 16 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex128.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex128` instance.\n*\n* @name toJSON\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex128', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex128.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex128;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex128';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\nvar fround = ( typeof Math.fround === 'function' ) ? Math.fround : null; // eslint-disable-line stdlib/no-builtin-math\n\n\n// EXPORTS //\n\nexport default fround;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float32Array from '@stdlib/array-float32';\n\n\n// VARIABLES //\n\nvar FLOAT32_VIEW = new Float32Array( 1 );\n\n\n// MAIN //\n\n/**\n* Converts a double-precision floating-point number to the nearest single-precision floating-point number.\n*\n* @param {number} x - double-precision floating-point number\n* @returns {number} nearest single-precision floating-point number\n*\n* @example\n* var y = float64ToFloat32( 1.337 );\n* // returns 1.3370000123977661\n*/\nfunction float64ToFloat32( x ) {\n\tFLOAT32_VIEW[ 0 ] = x;\n\treturn FLOAT32_VIEW[ 0 ];\n}\n\n\n// EXPORTS //\n\nexport default float64ToFloat32;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Convert a double-precision floating-point number to the nearest single-precision floating-point number.\n*\n* @module @stdlib/number-float64-base-to-float32\n*\n* @example\n* import float64ToFloat32 from '@stdlib/number-float64-base-to-float32';\n*\n* var y = float64ToFloat32( 1.337 );\n* // returns 1.3370000123977661\n*/\n\n// MODULES //\n\nimport builtin from './main.js';\nimport polyfill from './polyfill.js';\n\n\n// MAIN //\n\nvar float64ToFloat32;\nif ( typeof builtin === 'function' ) {\n\tfloat64ToFloat32 = builtin;\n} else {\n\tfloat64ToFloat32 = polyfill;\n}\n\n\n// EXPORTS //\n\nexport default float64ToFloat32;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport float64ToFloat32 from '@stdlib/number-float64-base-to-float32';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 64-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex64} 64-bit complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n* // returns <Complex64>\n*/\nfunction Complex64( real, imag ) {\n\tif ( !( this instanceof Complex64 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( real )\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( imag )\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex64.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64.prototype, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 8\n*/\nsetReadOnly( Complex64.prototype, 'byteLength', 8 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex64.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex64` instance.\n*\n* @name toJSON\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex64', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex64.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex64;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Complex128 from '@stdlib/complex-float64-ctor';\nimport Complex64 from '@stdlib/complex-float32-ctor';\n\n\n// MAIN //\n\n/**\n* Tests if a value is a complex number-like object.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex number-like object.\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64-ctor';\n* import Complex64 from '@stdlib/complex-float32-ctor';\n*\n* var x = new Complex128( 4.0, 2.0 );\n* var bool = isComplexLike( x );\n* // returns true\n*\n* x = new Complex64( 4.0, 2.0 );\n* bool = isComplexLike( x );\n* // returns true\n*/\nfunction isComplexLike( value ) {\n\tif ( value instanceof Complex128 || value instanceof Complex64 ) {\n\t\treturn true;\n\t}\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\ttypeof value.re === 'number' &&\n\t\ttypeof value.im === 'number'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isComplexLike;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isInteger from '@stdlib/math-base-assert-is-integer';\n\n\n// MAIN //\n\n/**\n* Tests if a finite numeric value is an even number.\n*\n* @param {number} x - value to test\n* @returns {boolean} boolean indicating whether the value is an even number\n*\n* @example\n* var bool = isEven( 5.0 );\n* // returns false\n*\n* @example\n* var bool = isEven( -2.0 );\n* // returns true\n*\n* @example\n* var bool = isEven( 0.0 );\n* // returns true\n*\n* @example\n* var bool = isEven( NaN );\n* // returns false\n*/\nfunction isEven( x ) {\n\treturn isInteger( x/2.0 );\n}\n\n\n// EXPORTS //\n\nexport default isEven;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex64';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2024 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = 8; // 4 bytes per float32 x (1 real + 1 imag component)\n\n\n// MAIN //\n\n/**\n* Returns a boolean indicating if a value is a `Complex64Array`.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a `Complex64Array`\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n*\n* var bool = isComplex64Array( new Complex64Array( 10 ) );\n* // returns true\n*\n* bool = isComplex64Array( [] );\n* // returns false\n*/\nfunction isComplex64Array( value ) {\n\t// Note: the following is not robust and that is intentional. In this case, we are seeking a lower cost way to reasonably determine whether an input value is a `Complex64Array` in order to avoid walking the prototype chain and resolving constructors, which is necessary for robust identification of cross-realm instances. For more robust validation, see `@stdlib/assert/is-complex64array`.\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\tvalue.constructor.name === 'Complex64Array' &&\n\t\tvalue.BYTES_PER_ELEMENT === BYTES_PER_ELEMENT\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isComplex64Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2024 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = 16; // 8 bytes per float64 x (1 real + 1 imag component)\n\n\n// MAIN //\n\n/**\n* Returns a boolean indicating if a value is a `Complex128Array`.\n*\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a `Complex128Array`\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n*\n* var bool = isComplex128Array( new Complex128Array( 10 ) );\n* // returns true\n*\n* bool = isComplex128Array( [] );\n* // returns false\n*/\nfunction isComplex128Array( value ) {\n\t// Note: the following is not robust and that is intentional. In this case, we are seeking a lower cost way to reasonably determine whether an input value is a `Complex128Array` in order to avoid walking the prototype chain and resolving constructors, which is necessary for robust identification of cross-realm instances. For more robust validation, see `@stdlib/assert/is-complex128array`.\n\treturn (\n\t\ttypeof value === 'object' &&\n\t\tvalue !== null &&\n\t\tvalue.constructor.name === 'Complex128Array' &&\n\t\tvalue.BYTES_PER_ELEMENT === BYTES_PER_ELEMENT\n\t);\n}\n\n\n// EXPORTS //\n\nexport default isComplex128Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasOwnProp from '@stdlib/assert-has-own-property';\nimport Symbol from '@stdlib/symbol-ctor';\n\n\n// MAIN //\n\n/**\n* Tests for native `Symbol.iterator` support.\n*\n* @returns {boolean} boolean indicating if an environment has `Symbol.iterator` support\n*\n* @example\n* var bool = hasIteratorSymbolSupport();\n* // returns <boolean>\n*/\nfunction hasIteratorSymbolSupport() {\n\treturn (\n\t\ttypeof Symbol === 'function' &&\n\t\ttypeof Symbol( 'foo' ) === 'symbol' &&\n\t\thasOwnProp( Symbol, 'iterator' ) &&\n\t\ttypeof Symbol.iterator === 'symbol'\n\t);\n}\n\n\n// EXPORTS //\n\nexport default hasIteratorSymbolSupport;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport hasIteratorSymbolSupport from '@stdlib/assert-has-iterator-symbol-support';\n\n\n// MAIN //\n\n/**\n* Iterator symbol.\n*\n* @name IteratorSymbol\n* @constant\n* @type {(symbol|null)}\n*\n* @example\n* function iterator() {\n* var it;\n* var i;\n*\n* i = -1;\n*\n* it = {};\n* it.next = next;\n* it.return = done;\n*\n* if ( IteratorSymbol ) {\n* it[ IteratorSymbol ] = iterator;\n* }\n* return it;\n*\n* function next() {\n* i += 1;\n* return {\n* 'value': i,\n* 'done': false\n* };\n* }\n*\n* function done( value ) {\n* if ( arguments.length === 0 ) {\n* return {\n* 'done': true\n* };\n* }\n* return {\n* 'value': value,\n* 'done': true\n* };\n* }\n* }\n*\n* var obj = iterator();\n*/\nvar IteratorSymbol = ( hasIteratorSymbolSupport() ) ? Symbol.iterator : null;\n\n\n// EXPORTS //\n\nexport default IteratorSymbol;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport defineProperty from '@stdlib/utils-define-property';\n\n\n// MAIN //\n\n/**\n* Defines a non-enumerable read-only accessor.\n*\n* @param {Object} obj - object on which to define the property\n* @param {(string|symbol)} prop - property name\n* @param {Function} getter - accessor\n*\n* @example\n* function getter() {\n* return 'bar';\n* }\n*\n* var obj = {};\n*\n* setNonEnumerableReadOnlyAccessor( obj, 'foo', getter );\n*\n* try {\n* obj.foo = 'boop';\n* } catch ( err ) {\n* console.error( err.message );\n* }\n*/\nfunction setNonEnumerableReadOnlyAccessor( obj, prop, getter ) { // eslint-disable-line id-length\n\tdefineProperty( obj, prop, {\n\t\t'configurable': false,\n\t\t'enumerable': false,\n\t\t'get': getter\n\t});\n}\n\n\n// EXPORTS //\n\nexport default setNonEnumerableReadOnlyAccessor;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport float64ToFloat32 from '@stdlib/number-float64-base-to-float32';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 64-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex64} 64-bit complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n* // returns <Complex64>\n*/\nfunction Complex64( real, imag ) {\n\tif ( !( this instanceof Complex64 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( real )\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': float64ToFloat32( imag )\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex64.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 4\n*/\nsetReadOnly( Complex64.prototype, 'BYTES_PER_ELEMENT', 4 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex64.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 8\n*/\nsetReadOnly( Complex64.prototype, 'byteLength', 8 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex64.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex64` instance.\n*\n* @name toJSON\n* @memberof Complex64.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex64', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex64.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex64;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the real component of a single-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} real component\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var re = realf( z );\n* // returns 5.0\n*/\nfunction realf( z ) {\n\treturn z.re;\n}\n\n\n// EXPORTS //\n\nexport default realf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the imaginary component of a single-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} imaginary component\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var z = new Complex64( 5.0, 3.0 );\n*\n* var im = imagf( z );\n* // returns 3.0\n*/\nfunction imagf( z ) {\n\treturn z.im;\n}\n\n\n// EXPORTS //\n\nexport default imagf;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float32Array from '@stdlib/array-float32';\n\n\n// MAIN //\n\n/**\n* Reinterprets a `Complex64Array` as a `Float32Array`.\n*\n* @param {Complex64Array} x - input array\n* @param {NonNegativeInteger} offset - starting index\n* @returns {Float32Array} `Float32Array` view\n*\n* @example\n* import Complex64Array from '@stdlib/array-complex64';\n*\n* var x = new Complex64Array( 10 );\n*\n* var out = reinterpret( x, 0 );\n* // returns <Float32Array>\n*\n* var bool = ( out.buffer === x.buffer );\n* // returns true\n*/\nfunction reinterpret( x, offset ) {\n\treturn new Float32Array( x.buffer, x.byteOffset+(x.BYTES_PER_ELEMENT*offset), 2*(x.length-offset) ); // eslint-disable-line max-len\n}\n\n\n// EXPORTS //\n\nexport default reinterpret;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2021 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float64Array from '@stdlib/array-float64';\n\n\n// MAIN //\n\n/**\n* Reinterprets a `Complex128Array` as a `Float64Array`.\n*\n* @param {Complex128Array} x - input array\n* @param {NonNegativeInteger} offset - starting index\n* @returns {Float64Array} `Float64Array` view\n*\n* @example\n* import Complex128Array from '@stdlib/array-complex128';\n*\n* var x = new Complex128Array( 10 );\n*\n* var out = reinterpret( x, 0 );\n* // returns <Float64Array>\n*\n* var bool = ( out.buffer === x.buffer );\n* // returns true\n*/\nfunction reinterpret( x, offset ) {\n\treturn new Float64Array( x.buffer, x.byteOffset+(x.BYTES_PER_ELEMENT*offset), 2*(x.length-offset) ); // eslint-disable-line max-len\n}\n\n\n// EXPORTS //\n\nexport default reinterpret;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\nimport format from '@stdlib/string-format';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIterator( it ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\n\tout = [];\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\tz = v.value;\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( realf( z ), imagf( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIterator;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex64';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/* eslint-disable no-restricted-syntax, max-lines, no-invalid-this */\n\n/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isCollection from '@stdlib/assert-is-collection';\nimport isArrayBuffer from '@stdlib/assert-is-arraybuffer';\nimport isObject from '@stdlib/assert-is-object';\nimport isArray from '@stdlib/assert-is-array';\nimport { isPrimitive as isString } from '@stdlib/assert-is-string';\nimport isFunction from '@stdlib/assert-is-function';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport isEven from '@stdlib/math-base-assert-is-even';\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport isComplex64Array from '@stdlib/array-base-assert-is-complex64array';\nimport isComplex128Array from '@stdlib/array-base-assert-is-complex128array';\nimport hasIteratorSymbolSupport from '@stdlib/assert-has-iterator-symbol-support';\nimport ITERATOR_SYMBOL from '@stdlib/symbol-iterator';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport setReadOnlyAccessor from '@stdlib/utils-define-nonenumerable-read-only-accessor';\nimport Float32Array from '@stdlib/array-float32';\nimport Complex64 from '@stdlib/complex-float32';\nimport format from '@stdlib/string-format';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\nimport floor from '@stdlib/math-base-special-floor';\nimport reinterpret64 from '@stdlib/strided-base-reinterpret-complex64';\nimport reinterpret128 from '@stdlib/strided-base-reinterpret-complex128';\nimport getter from '@stdlib/array-base-getter';\nimport accessorGetter from '@stdlib/array-base-accessor-getter';\nimport fromIterator from './from_iterator.js';\nimport fromIteratorMap from './from_iterator_map.js';\nimport fromArray from './from_array.js';\n\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = Float32Array.BYTES_PER_ELEMENT * 2;\nvar HAS_ITERATOR_SYMBOL = hasIteratorSymbolSupport();\n\n\n// FUNCTIONS //\n\n/**\n* Returns a boolean indicating if a value is a complex typed array.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array\n*/\nfunction isComplexArray( value ) {\n\treturn (\n\t\tvalue instanceof Complex64Array ||\n\t\t(\n\t\t\ttypeof value === 'object' &&\n\t\t\tvalue !== null &&\n\t\t\t(\n\t\t\t\tvalue.constructor.name === 'Complex64Array' ||\n\t\t\t\tvalue.constructor.name === 'Complex128Array'\n\t\t\t) &&\n\t\t\ttypeof value._length === 'number' && // eslint-disable-line no-underscore-dangle\n\n\t\t\t// NOTE: we don't perform a more rigorous test here for a typed array for performance reasons, as robustly checking for a typed array instance could require walking the prototype tree and performing relatively expensive constructor checks...\n\t\t\ttypeof value._buffer === 'object' // eslint-disable-line no-underscore-dangle\n\t\t)\n\t);\n}\n\n/**\n* Returns a boolean indicating if a value is a complex typed array constructor.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array constructor\n*/\nfunction isComplexArrayConstructor( value ) {\n\treturn (\n\t\tvalue === Complex64Array ||\n\n\t\t// NOTE: weaker test in order to avoid a circular dependency with Complex128Array...\n\t\tvalue.name === 'Complex128Array'\n\t);\n}\n\n/**\n* Retrieves a complex number from a complex number array buffer.\n*\n* @private\n* @param {Float32Array} buf - array buffer\n* @param {NonNegativeInteger} idx - element index\n* @returns {Complex64} complex number\n*/\nfunction getComplex64( buf, idx ) {\n\tidx *= 2;\n\treturn new Complex64( buf[ idx ], buf[ idx+1 ] );\n}\n\n\n// MAIN //\n\n/**\n* 64-bit complex number array constructor.\n*\n* @constructor\n* @param {(NonNegativeInteger|Collection|ArrayBuffer|Iterable)} [arg] - length, typed array, array-like object, buffer, or an iterable\n* @param {NonNegativeInteger} [byteOffset=0] - byte offset\n* @param {NonNegativeInteger} [length] - view length\n* @throws {RangeError} ArrayBuffer byte length must be a multiple of `8`\n* @throws {RangeError} array-like object and typed array input arguments must have a length which is a multiple of two\n* @throws {TypeError} if provided only a single argument, must provide a valid argument\n* @throws {TypeError} byte offset must be a nonnegative integer\n* @throws {RangeError} byte offset must be a multiple of `8`\n* @throws {TypeError} view length must be a positive multiple of `8`\n* @throws {RangeError} must provide sufficient memory to accommodate byte offset and view length requirements\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex64Array} complex number array\n*\n* @example\n* var arr = new Complex64Array();\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 0\n*\n* @example\n* var arr = new Complex64Array( 2 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* var arr = new Complex64Array( [ 1.0, -1.0 ] );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 16 );\n* var arr = new Complex64Array( buf );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 16 );\n* var arr = new Complex64Array( buf, 8 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 32 );\n* var arr = new Complex64Array( buf, 8, 2 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nfunction Complex64Array() {\n\tvar byteOffset;\n\tvar nargs;\n\tvar buf;\n\tvar len;\n\n\tnargs = arguments.length;\n\tif ( !(this instanceof Complex64Array) ) {\n\t\tif ( nargs === 0 ) {\n\t\t\treturn new Complex64Array();\n\t\t}\n\t\tif ( nargs === 1 ) {\n\t\t\treturn new Complex64Array( arguments[0] );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\treturn new Complex64Array( arguments[0], arguments[1] );\n\t\t}\n\t\treturn new Complex64Array( arguments[0], arguments[1], arguments[2] );\n\t}\n\t// Create the underlying data buffer...\n\tif ( nargs === 0 ) {\n\t\tbuf = new Float32Array( 0 ); // backward-compatibility\n\t} else if ( nargs === 1 ) {\n\t\tif ( isNonNegativeInteger( arguments[0] ) ) {\n\t\t\tbuf = new Float32Array( arguments[0]*2 );\n\t\t} else if ( isCollection( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tlen = buf.length;\n\n\t\t\t// If provided a \"generic\" array, peak at the first value, and, if the value is a complex number, try to process as an array of complex numbers, falling back to \"normal\" typed array initialization if we fail and ensuring consistency if the first value had not been a complex number...\n\t\t\tif ( len && isArray( buf ) && isComplexLike( buf[0] ) ) {\n\t\t\t\tbuf = fromArray( new Float32Array( len*2 ), buf );\n\t\t\t\tif ( buf === null ) {\n\t\t\t\t\t// We failed and we are now forced to allocate a new array :-(\n\t\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t\t}\n\t\t\t\t\t// We failed, so fall back to directly setting values...\n\t\t\t\t\tbuf = new Float32Array( arguments[0] );\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif ( isComplex64Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret64( buf, 0 );\n\t\t\t\t} else if ( isComplex128Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret128( buf, 0 );\n\t\t\t\t} else if ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t}\n\t\t\t\tbuf = new Float32Array( buf );\n\t\t\t}\n\t\t} else if ( isArrayBuffer( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( !isInteger( buf.byteLength/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.', BYTES_PER_ELEMENT, buf.byteLength ) );\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf );\n\t\t} else if ( isObject( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( HAS_ITERATOR_SYMBOL === false ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tif ( !isFunction( buf[ ITERATOR_SYMBOL ] ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tbuf = buf[ ITERATOR_SYMBOL ]();\n\t\t\tif ( !isFunction( buf.next ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) ); // FIXME: `buf` is what is returned from above, NOT the original value\n\t\t\t}\n\t\t\tbuf = fromIterator( buf );\n\t\t\tif ( buf instanceof Error ) {\n\t\t\t\tthrow buf;\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf );\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', arguments[0] ) );\n\t\t}\n\t} else {\n\t\tbuf = arguments[ 0 ];\n\t\tif ( !isArrayBuffer( buf ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an ArrayBuffer. Value: `%s`.', buf ) );\n\t\t}\n\t\tbyteOffset = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( byteOffset ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.', byteOffset ) );\n\t\t}\n\t\tif ( !isInteger( byteOffset/BYTES_PER_ELEMENT ) ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Byte offset must be a multiple of %u. Value: `%u`.', BYTES_PER_ELEMENT, byteOffset ) );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\tlen = buf.byteLength - byteOffset;\n\t\t\tif ( !isInteger( len/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.', BYTES_PER_ELEMENT, len ) );\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf, byteOffset );\n\t\t} else {\n\t\t\tlen = arguments[ 2 ];\n\t\t\tif ( !isNonNegativeInteger( len ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Length must be a nonnegative integer. Value: `%s`.', len ) );\n\t\t\t}\n\t\t\tif ( (len*BYTES_PER_ELEMENT) > (buf.byteLength-byteOffset) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.', len*BYTES_PER_ELEMENT ) );\n\t\t\t}\n\t\t\tbuf = new Float32Array( buf, byteOffset, len*2 );\n\t\t}\n\t}\n\tsetReadOnly( this, '_buffer', buf );\n\tsetReadOnly( this, '_length', buf.length/2 );\n\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64Array\n* @readonly\n* @type {PositiveInteger}\n* @default 8\n*\n* @example\n* var nbytes = Complex64Array.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex64Array, 'BYTES_PER_ELEMENT', BYTES_PER_ELEMENT );\n\n/**\n* Constructor name.\n*\n* @name name\n* @memberof Complex64Array\n* @readonly\n* @type {string}\n* @default 'Complex64Array'\n*\n* @example\n* var str = Complex64Array.name;\n* // returns 'Complex64Array'\n*/\nsetReadOnly( Complex64Array, 'name', 'Complex64Array' );\n\n/**\n* Creates a new 64-bit complex number array from an array-like object or an iterable.\n*\n* @name from\n* @memberof Complex64Array\n* @type {Function}\n* @param {(Collection|Iterable)} src - array-like object or iterable\n* @param {Function} [clbk] - callback to invoke for each source element\n* @param {*} [thisArg] - context\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an array-like object or an iterable\n* @throws {TypeError} second argument must be a function\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @throws {TypeError} when provided an iterator, a callback must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex64Array} 64-bit complex number array\n*\n* @example\n* var arr = Complex64Array.from( [ 1.0, -1.0 ] );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = Complex64Array.from( [ new Complex64( 1.0, 1.0 ) ] );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function clbk( v ) {\n* return new Complex64( realf(v)*2.0, imagf(v)*2.0 );\n* }\n*\n* var arr = Complex64Array.from( [ new Complex64( 1.0, 1.0 ) ], clbk );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 1\n*/\nsetReadOnly( Complex64Array, 'from', function from( src ) {\n\tvar thisArg;\n\tvar nargs;\n\tvar clbk;\n\tvar out;\n\tvar buf;\n\tvar tmp;\n\tvar get;\n\tvar len;\n\tvar flg;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tnargs = arguments.length;\n\tif ( nargs > 1 ) {\n\t\tclbk = arguments[ 1 ];\n\t\tif ( !isFunction( clbk ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a function. Value: `%s`.', clbk ) );\n\t\t}\n\t\tif ( nargs > 2 ) {\n\t\t\tthisArg = arguments[ 2 ];\n\t\t}\n\t}\n\tif ( isComplexArray( src ) ) {\n\t\tlen = src.length;\n\t\tif ( clbk ) {\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, src.get( i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = realf( v );\n\t\t\t\t\tbuf[ j+1 ] = imagf( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isCollection( src ) ) {\n\t\tif ( clbk ) {\n\t\t\t// Note: array contents affect how we iterate over a provided data source. If only complex number objects, we can extract real and imaginary components. Otherwise, for non-complex number arrays (e.g., `Float64Array`, etc), we assume a strided array where real and imaginary components are interleaved. In the former case, we expect a callback to return real and imaginary components (possibly as a complex number). In the latter case, we expect a callback to return *either* a real or imaginary component.\n\n\t\t\tlen = src.length;\n\t\t\tif ( src.get && src.set ) {\n\t\t\t\tget = accessorGetter( 'default' );\n\t\t\t} else {\n\t\t\t\tget = getter( 'default' );\n\t\t\t}\n\t\t\t// Detect whether we've been provided an array which returns complex number objects...\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tif ( !isComplexLike( get( src, i ) ) ) {\n\t\t\t\t\tflg = true;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// If an array does not contain only complex number objects, then we assume interleaved real and imaginary components...\n\t\t\tif ( flg ) {\n\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. First argument must have a length which is a multiple of %u. Length: `%u`.', 2, len ) );\n\t\t\t\t}\n\t\t\t\tout = new this( len/2 );\n\t\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\t\tbuf[ i ] = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\t}\n\t\t\t\treturn out;\n\t\t\t}\n\t\t\t// If an array contains only complex number objects, then we need to extract real and imaginary components...\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = realf( v );\n\t\t\t\t\tbuf[ j+1 ] = imagf( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isObject( src ) && HAS_ITERATOR_SYMBOL && isFunction( src[ ITERATOR_SYMBOL ] ) ) { // eslint-disable-line max-len\n\t\tbuf = src[ ITERATOR_SYMBOL ]();\n\t\tif ( !isFunction( buf.next ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n\t\t}\n\t\tif ( clbk ) {\n\t\t\ttmp = fromIteratorMap( buf, clbk, thisArg );\n\t\t} else {\n\t\t\ttmp = fromIterator( buf );\n\t\t}\n\t\tif ( tmp instanceof Error ) {\n\t\t\tthrow tmp;\n\t\t}\n\t\tlen = tmp.length / 2;\n\t\tout = new this( len );\n\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\tbuf[ i ] = tmp[ i ];\n\t\t}\n\t\treturn out;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n});\n\n/**\n* Creates a new 64-bit complex number array from a variable number of arguments.\n*\n* @name of\n* @memberof Complex64Array\n* @type {Function}\n* @param {...*} element - array elements\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} 64-bit complex number array\n*\n* @example\n* var arr = Complex64Array.of( 1.0, 1.0, 1.0, 1.0 );\n* // returns <Complex64Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nsetReadOnly( Complex64Array, 'of', function of() {\n\tvar args;\n\tvar i;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\targs = [];\n\tfor ( i = 0; i < arguments.length; i++ ) {\n\t\targs.push( arguments[ i ] );\n\t}\n\treturn new this( args );\n});\n\n/**\n* Returns an array element with support for both nonnegative and negative integer indices.\n*\n* @name at\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide an integer\n* @returns {(Complex64|void)} array element\n*\n* @example\n* var arr = new Complex64Array( 10 );\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var z = arr.at( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 0.0\n*\n* var im = imagf( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 9.0, -9.0 ], 9 );\n*\n* z = arr.at( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns -1.0\n*\n* z = arr.at( -1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 9.0\n*\n* im = imagf( z );\n* // returns -9.0\n*\n* z = arr.at( 100 );\n* // returns undefined\n*\n* z = arr.at( -100 );\n* // returns undefined\n*/\nsetReadOnly( Complex64Array.prototype, 'at', function at( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide an integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx < 0 ) {\n\t\tidx += this._length;\n\t}\n\tif ( idx < 0 || idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex64( this._buffer, idx );\n});\n\n/**\n* Pointer to the underlying data buffer.\n*\n* @name buffer\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {ArrayBuffer}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var buf = arr.buffer;\n* // returns <ArrayBuffer>\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'buffer', function get() {\n\treturn this._buffer.buffer;\n});\n\n/**\n* Size (in bytes) of the array.\n*\n* @name byteLength\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var byteLength = arr.byteLength;\n* // returns 80\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'byteLength', function get() {\n\treturn this._buffer.byteLength;\n});\n\n/**\n* Offset (in bytes) of the array from the start of its underlying `ArrayBuffer`.\n*\n* @name byteOffset\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var byteOffset = arr.byteOffset;\n* // returns 0\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'byteOffset', function get() {\n\treturn this._buffer.byteOffset;\n});\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {PositiveInteger}\n* @default 8\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var nbytes = arr.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex64Array.prototype, 'BYTES_PER_ELEMENT', Complex64Array.BYTES_PER_ELEMENT );\n\n/**\n* Copies a sequence of elements within the array to the position starting at `target`.\n*\n* @name copyWithin\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} target - index at which to start copying elements\n* @param {integer} start - source index at which to copy elements from\n* @param {integer} [end] - source index at which to stop copying elements from\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} modified array\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 4 );\n*\n* // Set the array elements:\n* arr.set( new Complex64( 1.0, 1.0 ), 0 );\n* arr.set( new Complex64( 2.0, 2.0 ), 1 );\n* arr.set( new Complex64( 3.0, 3.0 ), 2 );\n* arr.set( new Complex64( 4.0, 4.0 ), 3 );\n*\n* // Copy the first two elements to the last two elements:\n* arr.copyWithin( 2, 0, 2 );\n*\n* // Get the last array element:\n* var z = arr.get( 3 );\n*\n* var re = realf( z );\n* // returns 2.0\n*\n* var im = imagf( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex64Array.prototype, 'copyWithin', function copyWithin( target, start ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\t// FIXME: prefer a functional `copyWithin` implementation which addresses lack of universal browser support (e.g., IE11 and Safari) or ensure that typed arrays are polyfilled\n\tif ( arguments.length === 2 ) {\n\t\tthis._buffer.copyWithin( target*2, start*2 );\n\t} else {\n\t\tthis._buffer.copyWithin( target*2, start*2, arguments[2]*2 );\n\t}\n\treturn this;\n});\n\n/**\n* Returns an iterator for iterating over array key-value pairs.\n*\n* @name entries\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Iterator} iterator\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = [\n* new Complex64( 1.0, 1.0 ),\n* new Complex64( 2.0, 2.0 ),\n* new Complex64( 3.0, 3.0 )\n* ];\n* arr = new Complex64Array( arr );\n*\n* // Create an iterator:\n* var it = arr.entries();\n*\n* // Iterate over the key-value pairs...\n* var v = it.next().value;\n* // returns [ 0, <Complex64> ]\n*\n* v = it.next().value;\n* // returns [ 1, <Complex64> ]\n*\n* v = it.next().value;\n* // returns [ 2, <Complex64> ]\n*\n* var bool = it.next().done;\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'entries', function entries() {\n\tvar buffer;\n\tvar self;\n\tvar iter;\n\tvar len;\n\tvar FLG;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tself = this;\n\tbuffer = this._buffer;\n\tlen = this._length;\n\n\t// Initialize the iteration indices:\n\ti = -1;\n\tj = -2;\n\n\t// Create an iterator protocol-compliant object:\n\titer = {};\n\tsetReadOnly( iter, 'next', next );\n\tsetReadOnly( iter, 'return', end );\n\n\tif ( ITERATOR_SYMBOL ) {\n\t\tsetReadOnly( iter, ITERATOR_SYMBOL, factory );\n\t}\n\treturn iter;\n\n\t/**\n\t* Returns an iterator protocol-compliant object containing the next iterated value.\n\t*\n\t* @private\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction next() {\n\t\tvar z;\n\t\ti += 1;\n\t\tif ( FLG || i >= len ) {\n\t\t\treturn {\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\tj += 2;\n\t\tz = new Complex64( buffer[ j ], buffer[ j+1 ] );\n\t\treturn {\n\t\t\t'value': [ i, z ],\n\t\t\t'done': false\n\t\t};\n\t}\n\n\t/**\n\t* Finishes an iterator.\n\t*\n\t* @private\n\t* @param {*} [value] - value to return\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction end( value ) {\n\t\tFLG = true;\n\t\tif ( arguments.length ) {\n\t\t\treturn {\n\t\t\t\t'value': value,\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\t'done': true\n\t\t};\n\t}\n\n\t/**\n\t* Returns a new iterator.\n\t*\n\t* @private\n\t* @returns {Iterator} iterator\n\t*/\n\tfunction factory() {\n\t\treturn self.entries();\n\t}\n});\n\n/**\n* Tests whether all elements in an array pass a test implemented by a predicate function.\n*\n* @name every\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether all elements pass a test\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var bool = arr.every( predicate );\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'every', function every( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( !predicate.call( thisArg, getComplex64( buf, i ), i, this ) ) {\n\t\t\treturn false;\n\t\t}\n\t}\n\treturn true;\n});\n\n/**\n* Returns a modified typed array filled with a fill value.\n*\n* @name fill\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} value - fill value\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @throws {TypeError} third argument must be an integer\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.fill( new Complex64( 1.0, 1.0 ), 1 );\n*\n* var z = arr.get( 1 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns 1.0\n*\n* z = arr.get( 1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'fill', function fill( value, start, end ) {\n\tvar buf;\n\tvar len;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length > 2 ) {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Third argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t} else {\n\t\t\tend = len;\n\t\t}\n\t} else {\n\t\tstart = 0;\n\t\tend = len;\n\t}\n\tre = realf( value );\n\tim = imagf( value );\n\tfor ( i = start; i < end; i++ ) {\n\t\tidx = 2*i;\n\t\tbuf[ idx ] = re;\n\t\tbuf[ idx+1 ] = im;\n\t}\n\treturn this;\n});\n\n/**\n* Returns a new array containing the elements of an array which pass a test implemented by a predicate function.\n*\n* @name filter\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex64Array} complex number array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.filter( predicate );\n* // returns <Complex64Array>\n*\n* var len = out.length;\n* // returns 1\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 2.0\n*\n* var im = imagf( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex64Array.prototype, 'filter', function filter( predicate, thisArg ) {\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tout = [];\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\tout.push( z );\n\t\t}\n\t}\n\treturn new this.constructor( out );\n});\n\n/**\n* Returns the first element in an array for which a predicate function returns a truthy value.\n*\n* @name find\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex64|void)} array element or undefined\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import Complex64 from '@stdlib/complex-float32';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.find( predicate );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'find', function find( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the first element in an array for which a predicate function returns a truthy value.\n*\n* @name findIndex\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var idx = arr.findIndex( predicate );\n* // returns 2\n*/\nsetReadOnly( Complex64Array.prototype, 'findIndex', function findIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLast\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex64|void)} array element or undefined\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import Complex64 from '@stdlib/complex-float32';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.findLast( predicate );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 3.0\n*\n* var im = imagf( z );\n* // returns 3.0\n*/\nsetReadOnly( Complex64Array.prototype, 'findLast', function findLast( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLastIndex\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var idx = arr.findLastIndex( predicate );\n* // returns 1\n*/\nsetReadOnly( Complex64Array.prototype, 'findLastIndex', function findLastIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex64( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Invokes a function once for each array element.\n*\n* @name forEach\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} fcn - function to invoke\n* @param {*} [thisArg] - function invocation context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* function log( v, i ) {\n* console.log( '%s: %s', i, v.toString() );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* arr.forEach( log );\n*/\nsetReadOnly( Complex64Array.prototype, 'forEach', function forEach( fcn, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex64( buf, i );\n\t\tfcn.call( thisArg, z, i, this );\n\t}\n});\n\n/**\n* Returns an array element.\n*\n* @name get\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {NonNegativeInteger} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide a nonnegative integer\n* @returns {(Complex64|void)} array element\n*\n* @example\n* var arr = new Complex64Array( 10 );\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var z = arr.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 0.0\n*\n* var im = imagf( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns -1.0\n*\n* z = arr.get( 100 );\n* // returns undefined\n*/\nsetReadOnly( Complex64Array.prototype, 'get', function get( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isNonNegativeInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide a nonnegative integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex64( this._buffer, idx );\n});\n\n/**\n* Returns a boolean indicating whether an array includes a provided value.\n*\n* @name includes\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - search element\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {boolean} boolean indicating whether an array includes a provided value\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var bool = arr.includes( new Complex64( 3.0, -3.0 ) );\n* // returns true\n*\n* bool = arr.includes( new Complex64( 3.0, -3.0 ), 3 );\n* // returns false\n*\n* bool = arr.includes( new Complex64( 4.0, -4.0 ), -3 );\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'includes', function includes( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = realf( searchElement );\n\tim = imagf( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Returns the first index at which a given element can be found.\n*\n* @name indexOf\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 10 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var idx = arr.indexOf( new Complex64( 3.0, -3.0 ) );\n* // returns 2\n*\n* idx = arr.indexOf( new Complex64( 3.0, -3.0 ), 3 );\n* // returns -1\n*\n* idx = arr.indexOf( new Complex64( 4.0, -4.0 ), -3 );\n* // returns -1\n*/\nsetReadOnly( Complex64Array.prototype, 'indexOf', function indexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = realf( searchElement );\n\tim = imagf( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns a new string by concatenating all array elements.\n*\n* @name join\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {string} [separator=','] - element separator\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a string\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex64Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.join();\n* // returns '1 + 1i,2 + 2i'\n*\n* str = arr.join( '/' );\n* // returns '1 + 1i/2 + 2i'\n*/\nsetReadOnly( Complex64Array.prototype, 'join', function join( separator ) {\n\tvar out;\n\tvar buf;\n\tvar sep;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( arguments.length === 0 ) {\n\t\tsep = ',';\n\t} else if ( isString( separator ) ) {\n\t\tsep = separator;\n\t} else {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a string. Value: `%s`.', separator ) );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex64( buf, i ).toString() );\n\t}\n\treturn out.join( sep );\n});\n\n/**\n* Returns the last index at which a given element can be found.\n*\n* @name lastIndexOf\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex] - index at which to start searching backward (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 3.0, -3.0 ], 4 );\n*\n* var idx = arr.lastIndexOf( new Complex64( 3.0, -3.0 ) );\n* // returns 4\n*\n* idx = arr.lastIndexOf( new Complex64( 3.0, -3.0 ), 3 );\n* // returns 2\n*\n* idx = arr.lastIndexOf( new Complex64( 5.0, -5.0 ), 3 );\n* // returns -1\n*\n* idx = arr.lastIndexOf( new Complex64( 2.0, -2.0 ), -3 );\n* // returns 1\n*/\nsetReadOnly( Complex64Array.prototype, 'lastIndexOf', function lastIndexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex >= this._length ) {\n\t\t\tfromIndex = this._length - 1;\n\t\t} else if ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t}\n\t} else {\n\t\tfromIndex = this._length - 1;\n\t}\n\tre = realf( searchElement );\n\tim = imagf( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i >= 0; i-- ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Number of array elements.\n*\n* @name length\n* @memberof Complex64Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex64Array( 10 );\n*\n* var len = arr.length;\n* // returns 10\n*/\nsetReadOnlyAccessor( Complex64Array.prototype, 'length', function get() {\n\treturn this._length;\n});\n\n/**\n* Returns a new array with each element being the result of a provided callback function.\n*\n* @name map\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} fcn - callback function\n* @param {*} [thisArg] - callback function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex64Array} complex number array\n*\n* @example\n* import Complex64 from '@stdlib/complex-float32';\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function scale( v, i ) {\n* return new Complex64( 2.0*realf( v ), 2.0*imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.map( scale );\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 2\n*\n* var im = imagf( z );\n* // returns -2\n*/\nsetReadOnly( Complex64Array.prototype, 'map', function map( fcn, thisArg ) {\n\tvar outbuf;\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar v;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tout = new this.constructor( this._length );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tv = fcn.call( thisArg, getComplex64( buf, i ), i, this );\n\t\tif ( isComplexLike( v ) ) {\n\t\t\toutbuf[ 2*i ] = realf( v );\n\t\t\toutbuf[ (2*i)+1 ] = imagf( v );\n\t\t} else if ( isArrayLikeObject( v ) && v.length === 2 ) {\n\t\t\toutbuf[ 2*i ] = v[ 0 ];\n\t\t\toutbuf[ (2*i)+1 ] = v[ 1 ];\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t}\n\t}\n\treturn out;\n});\n\n/**\n* Applies a provided callback function to each element of the array, in order, passing in the return value from the calculation on the preceding element and returning the accumulated result upon completion.\n*\n* @name reduce\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} reducer - callback function\n* @param {*} [initialValue] - initial value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @throws {Error} if not provided an initial value, the array must have at least one element\n* @returns {*} accumulated result\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import caddf from '@stdlib/math-base-ops-caddf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.reduce( caddf );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 6.0\n*\n* var im = imagf( z );\n* // returns 6.0\n*/\nsetReadOnly( Complex64Array.prototype, 'reduce', function reduce( reducer, initialValue ) {\n\tvar buf;\n\tvar acc;\n\tvar len;\n\tvar v;\n\tvar i;\n\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( reducer ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', reducer ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tacc = initialValue;\n\t\ti = 0;\n\t} else {\n\t\tif ( len === 0 ) {\n\t\t\tthrow new Error( 'invalid operation. If not provided an initial value, an array must contain at least one element.' );\n\t\t}\n\t\tacc = getComplex64( buf, 0 );\n\t\ti = 1;\n\t}\n\tfor ( ; i < len; i++ ) {\n\t\tv = getComplex64( buf, i );\n\t\tacc = reducer( acc, v, i, this );\n\t}\n\treturn acc;\n});\n\n/**\n* Reverses an array in-place.\n*\n* @name reverse\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} reversed array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.reverse();\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 3.0\n*\n* var im = imagf( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'reverse', function reverse() {\n\tvar buf;\n\tvar tmp;\n\tvar len;\n\tvar N;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tbuf = this._buffer;\n\tN = floor( len / 2 );\n\tfor ( i = 0; i < N; i++ ) {\n\t\tj = len - i - 1;\n\t\ttmp = buf[ (2*i) ];\n\t\tbuf[ (2*i) ] = buf[ (2*j) ];\n\t\tbuf[ (2*j) ] = tmp;\n\t\ttmp = buf[ (2*i)+1 ];\n\t\tbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t\tbuf[ (2*j)+1 ] = tmp;\n\t}\n\treturn this;\n});\n\n/**\n* Sets an array element.\n*\n* ## Notes\n*\n* - When provided a typed array, real or complex, we must check whether the source array shares the same buffer as the target array and whether the underlying memory overlaps. In particular, we are concerned with the following scenario:\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* In the above, as we copy values from `src`, we will overwrite values in the `src` view, resulting in duplicated values copied into the end of `buf`, which is not intended. Hence, to avoid overwriting source values, we must **copy** source values to a temporary array.\n*\n* In the other overlapping scenario,\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* by the time we begin copying into the overlapping region, we are copying from the end of `src`, a non-overlapping region, which means we don't run the risk of copying copied values, rather than the original `src` values, as intended.\n*\n* @name set\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {(Collection|Complex|ComplexArray)} value - value(s)\n* @param {NonNegativeInteger} [i=0] - element index at which to start writing values\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be either a complex number, an array-like object, or a complex number array\n* @throws {TypeError} index argument must be a nonnegative integer\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {RangeError} target array lacks sufficient storage to accommodate source values\n* @returns {void}\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 10 );\n*\n* var z = arr.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 0.0\n*\n* var im = imagf( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns -1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'set', function set( value ) {\n\t/* eslint-disable no-underscore-dangle */\n\tvar sbuf;\n\tvar idx;\n\tvar buf;\n\tvar tmp;\n\tvar flg;\n\tvar N;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tif ( arguments.length > 1 ) {\n\t\tidx = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( idx ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Index argument must be a nonnegative integer. Value: `%s`.', idx ) );\n\t\t}\n\t} else {\n\t\tidx = 0;\n\t}\n\tif ( isComplexLike( value ) ) {\n\t\tif ( idx >= this._length ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%u`.', idx ) );\n\t\t}\n\t\tidx *= 2;\n\t\tbuf[ idx ] = realf( value );\n\t\tbuf[ idx+1 ] = imagf( value );\n\t\treturn;\n\t}\n\tif ( isComplexArray( value ) ) {\n\t\tN = value._length;\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tsbuf = value._buffer;\n\n\t\t// Check for overlapping memory...\n\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\tif (\n\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t(\n\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t)\n\t\t) {\n\t\t\t// We need to copy source values...\n\t\t\ttmp = new Float32Array( sbuf.length );\n\t\t\tfor ( i = 0; i < sbuf.length; i++ ) {\n\t\t\t\ttmp[ i ] = sbuf[ i ];\n\t\t\t}\n\t\t\tsbuf = tmp;\n\t\t}\n\t\tidx *= 2;\n\t\tj = 0;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\tidx += 2; // stride\n\t\t\tj += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tif ( isCollection( value ) ) {\n\t\t// Detect whether we've been provided an array of complex numbers...\n\t\tN = value.length;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tif ( !isComplexLike( value[ i ] ) ) {\n\t\t\t\tflg = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// If an array does not contain only complex numbers, then we assume interleaved real and imaginary components...\n\t\tif ( flg ) {\n\t\t\tif ( !isEven( N ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', N ) );\n\t\t\t}\n\t\t\tif ( idx+(N/2) > this._length ) {\n\t\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t\t}\n\t\t\tsbuf = value;\n\n\t\t\t// Check for overlapping memory...\n\t\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\t\tif (\n\t\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t\t(\n\t\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\t// We need to copy source values...\n\t\t\t\ttmp = new Float32Array( N );\n\t\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\t\ttmp[ i ] = sbuf[ i ]; // TODO: handle accessor arrays\n\t\t\t\t}\n\t\t\t\tsbuf = tmp;\n\t\t\t}\n\t\t\tidx *= 2;\n\t\t\tN /= 2;\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\t\tidx += 2; // stride\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t\t// If an array contains only complex numbers, then we need to extract real and imaginary components...\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tidx *= 2;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tv = value[ i ];\n\t\t\tbuf[ idx ] = realf( v );\n\t\t\tbuf[ idx+1 ] = imagf( v );\n\t\t\tidx += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.', value ) );\n\n\t/* eslint-enable no-underscore-dangle */\n});\n\n/**\n* Copies a portion of a typed array to a new typed array.\n*\n* @name slice\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex64Array} complex number array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var out = arr.slice();\n* // returns <Complex64Array>\n*\n* var len = out.length;\n* // returns 5\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns -1.0\n*\n* z = out.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 5.0\n*\n* im = imagf( z );\n* // returns -5.0\n*\n* out = arr.slice( 1, -2 );\n* // returns <Complex64Array>\n*\n* len = out.length;\n* // returns 2\n*\n* z = out.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns -2.0\n*\n* z = out.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 3.0\n*\n* im = imagf( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex64Array.prototype, 'slice', function slice( start, end ) {\n\tvar outlen;\n\tvar outbuf;\n\tvar out;\n\tvar idx;\n\tvar buf;\n\tvar len;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tstart = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( start < end ) {\n\t\toutlen = end - start;\n\t} else {\n\t\toutlen = 0;\n\t}\n\tout = new this.constructor( outlen );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < outlen; i++ ) {\n\t\tidx = 2*(i+start);\n\t\toutbuf[ 2*i ] = buf[ idx ];\n\t\toutbuf[ (2*i)+1 ] = buf[ idx+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Tests whether at least one element in an array passes a test implemented by a predicate function.\n*\n* @name some\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether at least one element passes a test\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* function predicate( v ) {\n* return ( realf( v ) === imagf( v ) );\n* }\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var bool = arr.some( predicate );\n* // returns true\n*/\nsetReadOnly( Complex64Array.prototype, 'some', function some( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( predicate.call( thisArg, getComplex64( buf, i ), i, this ) ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Creates a new typed array view over the same underlying `ArrayBuffer` and with the same underlying data type as the host array.\n*\n* @name subarray\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} [begin=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex64Array} subarray\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var subarr = arr.subarray();\n* // returns <Complex64Array>\n*\n* var len = subarr.length;\n* // returns 5\n*\n* var z = subarr.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 1.0\n*\n* var im = imagf( z );\n* // returns -1.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 5.0\n*\n* im = imagf( z );\n* // returns -5.0\n*\n* subarr = arr.subarray( 1, -2 );\n* // returns <Complex64Array>\n*\n* len = subarr.length;\n* // returns 2\n*\n* z = subarr.get( 0 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns -2.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 3.0\n*\n* im = imagf( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex64Array.prototype, 'subarray', function subarray( begin, end ) {\n\tvar offset;\n\tvar buf;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tbegin = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( begin ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', begin ) );\n\t\t}\n\t\tif ( begin < 0 ) {\n\t\t\tbegin += len;\n\t\t\tif ( begin < 0 ) {\n\t\t\t\tbegin = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( begin >= len ) {\n\t\tlen = 0;\n\t\toffset = buf.byteLength;\n\t} else if ( begin >= end ) {\n\t\tlen = 0;\n\t\toffset = buf.byteOffset + (begin*BYTES_PER_ELEMENT);\n\t} else {\n\t\tlen = end - begin;\n\t\toffset = buf.byteOffset + ( begin*BYTES_PER_ELEMENT );\n\t}\n\treturn new this.constructor( buf.buffer, offset, ( len < 0 ) ? 0 : len );\n});\n\n/**\n* Returns a new typed array containing the elements in reversed order.\n*\n* @name toReversed\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex64Array} reversed array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.toReversed();\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 3.0\n*\n* var im = imagf( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 2.0\n*\n* im = imagf( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex64>\n*\n* re = realf( z );\n* // returns 1.0\n*\n* im = imagf( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex64Array.prototype, 'toReversed', function toReversed() {\n\tvar outbuf;\n\tvar out;\n\tvar len;\n\tvar buf;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tout = new this.constructor( len );\n\tbuf = this._buffer;\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < len; i++ ) {\n\t\tj = len - i - 1;\n\t\toutbuf[ (2*i) ] = buf[ (2*j) ];\n\t\toutbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Serializes an array as a string.\n*\n* @name toString\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex64Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.toString();\n* // returns '1 + 1i,2 + 2i'\n*/\nsetReadOnly( Complex64Array.prototype, 'toString', function toString() {\n\tvar out;\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex64( buf, i ).toString() );\n\t}\n\treturn out.join( ',' );\n});\n\n/**\n* Returns a new typed array with the element at a provided index replaced with a provided value.\n*\n* @name with\n* @memberof Complex64Array.prototype\n* @type {Function}\n* @param {integer} index - element index\n* @param {ComplexLike} value - new value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {TypeError} second argument must be a complex number\n* @returns {Complex64Array} new typed array\n*\n* @example\n* import realf from '@stdlib/complex-realf';\n* import imagf from '@stdlib/complex-imagf';\n* import Complex64 from '@stdlib/complex-float32';\n*\n* var arr = new Complex64Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.with( 0, new Complex64( 4.0, 4.0 ) );\n* // returns <Complex64Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex64>\n*\n* var re = realf( z );\n* // returns 4.0\n*\n* var im = imagf( z );\n* // returns 4.0\n*/\nsetReadOnly( Complex64Array.prototype, 'with', function copyWith( index, value ) {\n\tvar buf;\n\tvar out;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( index ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', index ) );\n\t}\n\tlen = this._length;\n\tif ( index < 0 ) {\n\t\tindex += len;\n\t}\n\tif ( index < 0 || index >= len ) {\n\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%s`.', index ) );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tout = new this.constructor( this._buffer );\n\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tbuf[ 2*index ] = realf( value );\n\tbuf[ (2*index)+1 ] = imagf( value );\n\treturn out;\n});\n\n\n// EXPORTS //\n\nexport default Complex64Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\n\n\n// MAIN //\n\n/**\n* Returns a strided array of real and imaginary components.\n*\n* @private\n* @param {Float32Array} buf - output array\n* @param {Array} arr - array containing complex numbers\n* @returns {(Float32Array|null)} output array or null\n*/\nfunction fromArray( buf, arr ) {\n\tvar len;\n\tvar v;\n\tvar i;\n\tvar j;\n\n\tlen = arr.length;\n\tj = 0;\n\tfor ( i = 0; i < len; i++ ) {\n\t\tv = arr[ i ];\n\t\tif ( !isComplexLike( v ) ) {\n\t\t\treturn null;\n\t\t}\n\t\tbuf[ j ] = realf( v );\n\t\tbuf[ j+1 ] = imagf( v );\n\t\tj += 2; // stride\n\t}\n\treturn buf;\n}\n\n\n// EXPORTS //\n\nexport default fromArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNumber } from '@stdlib/assert-is-number';\nimport defineProperty from '@stdlib/utils-define-property';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport format from '@stdlib/string-format';\nimport toStr from './tostring.js';\nimport toJSON from './tojson.js';\n\n\n// MAIN //\n\n/**\n* 128-bit complex number constructor.\n*\n* @constructor\n* @param {number} real - real component\n* @param {number} imag - imaginary component\n* @throws {TypeError} must invoke using the `new` keyword\n* @throws {TypeError} real component must be a number\n* @throws {TypeError} imaginary component must be a number\n* @returns {Complex128} 128-bit complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n* // returns <Complex128>\n*/\nfunction Complex128( real, imag ) {\n\tif ( !( this instanceof Complex128 ) ) {\n\t\tthrow new TypeError( 'invalid invocation. Constructor must be called with the `new` keyword.' );\n\t}\n\tif ( !isNumber( real ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Real component must be a number. Value: `%s`.', real ) );\n\t}\n\tif ( !isNumber( imag ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Imaginary component must be a number. Value: `%s`.', imag ) );\n\t}\n\tdefineProperty( this, 're', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': real\n\t});\n\tdefineProperty( this, 'im', {\n\t\t'configurable': false,\n\t\t'enumerable': true,\n\t\t'writable': false,\n\t\t'value': imag\n\t});\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var nbytes = Complex128.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Size (in bytes) of each component.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} size of each component\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.BYTES_PER_ELEMENT;\n* // returns 8\n*/\nsetReadOnly( Complex128.prototype, 'BYTES_PER_ELEMENT', 8 );\n\n/**\n* Length (in bytes) of a complex number.\n*\n* @name byteLength\n* @memberof Complex128.prototype\n* @type {integer}\n* @returns {integer} byte length\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var nbytes = z.byteLength;\n* // returns 16\n*/\nsetReadOnly( Complex128.prototype, 'byteLength', 16 );\n\n/**\n* Serializes a complex number as a string.\n*\n* @name toString\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {string} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var str = z.toString();\n* // returns '5 + 3i'\n*/\nsetReadOnly( Complex128.prototype, 'toString', toStr );\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* ## Notes\n*\n* - `JSON.stringify()` implicitly calls this method when stringifying a `Complex128` instance.\n*\n* @name toJSON\n* @memberof Complex128.prototype\n* @type {Function}\n* @returns {Object} serialized complex number\n*\n* @example\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var obj = z.toJSON();\n* // returns { 'type': 'Complex128', 're': 5.0, 'im': 3.0 }\n*/\nsetReadOnly( Complex128.prototype, 'toJSON', toJSON );\n\n\n// EXPORTS //\n\nexport default Complex128;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the real component of a double-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} real component\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var re = real( z );\n* // returns 5.0\n*/\nfunction real( z ) {\n\treturn z.re;\n}\n\n\n// EXPORTS //\n\nexport default real;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Returns the imaginary component of a double-precision complex floating-point number.\n*\n* @param {Complex} z - complex number\n* @returns {number} imaginary component\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var z = new Complex128( 5.0, 3.0 );\n*\n* var im = imag( z );\n* // returns 3.0\n*/\nfunction imag( z ) {\n\treturn z.im;\n}\n\n\n// EXPORTS //\n\nexport default imag;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport format from '@stdlib/string-format';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIterator( it ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\n\tout = [];\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\tz = v.value;\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( real( z ), imag( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. An iterator must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIterator;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport realf from '@stdlib/complex-realf';\nimport imagf from '@stdlib/complex-imagf';\nimport format from '@stdlib/string-format';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @param {Function} clbk - callback to invoke for each iterated value\n* @param {*} thisArg - invocation context\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIteratorMap( it, clbk, thisArg ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\tvar i;\n\n\tout = [];\n\ti = -1;\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\ti += 1;\n\t\tz = clbk.call( thisArg, v.value, i );\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( realf( z ), imagf( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIteratorMap;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a string.\n*\n* @private\n* @returns {string} serialized complex number\n*/\nfunction toString() { // eslint-disable-line stdlib/no-redeclare\n\t/* eslint-disable no-invalid-this */\n\tvar str = '' + this.re;\n\tif ( this.im < 0 ) {\n\t\tstr += ' - ' + (-this.im);\n\t} else {\n\t\tstr += ' + ' + this.im;\n\t}\n\tstr += 'i';\n\treturn str;\n}\n\n\n// EXPORTS //\n\nexport default toString;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Serializes a complex number as a JSON object.\n*\n* @private\n* @returns {Object} JSON representation\n*/\nfunction toJSON() {\n\t/* eslint-disable no-invalid-this */\n\tvar out = {};\n\tout.type = 'Complex128';\n\tout.re = this.re;\n\tout.im = this.im;\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default toJSON;\n","/* eslint-disable no-restricted-syntax, max-lines, no-invalid-this */\n\n/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport { isPrimitive as isNonNegativeInteger } from '@stdlib/assert-is-nonnegative-integer';\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isCollection from '@stdlib/assert-is-collection';\nimport isArrayBuffer from '@stdlib/assert-is-arraybuffer';\nimport isObject from '@stdlib/assert-is-object';\nimport isArray from '@stdlib/assert-is-array';\nimport isString from '@stdlib/assert-is-string';\nimport isFunction from '@stdlib/assert-is-function';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport isEven from '@stdlib/math-base-assert-is-even';\nimport isInteger from '@stdlib/math-base-assert-is-integer';\nimport isComplex64Array from '@stdlib/array-base-assert-is-complex64array';\nimport isComplex128Array from '@stdlib/array-base-assert-is-complex128array';\nimport hasIteratorSymbolSupport from '@stdlib/assert-has-iterator-symbol-support';\nimport ITERATOR_SYMBOL from '@stdlib/symbol-iterator';\nimport setReadOnly from '@stdlib/utils-define-nonenumerable-read-only-property';\nimport setReadOnlyAccessor from '@stdlib/utils-define-nonenumerable-read-only-accessor';\nimport Float64Array from '@stdlib/array-float64';\nimport Complex128 from '@stdlib/complex-float64';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\nimport floor from '@stdlib/math-base-special-floor';\nimport reinterpret64 from '@stdlib/strided-base-reinterpret-complex64';\nimport reinterpret128 from '@stdlib/strided-base-reinterpret-complex128';\nimport getter from '@stdlib/array-base-getter';\nimport accessorGetter from '@stdlib/array-base-accessor-getter';\nimport format from '@stdlib/string-format';\nimport fromIterator from './from_iterator.js';\nimport fromIteratorMap from './from_iterator_map.js';\nimport fromArray from './from_array.js';\n\n\n// VARIABLES //\n\nvar BYTES_PER_ELEMENT = Float64Array.BYTES_PER_ELEMENT * 2;\nvar HAS_ITERATOR_SYMBOL = hasIteratorSymbolSupport();\n\n\n// FUNCTIONS //\n\n/**\n* Returns a boolean indicating if a value is a complex typed array.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array\n*/\nfunction isComplexArray( value ) {\n\treturn (\n\t\tvalue instanceof Complex128Array ||\n\t\t(\n\t\t\ttypeof value === 'object' &&\n\t\t\tvalue !== null &&\n\t\t\t(\n\t\t\t\tvalue.constructor.name === 'Complex64Array' ||\n\t\t\t\tvalue.constructor.name === 'Complex128Array'\n\t\t\t) &&\n\t\t\ttypeof value._length === 'number' && // eslint-disable-line no-underscore-dangle\n\n\t\t\t// NOTE: we don't perform a more rigorous test here for a typed array for performance reasons, as robustly checking for a typed array instance could require walking the prototype tree and performing relatively expensive constructor checks...\n\t\t\ttypeof value._buffer === 'object' // eslint-disable-line no-underscore-dangle\n\t\t)\n\t);\n}\n\n/**\n* Returns a boolean indicating if a value is a complex typed array constructor.\n*\n* @private\n* @param {*} value - value to test\n* @returns {boolean} boolean indicating if a value is a complex typed array constructor\n*/\nfunction isComplexArrayConstructor( value ) {\n\treturn (\n\t\tvalue === Complex128Array ||\n\n\t\t// NOTE: weaker test in order to avoid a circular dependency with Complex64Array...\n\t\tvalue.name === 'Complex64Array'\n\t);\n}\n\n/**\n* Retrieves a complex number from a complex number array buffer.\n*\n* @private\n* @param {Float64Array} buf - array buffer\n* @param {NonNegativeInteger} idx - element index\n* @returns {Complex128} complex number\n*/\nfunction getComplex128( buf, idx ) {\n\tidx *= 2;\n\treturn new Complex128( buf[ idx ], buf[ idx+1 ] );\n}\n\n\n// MAIN //\n\n/**\n* 128-bit complex number array constructor.\n*\n* @constructor\n* @param {(NonNegativeInteger|Collection|ArrayBuffer|Iterable)} [arg] - length, typed array, array-like object, buffer, or iterable\n* @param {NonNegativeInteger} [byteOffset=0] - byte offset\n* @param {NonNegativeInteger} [length] - view length\n* @throws {RangeError} ArrayBuffer byte length must be a multiple of `16`\n* @throws {RangeError} array-like object and typed array input arguments must have a length which is a multiple of two\n* @throws {TypeError} if provided only a single argument, must provide a valid argument\n* @throws {TypeError} byte offset must be a nonnegative integer\n* @throws {RangeError} byte offset must be a multiple of `16`\n* @throws {TypeError} view length must be a positive multiple of `16`\n* @throws {RangeError} must provide sufficient memory to accommodate byte offset and view length requirements\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex128Array} complex number array\n*\n* @example\n* var arr = new Complex128Array();\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 0\n*\n* @example\n* var arr = new Complex128Array( 2 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* var arr = new Complex128Array( [ 1.0, -1.0 ] );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 32 );\n* var arr = new Complex128Array( buf );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 32 );\n* var arr = new Complex128Array( buf, 16 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import ArrayBuffer from '@stdlib/array-buffer';\n*\n* var buf = new ArrayBuffer( 64 );\n* var arr = new Complex128Array( buf, 16, 2 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nfunction Complex128Array() {\n\tvar byteOffset;\n\tvar nargs;\n\tvar buf;\n\tvar len;\n\n\tnargs = arguments.length;\n\tif ( !(this instanceof Complex128Array) ) {\n\t\tif ( nargs === 0 ) {\n\t\t\treturn new Complex128Array();\n\t\t}\n\t\tif ( nargs === 1 ) {\n\t\t\treturn new Complex128Array( arguments[0] );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\treturn new Complex128Array( arguments[0], arguments[1] );\n\t\t}\n\t\treturn new Complex128Array( arguments[0], arguments[1], arguments[2] );\n\t}\n\t// Create the underlying data buffer...\n\tif ( nargs === 0 ) {\n\t\tbuf = new Float64Array( 0 ); // backward-compatibility\n\t} else if ( nargs === 1 ) {\n\t\tif ( isNonNegativeInteger( arguments[0] ) ) {\n\t\t\tbuf = new Float64Array( arguments[0]*2 );\n\t\t} else if ( isCollection( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tlen = buf.length;\n\n\t\t\t// If provided a \"generic\" array, peak at the first value, and, if the value is a complex number, try to process as an array of complex numbers, falling back to \"normal\" typed array initialization if we fail and ensuring consistency if the first value had not been a complex number...\n\t\t\tif ( len && isArray( buf ) && isComplexLike( buf[0] ) ) {\n\t\t\t\tbuf = fromArray( new Float64Array( len*2 ), buf );\n\t\t\t\tif ( buf === null ) {\n\t\t\t\t\t// We failed and we are now forced to allocate a new array :-(\n\t\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t\t}\n\t\t\t\t\t// We failed, so fall back to directly setting values...\n\t\t\t\t\tbuf = new Float64Array( arguments[0] );\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif ( isComplex64Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret64( buf, 0 );\n\t\t\t\t} else if ( isComplex128Array( buf ) ) {\n\t\t\t\t\tbuf = reinterpret128( buf, 0 );\n\t\t\t\t} else if ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object and typed array arguments must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t}\n\t\t\t\tbuf = new Float64Array( buf );\n\t\t\t}\n\t\t} else if ( isArrayBuffer( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( !isInteger( buf.byteLength/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. ArrayBuffer byte length must be a multiple of %u. Byte length: `%u`.', BYTES_PER_ELEMENT, buf.byteLength ) );\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf );\n\t\t} else if ( isObject( arguments[0] ) ) {\n\t\t\tbuf = arguments[ 0 ];\n\t\t\tif ( HAS_ITERATOR_SYMBOL === false ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Environment lacks Symbol.iterator support. Must provide a length, ArrayBuffer, typed array, or array-like object. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tif ( !isFunction( buf[ ITERATOR_SYMBOL ] ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tbuf = buf[ ITERATOR_SYMBOL ]();\n\t\t\tif ( !isFunction( buf.next ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', buf ) );\n\t\t\t}\n\t\t\tbuf = fromIterator( buf );\n\t\t\tif ( buf instanceof Error ) {\n\t\t\t\tthrow buf;\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf );\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Must provide a length, ArrayBuffer, typed array, array-like object, or an iterable. Value: `%s`.', arguments[0] ) );\n\t\t}\n\t} else {\n\t\tbuf = arguments[ 0 ];\n\t\tif ( !isArrayBuffer( buf ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an ArrayBuffer. Value: `%s`.', buf ) );\n\t\t}\n\t\tbyteOffset = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( byteOffset ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Byte offset must be a nonnegative integer. Value: `%s`.', byteOffset ) );\n\t\t}\n\t\tif ( !isInteger( byteOffset/BYTES_PER_ELEMENT ) ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Byte offset must be a multiple of %u. Value: `%u`.', BYTES_PER_ELEMENT, byteOffset ) );\n\t\t}\n\t\tif ( nargs === 2 ) {\n\t\t\tlen = buf.byteLength - byteOffset;\n\t\t\tif ( !isInteger( len/BYTES_PER_ELEMENT ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer view byte length must be a multiple of %u. View byte length: `%u`.', BYTES_PER_ELEMENT, len ) );\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf, byteOffset );\n\t\t} else {\n\t\t\tlen = arguments[ 2 ];\n\t\t\tif ( !isNonNegativeInteger( len ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Length must be a nonnegative integer. Value: `%s`.', len ) );\n\t\t\t}\n\t\t\tif ( (len*BYTES_PER_ELEMENT) > (buf.byteLength-byteOffset) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid arguments. ArrayBuffer has insufficient capacity. Either decrease the array length or provide a bigger buffer. Minimum capacity: `%u`.', len*BYTES_PER_ELEMENT ) );\n\t\t\t}\n\t\t\tbuf = new Float64Array( buf, byteOffset, len*2 );\n\t\t}\n\t}\n\tsetReadOnly( this, '_buffer', buf );\n\tsetReadOnly( this, '_length', buf.length/2 );\n\n\treturn this;\n}\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128Array\n* @readonly\n* @type {PositiveInteger}\n* @default 16\n*\n* @example\n* var nbytes = Complex128Array.BYTES_PER_ELEMENT;\n* // returns 16\n*/\nsetReadOnly( Complex128Array, 'BYTES_PER_ELEMENT', BYTES_PER_ELEMENT );\n\n/**\n* Constructor name.\n*\n* @name name\n* @memberof Complex128Array\n* @readonly\n* @type {string}\n* @default 'Complex128Array'\n*\n* @example\n* var name = Complex128Array.name;\n* // returns 'Complex128Array'\n*/\nsetReadOnly( Complex128Array, 'name', 'Complex128Array' );\n\n/**\n* Creates a new 128-bit complex number array from an array-like object or an iterable.\n*\n* @name from\n* @memberof Complex128Array\n* @type {Function}\n* @param {(Collection|Object)} src - array-like object or iterable\n* @param {Function} [clbk] - callback to invoke for each source element\n* @param {*} [thisArg] - context\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an array-like object or an iterable\n* @throws {TypeError} second argument must be a function\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {TypeError} an iterator must return either a two element array containing real and imaginary components or a complex number\n* @throws {TypeError} when provided an iterator, a callback must return either a two element array containing real and imaginary components or a complex number\n* @returns {Complex128Array} 128-bit complex number array\n*\n* @example\n* var arr = Complex128Array.from( [ 1.0, -1.0 ] );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = Complex128Array.from( [ new Complex128( 1.0, 1.0 ) ] );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function clbk( v ) {\n* return new Complex128( real(v)*2.0, imag(v)*2.0 );\n* }\n*\n* var arr = Complex128Array.from( [ new Complex128( 1.0, 1.0 ) ], clbk );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 1\n*/\nsetReadOnly( Complex128Array, 'from', function from( src ) {\n\tvar thisArg;\n\tvar nargs;\n\tvar clbk;\n\tvar out;\n\tvar buf;\n\tvar tmp;\n\tvar get;\n\tvar len;\n\tvar flg;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tnargs = arguments.length;\n\tif ( nargs > 1 ) {\n\t\tclbk = arguments[ 1 ];\n\t\tif ( !isFunction( clbk ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a function. Value: `%s`.', clbk ) );\n\t\t}\n\t\tif ( nargs > 2 ) {\n\t\t\tthisArg = arguments[ 2 ];\n\t\t}\n\t}\n\tif ( isComplexArray( src ) ) {\n\t\tlen = src.length;\n\t\tif ( clbk ) {\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, src.get( i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = real( v );\n\t\t\t\t\tbuf[ j+1 ] = imag( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isCollection( src ) ) {\n\t\tif ( clbk ) {\n\t\t\t// Note: array contents affect how we iterate over a provided data source. If only complex number objects, we can extract real and imaginary components. Otherwise, for non-complex number arrays (e.g., `Float64Array`, etc), we assume a strided array where real and imaginary components are interleaved. In the former case, we expect a callback to return real and imaginary components (possibly as a complex number). In the latter case, we expect a callback to return *either* a real or imaginary component.\n\n\t\t\tlen = src.length;\n\t\t\tif ( src.get && src.set ) {\n\t\t\t\tget = accessorGetter( 'default' );\n\t\t\t} else {\n\t\t\t\tget = getter( 'default' );\n\t\t\t}\n\t\t\t// Detect whether we've been provided an array which returns complex number objects...\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tif ( !isComplexLike( get( src, i ) ) ) {\n\t\t\t\t\tflg = true;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// If an array does not contain only complex number objects, then we assume interleaved real and imaginary components...\n\t\t\tif ( flg ) {\n\t\t\t\tif ( !isEven( len ) ) {\n\t\t\t\t\tthrow new RangeError( format( 'invalid argument. First argument must have a length which is a multiple of two. Length: `%u`.', len ) );\n\t\t\t\t}\n\t\t\t\tout = new this( len/2 );\n\t\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\t\tbuf[ i ] = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\t}\n\t\t\t\treturn out;\n\t\t\t}\n\t\t\t// If an array contains only complex number objects, then we need to extract real and imaginary components...\n\t\t\tout = new this( len );\n\t\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\tv = clbk.call( thisArg, get( src, i ), i );\n\t\t\t\tif ( isComplexLike( v ) ) {\n\t\t\t\t\tbuf[ j ] = real( v );\n\t\t\t\t\tbuf[ j+1 ] = imag( v );\n\t\t\t\t} else if ( isArrayLikeObject( v ) && v.length >= 2 ) {\n\t\t\t\t\tbuf[ j ] = v[ 0 ];\n\t\t\t\t\tbuf[ j+1 ] = v[ 1 ];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t\t\t}\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn out;\n\t\t}\n\t\treturn new this( src );\n\t}\n\tif ( isObject( src ) && HAS_ITERATOR_SYMBOL && isFunction( src[ ITERATOR_SYMBOL ] ) ) { // eslint-disable-line max-len\n\t\tbuf = src[ ITERATOR_SYMBOL ]();\n\t\tif ( !isFunction( buf.next ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n\t\t}\n\t\tif ( clbk ) {\n\t\t\ttmp = fromIteratorMap( buf, clbk, thisArg );\n\t\t} else {\n\t\t\ttmp = fromIterator( buf );\n\t\t}\n\t\tif ( tmp instanceof Error ) {\n\t\t\tthrow tmp;\n\t\t}\n\t\tlen = tmp.length / 2;\n\t\tout = new this( len );\n\t\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\tbuf[ i ] = tmp[ i ];\n\t\t}\n\t\treturn out;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be an array-like object or an iterable. Value: `%s`.', src ) );\n});\n\n/**\n* Creates a new 128-bit complex number array from a variable number of arguments.\n*\n* @name of\n* @memberof Complex128Array\n* @type {Function}\n* @param {...*} element - array elements\n* @throws {TypeError} `this` context must be a constructor\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} 128-bit complex number array\n*\n* @example\n* var arr = Complex128Array.of( 1.0, 1.0, 1.0, 1.0 );\n* // returns <Complex128Array>\n*\n* var len = arr.length;\n* // returns 2\n*/\nsetReadOnly( Complex128Array, 'of', function of() {\n\tvar args;\n\tvar i;\n\tif ( !isFunction( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` context must be a constructor.' );\n\t}\n\tif ( !isComplexArrayConstructor( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\targs = [];\n\tfor ( i = 0; i < arguments.length; i++ ) {\n\t\targs.push( arguments[ i ] );\n\t}\n\treturn new this( args );\n});\n\n/**\n* Returns an array element with support for both nonnegative and negative integer indices.\n*\n* @name at\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide an integer\n* @returns {(Complex128|void)} array element\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 10 );\n*\n* var z = arr.at( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 0.0\n*\n* var im = imag( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 9.0, -9.0 ], 9 );\n*\n* z = arr.at( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns -1.0\n*\n* z = arr.at( -1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 9.0\n*\n* im = imag( z );\n* // returns -9.0\n*\n* z = arr.at( 100 );\n* // returns undefined\n*\n* z = arr.at( -100 );\n* // returns undefined\n*/\nsetReadOnly( Complex128Array.prototype, 'at', function at( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide an integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx < 0 ) {\n\t\tidx += this._length;\n\t}\n\tif ( idx < 0 || idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex128( this._buffer, idx );\n});\n\n/**\n* Pointer to the underlying data buffer.\n*\n* @name buffer\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {ArrayBuffer}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var buf = arr.buffer;\n* // returns <ArrayBuffer>\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'buffer', function get() {\n\treturn this._buffer.buffer;\n});\n\n/**\n* Size (in bytes) of the array.\n*\n* @name byteLength\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var byteLength = arr.byteLength;\n* // returns 160\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'byteLength', function get() {\n\treturn this._buffer.byteLength;\n});\n\n/**\n* Offset (in bytes) of the array from the start of its underlying `ArrayBuffer`.\n*\n* @name byteOffset\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var byteOffset = arr.byteOffset;\n* // returns 0\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'byteOffset', function get() {\n\treturn this._buffer.byteOffset;\n});\n\n/**\n* Size (in bytes) of each array element.\n*\n* @name BYTES_PER_ELEMENT\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {PositiveInteger}\n* @default 16\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var nbytes = arr.BYTES_PER_ELEMENT;\n* // returns 16\n*/\nsetReadOnly( Complex128Array.prototype, 'BYTES_PER_ELEMENT', Complex128Array.BYTES_PER_ELEMENT );\n\n/**\n* Copies a sequence of elements within the array to the position starting at `target`.\n*\n* @name copyWithin\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} target - index at which to start copying elements\n* @param {integer} start - source index at which to copy elements from\n* @param {integer} [end] - source index at which to stop copying elements from\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} modified array\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 4 );\n*\n* // Set the array elements:\n* arr.set( new Complex128( 1.0, 1.0 ), 0 );\n* arr.set( new Complex128( 2.0, 2.0 ), 1 );\n* arr.set( new Complex128( 3.0, 3.0 ), 2 );\n* arr.set( new Complex128( 4.0, 4.0 ), 3 );\n*\n* // Copy the first two elements to the last two elements:\n* arr.copyWithin( 2, 0, 2 );\n*\n* // Get the last array element:\n* var z = arr.get( 3 );\n*\n* var re = real( z );\n* // returns 2.0\n*\n* var im = imag( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex128Array.prototype, 'copyWithin', function copyWithin( target, start ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\t// FIXME: prefer a functional `copyWithin` implementation which addresses lack of universal browser support (e.g., IE11 and Safari) or ensure that typed arrays are polyfilled\n\tif ( arguments.length === 2 ) {\n\t\tthis._buffer.copyWithin( target*2, start*2 );\n\t} else {\n\t\tthis._buffer.copyWithin( target*2, start*2, arguments[2]*2 );\n\t}\n\treturn this;\n});\n\n/**\n* Returns an iterator for iterating over array key-value pairs.\n*\n* @name entries\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Iterator} iterator\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = [\n* new Complex128( 1.0, 1.0 ),\n* new Complex128( 2.0, 2.0 ),\n* new Complex128( 3.0, 3.0 )\n* ];\n* arr = new Complex128Array( arr );\n*\n* // Create an iterator:\n* var it = arr.entries();\n*\n* // Iterate over the key-value pairs...\n* var v = it.next().value;\n* // returns [ 0, <Complex128> ]\n*\n* v = it.next().value;\n* // returns [ 1, <Complex128> ]\n*\n* v = it.next().value;\n* // returns [ 2, <Complex128> ]\n*\n* var bool = it.next().done;\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'entries', function entries() {\n\tvar buffer;\n\tvar self;\n\tvar iter;\n\tvar len;\n\tvar FLG;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tself = this;\n\tbuffer = this._buffer;\n\tlen = this._length;\n\n\t// Initialize the iteration indices:\n\ti = -1;\n\tj = -2;\n\n\t// Create an iterator protocol-compliant object:\n\titer = {};\n\tsetReadOnly( iter, 'next', next );\n\tsetReadOnly( iter, 'return', end );\n\n\tif ( ITERATOR_SYMBOL ) {\n\t\tsetReadOnly( iter, ITERATOR_SYMBOL, factory );\n\t}\n\treturn iter;\n\n\t/**\n\t* Returns an iterator protocol-compliant object containing the next iterated value.\n\t*\n\t* @private\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction next() {\n\t\tvar z;\n\t\ti += 1;\n\t\tif ( FLG || i >= len ) {\n\t\t\treturn {\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\tj += 2;\n\t\tz = new Complex128( buffer[ j ], buffer[ j+1 ] );\n\t\treturn {\n\t\t\t'value': [ i, z ],\n\t\t\t'done': false\n\t\t};\n\t}\n\n\t/**\n\t* Finishes an iterator.\n\t*\n\t* @private\n\t* @param {*} [value] - value to return\n\t* @returns {Object} iterator protocol-compliant object\n\t*/\n\tfunction end( value ) {\n\t\tFLG = true;\n\t\tif ( arguments.length ) {\n\t\t\treturn {\n\t\t\t\t'value': value,\n\t\t\t\t'done': true\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\t'done': true\n\t\t};\n\t}\n\n\t/**\n\t* Returns a new iterator.\n\t*\n\t* @private\n\t* @returns {Iterator} iterator\n\t*/\n\tfunction factory() {\n\t\treturn self.entries();\n\t}\n});\n\n/**\n* Tests whether all elements in an array pass a test implemented by a predicate function.\n*\n* @name every\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether all elements pass a test\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var bool = arr.every( predicate );\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'every', function every( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( !predicate.call( thisArg, getComplex128( buf, i ), i, this ) ) {\n\t\t\treturn false;\n\t\t}\n\t}\n\treturn true;\n});\n\n/**\n* Returns a modified typed array filled with a fill value.\n*\n* @name fill\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} value - fill value\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @throws {TypeError} third argument must be an integer\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.fill( new Complex128( 1.0, 1.0 ), 1 );\n*\n* var z = arr.get( 1 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns 1.0\n*\n* z = arr.get( 1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'fill', function fill( value, start, end ) {\n\tvar buf;\n\tvar len;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length > 2 ) {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Third argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t} else {\n\t\t\tend = len;\n\t\t}\n\t} else {\n\t\tstart = 0;\n\t\tend = len;\n\t}\n\tre = real( value );\n\tim = imag( value );\n\tfor ( i = start; i < end; i++ ) {\n\t\tidx = 2*i;\n\t\tbuf[ idx ] = re;\n\t\tbuf[ idx+1 ] = im;\n\t}\n\treturn this;\n});\n\n/**\n* Returns a new array containing the elements of an array which pass a test implemented by a predicate function.\n*\n* @name filter\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex128Array} complex number array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.filter( predicate );\n* // returns <Complex128Array>\n*\n* var len = out.length;\n* // returns 1\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 2.0\n*\n* var im = imag( z );\n* // returns 2.0\n*/\nsetReadOnly( Complex128Array.prototype, 'filter', function filter( predicate, thisArg ) {\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tout = [];\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\tout.push( z );\n\t\t}\n\t}\n\treturn new this.constructor( out );\n});\n\n/**\n* Returns the first element in an array for which a predicate function returns a truthy value.\n*\n* @name find\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex128|void)} array element or undefined\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.find( predicate );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'find', function find( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the first element in an array for which a predicate function returns a truthy value.\n*\n* @name findIndex\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var idx = arr.findIndex( predicate );\n* // returns 2\n*/\nsetReadOnly( Complex128Array.prototype, 'findIndex', function findIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLast\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {(Complex128|void)} array element or undefined\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.findLast( predicate );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 3.0\n*\n* var im = imag( z );\n* // returns 3.0\n*/\nsetReadOnly( Complex128Array.prototype, 'findLast', function findLast( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn z;\n\t\t}\n\t}\n});\n\n/**\n* Returns the index of the last element in an array for which a predicate function returns a truthy value.\n*\n* @name findLastIndex\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {integer} index or -1\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var idx = arr.findLastIndex( predicate );\n* // returns 1\n*/\nsetReadOnly( Complex128Array.prototype, 'findLastIndex', function findLastIndex( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = this._length-1; i >= 0; i-- ) {\n\t\tz = getComplex128( buf, i );\n\t\tif ( predicate.call( thisArg, z, i, this ) ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Invokes a function once for each array element.\n*\n* @name forEach\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} fcn - function to invoke\n* @param {*} [thisArg] - function invocation context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* function log( v, i ) {\n* console.log( '%s: %s', i, v.toString() );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* arr.forEach( log );\n*/\nsetReadOnly( Complex128Array.prototype, 'forEach', function forEach( fcn, thisArg ) {\n\tvar buf;\n\tvar i;\n\tvar z;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tz = getComplex128( buf, i );\n\t\tfcn.call( thisArg, z, i, this );\n\t}\n});\n\n/**\n* Returns an array element.\n*\n* @name get\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {NonNegativeInteger} idx - element index\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} must provide a nonnegative integer\n* @returns {(Complex128|void)} array element\n*\n* @example\n* var arr = new Complex128Array( 10 );\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var z = arr.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 0.0\n*\n* var im = imag( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns -1.0\n*\n* z = arr.get( 100 );\n* // returns undefined\n*/\nsetReadOnly( Complex128Array.prototype, 'get', function get( idx ) {\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isNonNegativeInteger( idx ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Must provide a nonnegative integer. Value: `%s`.', idx ) );\n\t}\n\tif ( idx >= this._length ) {\n\t\treturn;\n\t}\n\treturn getComplex128( this._buffer, idx );\n});\n\n/**\n* Number of array elements.\n*\n* @name length\n* @memberof Complex128Array.prototype\n* @readonly\n* @type {NonNegativeInteger}\n*\n* @example\n* var arr = new Complex128Array( 10 );\n*\n* var len = arr.length;\n* // returns 10\n*/\nsetReadOnlyAccessor( Complex128Array.prototype, 'length', function get() {\n\treturn this._length;\n});\n\n/**\n* Returns a boolean indicating whether an array includes a provided value.\n*\n* @name includes\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - search element\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {boolean} boolean indicating whether an array includes a provided value\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var bool = arr.includes( new Complex128( 3.0, -3.0 ) );\n* // returns true\n*\n* bool = arr.includes( new Complex128( 3.0, -3.0 ), 3 );\n* // returns false\n*\n* bool = arr.includes( new Complex128( 4.0, -4.0 ), -3 );\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'includes', function includes( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = real( searchElement );\n\tim = imag( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Returns the first index at which a given element can be found.\n*\n* @name indexOf\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex=0] - starting index (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var idx = arr.indexOf( new Complex128( 3.0, -3.0 ) );\n* // returns 2\n*\n* idx = arr.indexOf( new Complex128( 3.0, -3.0 ), 3 );\n* // returns -1\n*\n* idx = arr.indexOf( new Complex128( 4.0, -4.0 ), -3 );\n* // returns 3\n*/\nsetReadOnly( Complex128Array.prototype, 'indexOf', function indexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t\tif ( fromIndex < 0 ) {\n\t\t\t\tfromIndex = 0;\n\t\t\t}\n\t\t}\n\t} else {\n\t\tfromIndex = 0;\n\t}\n\tre = real( searchElement );\n\tim = imag( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i < this._length; i++ ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns a new string by concatenating all array elements.\n*\n* @name join\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {string} [separator=','] - element separator\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a string\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex128Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.join();\n* // returns '1 + 1i,2 + 2i'\n*\n* str = arr.join( '/' );\n* // returns '1 + 1i/2 + 2i'\n*/\nsetReadOnly( Complex128Array.prototype, 'join', function join( separator ) {\n\tvar out;\n\tvar buf;\n\tvar sep;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( arguments.length === 0 ) {\n\t\tsep = ',';\n\t} else if ( isString( separator ) ) {\n\t\tsep = separator;\n\t} else {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a string. Value: `%s`.', separator ) );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex128( buf, i ).toString() );\n\t}\n\treturn out.join( sep );\n});\n\n/**\n* Returns the last index at which a given element can be found.\n*\n* @name lastIndexOf\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {ComplexLike} searchElement - element to find\n* @param {integer} [fromIndex] - index at which to start searching backward (inclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a complex number\n* @throws {TypeError} second argument must be an integer\n* @returns {integer} index or -1\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 3.0, -3.0 ], 4 );\n*\n* var idx = arr.lastIndexOf( new Complex128( 3.0, -3.0 ) );\n* // returns 4\n*\n* idx = arr.lastIndexOf( new Complex128( 3.0, -3.0 ), 3 );\n* // returns 2\n*\n* idx = arr.lastIndexOf( new Complex128( 5.0, -5.0 ), 3 );\n* // returns -1\n*\n* idx = arr.lastIndexOf( new Complex128( 2.0, -2.0 ), -3 );\n* // returns 1\n*/\nsetReadOnly( Complex128Array.prototype, 'lastIndexOf', function lastIndexOf( searchElement, fromIndex ) {\n\tvar buf;\n\tvar idx;\n\tvar re;\n\tvar im;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isComplexLike( searchElement ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a complex number. Value: `%s`.', searchElement ) );\n\t}\n\tif ( arguments.length > 1 ) {\n\t\tif ( !isInteger( fromIndex ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', fromIndex ) );\n\t\t}\n\t\tif ( fromIndex >= this._length ) {\n\t\t\tfromIndex = this._length - 1;\n\t\t} else if ( fromIndex < 0 ) {\n\t\t\tfromIndex += this._length;\n\t\t}\n\t} else {\n\t\tfromIndex = this._length - 1;\n\t}\n\tre = real( searchElement );\n\tim = imag( searchElement );\n\tbuf = this._buffer;\n\tfor ( i = fromIndex; i >= 0; i-- ) {\n\t\tidx = 2 * i;\n\t\tif ( re === buf[ idx ] && im === buf[ idx+1 ] ) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n});\n\n/**\n* Returns a new array with each element being the result of a provided callback function.\n*\n* @name map\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} fcn - callback function\n* @param {*} [thisArg] - callback function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {Complex128Array} complex number array\n*\n* @example\n* import Complex128 from '@stdlib/complex-float64';\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function scale( v, i ) {\n* return new Complex128( 2.0*real( v ), 2.0*imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var out = arr.map( scale );\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 2.0\n*\n* var im = imag( z );\n* // returns -2.0\n*/\nsetReadOnly( Complex128Array.prototype, 'map', function map( fcn, thisArg ) {\n\tvar outbuf;\n\tvar buf;\n\tvar out;\n\tvar i;\n\tvar v;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( fcn ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', fcn ) );\n\t}\n\tbuf = this._buffer;\n\tout = new this.constructor( this._length );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tv = fcn.call( thisArg, getComplex128( buf, i ), i, this );\n\t\tif ( isComplexLike( v ) ) {\n\t\t\toutbuf[ 2*i ] = real( v );\n\t\t\toutbuf[ (2*i)+1 ] = imag( v );\n\t\t} else if ( isArrayLikeObject( v ) && v.length === 2 ) {\n\t\t\toutbuf[ 2*i ] = v[ 0 ];\n\t\t\toutbuf[ (2*i)+1 ] = v[ 1 ];\n\t\t} else {\n\t\t\tthrow new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', v ) );\n\t\t}\n\t}\n\treturn out;\n});\n\n/**\n* Applies a provided callback function to each element of the array, in order, passing in the return value from the calculation on the preceding element and returning the accumulated result upon completion.\n*\n* @name reduce\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} reducer - callback function\n* @param {*} [initialValue] - initial value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @throws {Error} if not provided an initial value, the array must have at least one element\n* @returns {*} accumulated result\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n* import cadd from '@stdlib/math-base-ops-cadd';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var z = arr.reduce( cadd );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 6.0\n*\n* var im = imag( z );\n* // returns 6.0\n*/\nsetReadOnly( Complex128Array.prototype, 'reduce', function reduce( reducer, initialValue ) {\n\tvar buf;\n\tvar acc;\n\tvar len;\n\tvar v;\n\tvar i;\n\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( reducer ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', reducer ) );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length > 1 ) {\n\t\tacc = initialValue;\n\t\ti = 0;\n\t} else {\n\t\tif ( len === 0 ) {\n\t\t\tthrow new Error( 'invalid operation. If not provided an initial value, an array must contain at least one element.' );\n\t\t}\n\t\tacc = getComplex128( buf, 0 );\n\t\ti = 1;\n\t}\n\tfor ( ; i < len; i++ ) {\n\t\tv = getComplex128( buf, i );\n\t\tacc = reducer( acc, v, i, this );\n\t}\n\treturn acc;\n});\n\n/**\n* Reverses an array in-place.\n*\n* @name reverse\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} reversed array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.reverse();\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 3.0\n*\n* var im = imag( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'reverse', function reverse() {\n\tvar buf;\n\tvar tmp;\n\tvar len;\n\tvar N;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tbuf = this._buffer;\n\tN = floor( len / 2 );\n\tfor ( i = 0; i < N; i++ ) {\n\t\tj = len - i - 1;\n\t\ttmp = buf[ (2*i) ];\n\t\tbuf[ (2*i) ] = buf[ (2*j) ];\n\t\tbuf[ (2*j) ] = tmp;\n\t\ttmp = buf[ (2*i)+1 ];\n\t\tbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t\tbuf[ (2*j)+1 ] = tmp;\n\t}\n\treturn this;\n});\n\n/**\n* Sets an array element.\n*\n* ## Notes\n*\n* - When provided a typed array, real or complex, we must check whether the source array shares the same buffer as the target array and whether the underlying memory overlaps. In particular, we are concerned with the following scenario:\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* In the above, as we copy values from `src`, we will overwrite values in the `src` view, resulting in duplicated values copied into the end of `buf`, which is not intended. Hence, to avoid overwriting source values, we must **copy** source values to a temporary array.\n*\n* In the other overlapping scenario,\n*\n* ```text\n* buf: ---------------------\n* src: ---------------------\n* ```\n*\n* by the time we begin copying into the overlapping region, we are copying from the end of `src`, a non-overlapping region, which means we don't run the risk of copying copied values, rather than the original `src` values as intended.\n*\n* @name set\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {(Collection|Complex|ComplexArray)} value - value(s)\n* @param {NonNegativeInteger} [i=0] - element index at which to start writing values\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be either a complex number, an array-like object, or a complex number array\n* @throws {TypeError} index argument must be a nonnegative integer\n* @throws {RangeError} array-like objects must have a length which is a multiple of two\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {RangeError} target array lacks sufficient storage to accommodate source values\n* @returns {void}\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 10 );\n*\n* var z = arr.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 0.0\n*\n* var im = imag( z );\n* // returns 0.0\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n*\n* z = arr.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns -1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'set', function set( value ) {\n\t/* eslint-disable no-underscore-dangle */\n\tvar sbuf;\n\tvar idx;\n\tvar buf;\n\tvar tmp;\n\tvar flg;\n\tvar N;\n\tvar v;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tif ( arguments.length > 1 ) {\n\t\tidx = arguments[ 1 ];\n\t\tif ( !isNonNegativeInteger( idx ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. Index argument must be a nonnegative integer. Value: `%s`.', idx ) );\n\t\t}\n\t} else {\n\t\tidx = 0;\n\t}\n\tif ( isComplexLike( value ) ) {\n\t\tif ( idx >= this._length ) {\n\t\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%u`.', idx ) );\n\t\t}\n\t\tidx *= 2;\n\t\tbuf[ idx ] = real( value );\n\t\tbuf[ idx+1 ] = imag( value );\n\t\treturn;\n\t}\n\tif ( isComplexArray( value ) ) {\n\t\tN = value._length;\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tsbuf = value._buffer;\n\n\t\t// Check for overlapping memory...\n\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\tif (\n\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t(\n\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t)\n\t\t) {\n\t\t\t// We need to copy source values...\n\t\t\ttmp = new Float64Array( sbuf.length );\n\t\t\tfor ( i = 0; i < sbuf.length; i++ ) {\n\t\t\t\ttmp[ i ] = sbuf[ i ];\n\t\t\t}\n\t\t\tsbuf = tmp;\n\t\t}\n\t\tidx *= 2;\n\t\tj = 0;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\tidx += 2; // stride\n\t\t\tj += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tif ( isCollection( value ) ) {\n\t\t// Detect whether we've been provided an array of complex numbers...\n\t\tN = value.length;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tif ( !isComplexLike( value[ i ] ) ) {\n\t\t\t\tflg = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t// If an array does not contain only complex numbers, then we assume interleaved real and imaginary components...\n\t\tif ( flg ) {\n\t\t\tif ( !isEven( N ) ) {\n\t\t\t\tthrow new RangeError( format( 'invalid argument. Array-like object arguments must have a length which is a multiple of two. Length: `%u`.', N ) );\n\t\t\t}\n\t\t\tif ( idx+(N/2) > this._length ) {\n\t\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t\t}\n\t\t\tsbuf = value;\n\n\t\t\t// Check for overlapping memory...\n\t\t\tj = buf.byteOffset + (idx*BYTES_PER_ELEMENT);\n\t\t\tif (\n\t\t\t\tsbuf.buffer === buf.buffer &&\n\t\t\t\t(\n\t\t\t\t\tsbuf.byteOffset < j &&\n\t\t\t\t\tsbuf.byteOffset+sbuf.byteLength > j\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\t// We need to copy source values...\n\t\t\t\ttmp = new Float64Array( N );\n\t\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\t\ttmp[ i ] = sbuf[ i ];\n\t\t\t\t}\n\t\t\t\tsbuf = tmp;\n\t\t\t}\n\t\t\tidx *= 2;\n\t\t\tN /= 2;\n\t\t\tj = 0;\n\t\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\t\tbuf[ idx ] = sbuf[ j ];\n\t\t\t\tbuf[ idx+1 ] = sbuf[ j+1 ];\n\t\t\t\tidx += 2; // stride\n\t\t\t\tj += 2; // stride\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t\t// If an array contains only complex numbers, then we need to extract real and imaginary components...\n\t\tif ( idx+N > this._length ) {\n\t\t\tthrow new RangeError( 'invalid arguments. Target array lacks sufficient storage to accommodate source values.' );\n\t\t}\n\t\tidx *= 2;\n\t\tfor ( i = 0; i < N; i++ ) {\n\t\t\tv = value[ i ];\n\t\t\tbuf[ idx ] = real( v );\n\t\t\tbuf[ idx+1 ] = imag( v );\n\t\t\tidx += 2; // stride\n\t\t}\n\t\treturn;\n\t}\n\tthrow new TypeError( format( 'invalid argument. First argument must be either a complex number, an array-like object, or a complex number array. Value: `%s`.', value ) );\n\n\t/* eslint-enable no-underscore-dangle */\n});\n\n/**\n* Copies a portion of a typed array to a new typed array.\n*\n* @name slice\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} [start=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex128Array} complex number array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var out = arr.slice();\n* // returns <Complex128Array>\n*\n* var len = out.length;\n* // returns 5\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns -1.0\n*\n* z = out.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 5.0\n*\n* im = imag( z );\n* // returns -5.0\n*\n* out = arr.slice( 1, -2 );\n* // returns <Complex128Array>\n*\n* len = out.length;\n* // returns 2\n*\n* z = out.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns -2.0\n*\n* z = out.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 3.0\n*\n* im = imag( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex128Array.prototype, 'slice', function slice( start, end ) {\n\tvar outlen;\n\tvar outbuf;\n\tvar out;\n\tvar idx;\n\tvar buf;\n\tvar len;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tstart = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( start ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', start ) );\n\t\t}\n\t\tif ( start < 0 ) {\n\t\t\tstart += len;\n\t\t\tif ( start < 0 ) {\n\t\t\t\tstart = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( start < end ) {\n\t\toutlen = end - start;\n\t} else {\n\t\toutlen = 0;\n\t}\n\tout = new this.constructor( outlen );\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < outlen; i++ ) {\n\t\tidx = 2*(i+start);\n\t\toutbuf[ 2*i ] = buf[ idx ];\n\t\toutbuf[ (2*i)+1 ] = buf[ idx+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Tests whether at least one element in an array passes a test implemented by a predicate function.\n*\n* @name some\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {Function} predicate - test function\n* @param {*} [thisArg] - predicate function execution context\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be a function\n* @returns {boolean} boolean indicating whether at least one element passes a test\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* function predicate( v ) {\n* return ( real( v ) === imag( v ) );\n* }\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n*\n* var bool = arr.some( predicate );\n* // returns true\n*/\nsetReadOnly( Complex128Array.prototype, 'some', function some( predicate, thisArg ) {\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isFunction( predicate ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be a function. Value: `%s`.', predicate ) );\n\t}\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tif ( predicate.call( thisArg, getComplex128( buf, i ), i, this ) ) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n});\n\n/**\n* Creates a new typed array view over the same underlying `ArrayBuffer` and with the same underlying data type as the host array.\n*\n* @name subarray\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} [begin=0] - starting index (inclusive)\n* @param {integer} [end] - ending index (exclusive)\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {TypeError} second argument must be an integer\n* @returns {Complex64Array} subarray\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 5 );\n*\n* arr.set( [ 1.0, -1.0 ], 0 );\n* arr.set( [ 2.0, -2.0 ], 1 );\n* arr.set( [ 3.0, -3.0 ], 2 );\n* arr.set( [ 4.0, -4.0 ], 3 );\n* arr.set( [ 5.0, -5.0 ], 4 );\n*\n* var subarr = arr.subarray();\n* // returns <Complex128Array>\n*\n* var len = subarr.length;\n* // returns 5\n*\n* var z = subarr.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 1.0\n*\n* var im = imag( z );\n* // returns -1.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 5.0\n*\n* im = imag( z );\n* // returns -5.0\n*\n* subarr = arr.subarray( 1, -2 );\n* // returns <Complex128Array>\n*\n* len = subarr.length;\n* // returns 2\n*\n* z = subarr.get( 0 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns -2.0\n*\n* z = subarr.get( len-1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 3.0\n*\n* im = imag( z );\n* // returns -3.0\n*/\nsetReadOnly( Complex128Array.prototype, 'subarray', function subarray( begin, end ) {\n\tvar offset;\n\tvar buf;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tbuf = this._buffer;\n\tlen = this._length;\n\tif ( arguments.length === 0 ) {\n\t\tbegin = 0;\n\t\tend = len;\n\t} else {\n\t\tif ( !isInteger( begin ) ) {\n\t\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', begin ) );\n\t\t}\n\t\tif ( begin < 0 ) {\n\t\t\tbegin += len;\n\t\t\tif ( begin < 0 ) {\n\t\t\t\tbegin = 0;\n\t\t\t}\n\t\t}\n\t\tif ( arguments.length === 1 ) {\n\t\t\tend = len;\n\t\t} else {\n\t\t\tif ( !isInteger( end ) ) {\n\t\t\t\tthrow new TypeError( format( 'invalid argument. Second argument must be an integer. Value: `%s`.', end ) );\n\t\t\t}\n\t\t\tif ( end < 0 ) {\n\t\t\t\tend += len;\n\t\t\t\tif ( end < 0 ) {\n\t\t\t\t\tend = 0;\n\t\t\t\t}\n\t\t\t} else if ( end > len ) {\n\t\t\t\tend = len;\n\t\t\t}\n\t\t}\n\t}\n\tif ( begin >= len ) {\n\t\tlen = 0;\n\t\toffset = buf.byteLength;\n\t} else if ( begin >= end ) {\n\t\tlen = 0;\n\t\toffset = buf.byteOffset + ( begin*BYTES_PER_ELEMENT );\n\t} else {\n\t\tlen = end - begin;\n\t\toffset = buf.byteOffset + ( begin*BYTES_PER_ELEMENT );\n\t}\n\treturn new this.constructor( buf.buffer, offset, ( len < 0 ) ? 0 : len );\n});\n\n/**\n* Returns a new typed array containing the elements in reversed order.\n*\n* @name toReversed\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {Complex128Array} reversed array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.toReversed();\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 3.0\n*\n* var im = imag( z );\n* // returns 3.0\n*\n* z = out.get( 1 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 2.0\n*\n* im = imag( z );\n* // returns 2.0\n*\n* z = out.get( 2 );\n* // returns <Complex128>\n*\n* re = real( z );\n* // returns 1.0\n*\n* im = imag( z );\n* // returns 1.0\n*/\nsetReadOnly( Complex128Array.prototype, 'toReversed', function toReversed() {\n\tvar outbuf;\n\tvar out;\n\tvar len;\n\tvar buf;\n\tvar i;\n\tvar j;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tlen = this._length;\n\tout = new this.constructor( len );\n\tbuf = this._buffer;\n\toutbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tfor ( i = 0; i < len; i++ ) {\n\t\tj = len - i - 1;\n\t\toutbuf[ (2*i) ] = buf[ (2*j) ];\n\t\toutbuf[ (2*i)+1 ] = buf[ (2*j)+1 ];\n\t}\n\treturn out;\n});\n\n/**\n* Serializes an array as a string.\n*\n* @name toString\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @throws {TypeError} `this` must be a complex number array\n* @returns {string} string representation\n*\n* @example\n* var arr = new Complex128Array( 2 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n*\n* var str = arr.toString();\n* // returns '1 + 1i,2 + 2i'\n*/\nsetReadOnly( Complex128Array.prototype, 'toString', function toString() {\n\tvar out;\n\tvar buf;\n\tvar i;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tout = [];\n\tbuf = this._buffer;\n\tfor ( i = 0; i < this._length; i++ ) {\n\t\tout.push( getComplex128( buf, i ).toString() );\n\t}\n\treturn out.join( ',' );\n});\n\n/**\n* Returns a new typed array with the element at a provided index replaced with a provided value.\n*\n* @name with\n* @memberof Complex128Array.prototype\n* @type {Function}\n* @param {integer} index - element index\n* @param {ComplexLike} value - new value\n* @throws {TypeError} `this` must be a complex number array\n* @throws {TypeError} first argument must be an integer\n* @throws {RangeError} index argument is out-of-bounds\n* @throws {TypeError} second argument must be a complex number\n* @returns {Complex128Array} new typed array\n*\n* @example\n* import real from '@stdlib/complex-real';\n* import imag from '@stdlib/complex-imag';\n* import Complex128 from '@stdlib/complex-float64';\n*\n* var arr = new Complex128Array( 3 );\n*\n* arr.set( [ 1.0, 1.0 ], 0 );\n* arr.set( [ 2.0, 2.0 ], 1 );\n* arr.set( [ 3.0, 3.0 ], 2 );\n*\n* var out = arr.with( 0, new Complex128( 4.0, 4.0 ) );\n* // returns <Complex128Array>\n*\n* var z = out.get( 0 );\n* // returns <Complex128>\n*\n* var re = real( z );\n* // returns 4.0\n*\n* var im = imag( z );\n* // returns 4.0\n*/\nsetReadOnly( Complex128Array.prototype, 'with', function copyWith( index, value ) {\n\tvar buf;\n\tvar out;\n\tvar len;\n\tif ( !isComplexArray( this ) ) {\n\t\tthrow new TypeError( 'invalid invocation. `this` is not a complex number array.' );\n\t}\n\tif ( !isInteger( index ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. First argument must be an integer. Value: `%s`.', index ) );\n\t}\n\tlen = this._length;\n\tif ( index < 0 ) {\n\t\tindex += len;\n\t}\n\tif ( index < 0 || index >= len ) {\n\t\tthrow new RangeError( format( 'invalid argument. Index argument is out-of-bounds. Value: `%s`.', index ) );\n\t}\n\tif ( !isComplexLike( value ) ) {\n\t\tthrow new TypeError( format( 'invalid argument. Second argument must be a complex number. Value: `%s`.', value ) );\n\t}\n\tout = new this.constructor( this._buffer );\n\tbuf = out._buffer; // eslint-disable-line no-underscore-dangle\n\tbuf[ 2*index ] = real( value );\n\tbuf[ (2*index)+1 ] = imag( value );\n\treturn out;\n});\n\n\n// EXPORTS //\n\nexport default Complex128Array;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\n\n\n// MAIN //\n\n/**\n* Returns a strided array of real and imaginary components.\n*\n* @private\n* @param {Float64Array} buf - output array\n* @param {Array} arr - array containing complex numbers\n* @returns {(Float64Array|null)} output array or null\n*/\nfunction fromArray( buf, arr ) {\n\tvar len;\n\tvar v;\n\tvar i;\n\tvar j;\n\n\tlen = arr.length;\n\tj = 0;\n\tfor ( i = 0; i < len; i++ ) {\n\t\tv = arr[ i ];\n\t\tif ( !isComplexLike( v ) ) {\n\t\t\treturn null;\n\t\t}\n\t\tbuf[ j ] = real( v );\n\t\tbuf[ j+1 ] = imag( v );\n\t\tj += 2; // stride\n\t}\n\treturn buf;\n}\n\n\n// EXPORTS //\n\nexport default fromArray;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isArrayLikeObject from '@stdlib/assert-is-array-like-object';\nimport isComplexLike from '@stdlib/assert-is-complex-like';\nimport format from '@stdlib/string-format';\nimport real from '@stdlib/complex-real';\nimport imag from '@stdlib/complex-imag';\n\n\n// MAIN //\n\n/**\n* Returns an array of iterated values.\n*\n* @private\n* @param {Object} it - iterator\n* @param {Function} clbk - callback to invoke for each iterated value\n* @param {*} thisArg - invocation context\n* @returns {(Array|TypeError)} array or an error\n*/\nfunction fromIteratorMap( it, clbk, thisArg ) {\n\tvar out;\n\tvar v;\n\tvar z;\n\tvar i;\n\n\tout = [];\n\ti = -1;\n\twhile ( true ) {\n\t\tv = it.next();\n\t\tif ( v.done ) {\n\t\t\tbreak;\n\t\t}\n\t\ti += 1;\n\t\tz = clbk.call( thisArg, v.value, i );\n\t\tif ( isArrayLikeObject( z ) && z.length >= 2 ) {\n\t\t\tout.push( z[ 0 ], z[ 1 ] );\n\t\t} else if ( isComplexLike( z ) ) {\n\t\t\tout.push( real( z ), imag( z ) );\n\t\t} else {\n\t\t\treturn new TypeError( format( 'invalid argument. Callback must return either a two-element array containing real and imaginary components or a complex number. Value: `%s`.', z ) );\n\t\t}\n\t}\n\treturn out;\n}\n\n\n// EXPORTS //\n\nexport default fromIteratorMap;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport Float64Array from '@stdlib/array-float64';\nimport Float32Array from '@stdlib/array-float32';\nimport Uint32Array from '@stdlib/array-uint32';\nimport Int32Array from '@stdlib/array-int32';\nimport Uint16Array from '@stdlib/array-uint16';\nimport Int16Array from '@stdlib/array-int16';\nimport Uint8Array from '@stdlib/array-uint8';\nimport Uint8ClampedArray from '@stdlib/array-uint8c';\nimport Int8Array from '@stdlib/array-int8';\nimport Complex64Array from '@stdlib/array-complex64';\nimport Complex128Array from '@stdlib/array-complex128';\n\n\n// MAIN //\n\n// Note: order should match `dtypes` order\nvar CTORS = [\n\tFloat64Array,\n\tFloat32Array,\n\tInt32Array,\n\tUint32Array,\n\tInt16Array,\n\tUint16Array,\n\tInt8Array,\n\tUint8Array,\n\tUint8ClampedArray,\n\tComplex64Array,\n\tComplex128Array\n];\n\n\n// EXPORTS //\n\nexport default CTORS;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n// Note: order should match `ctors` order\nvar DTYPES = [\n\t'float64',\n\t'float32',\n\t'int32',\n\t'uint32',\n\t'int16',\n\t'uint16',\n\t'int8',\n\t'uint8',\n\t'uint8c',\n\t'complex64',\n\t'complex128'\n];\n\n\n// EXPORTS //\n\nexport default DTYPES;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isBuffer from '@stdlib/assert-is-buffer';\nimport isArray from '@stdlib/assert-is-array';\nimport constructorName from '@stdlib/utils-constructor-name';\nimport ctor2dtype from './ctor2dtype.js';\nimport CTORS from './ctors.js';\nimport DTYPES from './dtypes.js';\n\n\n// VARIABLES //\n\nvar NTYPES = DTYPES.length;\n\n\n// MAIN //\n\n/**\n* Returns the data type of an array.\n*\n* @param {*} value - input value\n* @returns {(string|null)} data type\n*\n* @example\n* var dt = dtype( [ 1, 2, 3 ] );\n* // returns 'generic'\n*\n* var dt = dtype( 'beep' );\n* // returns null\n*/\nfunction dtype( value ) {\n\tvar i;\n\tif ( isArray( value ) ) {\n\t\treturn 'generic';\n\t}\n\tif ( isBuffer( value ) ) {\n\t\treturn null;\n\t}\n\tfor ( i = 0; i < NTYPES; i++ ) {\n\t\tif ( value instanceof CTORS[ i ] ) {\n\t\t\treturn DTYPES[ i ];\n\t\t}\n\t}\n\t// If the above failed, fall back to a more robust (and significantly slower) means for resolving underlying data types:\n\treturn ctor2dtype[ constructorName( value ) ] || null;\n}\n\n\n// EXPORTS //\n\nexport default dtype;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2023 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nimport isAccessorArray from '@stdlib/array-base-assert-is-accessor-array';\nimport accessorGetter from '@stdlib/array-base-accessor-getter';\nimport getter from '@stdlib/array-base-getter';\nimport dtype from '@stdlib/array-dtype';\n\n\n// MAIN //\n\n/**\n* Returns an accessor function for retrieving an element from an array-like object.\n*\n* @param {Collection} x - input array\n* @returns {Function} accessor\n*\n* @example\n* var arr = [ 1, 2, 3, 4 ];\n*\n* var get = resolveGetter( arr );\n* var v = get( arr, 2 );\n* // returns 3\n*/\nfunction resolveGetter( x ) {\n\tvar dt = dtype( x );\n\tif ( isAccessorArray( x ) ) {\n\t\treturn accessorGetter( dt );\n\t}\n\treturn getter( dt );\n}\n\n\n// EXPORTS //\n\nexport default resolveGetter;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2023 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\nimport format from '@stdlib/error-tools-fmtprodmsg';\n\n// MODULES //\n\nimport isArray from '@stdlib/assert-is-array';\n\nimport resolveGetter from '@stdlib/array-base-resolve-getter';\n\n// MAIN //\n\n/**\n* Groups element entries as arrays associated with distinct keys.\n*\n* @param {Collection} x - input array\n* @param {Collection} groups - array defining which group an element in the input array belongs to\n* @throws {RangeError} must provide arrays having the same length\n* @returns {Object} group results\n*\n* @example\n* var x = [ 'beep', 'boop', 'foo', 'bar' ];\n* var groups = [ 'b', 'b', 'f', 'b' ];\n*\n* var out = groupEntries( x, groups );\n* // returns { 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], 'f': [ [ 2, 'foo' ] ] }\n*/\nfunction groupEntries( x, groups ) {\n\tvar xget;\n\tvar gget;\n\tvar len;\n\tvar out;\n\tvar g;\n\tvar o;\n\tvar v;\n\tvar i;\n\n\t// Get the number of elements to group:\n\tlen = x.length;\n\tif ( groups.length !== len ) {\n\t\tthrow new RangeError( format('1nHFI') );\n\t}\n\t// Resolve accessors for retrieving array elements:\n\txget = resolveGetter( x );\n\tgget = resolveGetter( groups );\n\n\t// Loop over the elements and assign each to a group...\n\tout = {};\n\tfor ( i = 0; i < len; i++ ) {\n\t\tv = xget( x, i );\n\t\tg = gget( groups, i ).toString();\n\t\to = out[ g ];\n\t\tif ( isArray( o ) ) {\n\t\t\to.push( [ i, v ] );\n\t\t} else {\n\t\t\tout[ g ] = [ [ i, v ] ];\n\t\t}\n\t}\n\treturn out;\n}\n\n// EXPORTS //\n\nexport default groupEntries;\n","/**\n* @license Apache-2.0\n*\n* Copyright (c) 2022 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MAIN //\n\n/**\n* Formats an error message for production.\n*\n* @param {string} code - error code\n* @param {*} ...args - error message arguments\n* @returns {string} formatted error message\n*\n* @example\n* var msg = fmtprodmsg( '3', 'wrong_type' );\n* // returns 'https://stdlib.io/e/3?&arg[]=wrong_type'\n*/\nfunction fmtprodmsg() {\n\tvar a = arguments;\n\tvar c = a[ 0 ];\n\tvar u = 'https://stdlib.io/e/'+c+'?';\n\tvar i;\n\tfor ( i = 1; i < a.length; i++ ) {\n\t\tu += '&arg[]=' + encodeURIComponent( a[ i ] );\n\t}\n\treturn u;\n}\n\n\n// EXPORTS //\n\nexport default fmtprodmsg;\n"],"names":["FLG","Symbol","hasToStringTagSupport","toStringTag","toStr","Object","prototype","toString","has","hasOwnProperty","hasOwnProp","value","property","call","Sym","toStrTag","nativeClass","hasToStringTag","v","isOwn","tag","out","err","main$c","Array","isArray","TYPE","GETTERS","complex128","arr","idx","get","complex64","default","getter","dtype","f","float64","float32","int32","int16","int8","uint32","uint16","uint8","uint8c","generic","main","defineProperty","isNumber","zeros","n","i","zeroPad","str","width","right","negative","pad","length","startsWithMinus","substr","lowercase","String","toLowerCase","uppercase","toUpperCase","formatInteger","token","base","specifier","arg","parseInt","isFinite","Error","precision","padRight","sign","alternate","charAt","abs","Math","replace","RE_EXP_POS_DIGITS","RE_EXP_NEG_DIGITS","RE_ONLY_DIGITS","RE_DIGITS_BEFORE_EXP","RE_TRAILING_PERIOD_ZERO","RE_PERIOD_ZERO_EXP","RE_ZERO_BEFORE_EXP","formatDouble","digits","parseFloat","toExponential","toFixed","toPrecision","spaces","fromCharCode","isnan","initialize","flags","mapping","formatInterpolate","tokens","hasPeriod","flag","num","pos","j","TypeError","padZeros","indexOf","arguments","maxWidth","substring","RE","parse","match","formatTokenize","content","prev","exec","slice","lastIndex","push","format","args","tokenize","interpolate","apply","objectProtoype","defineGetter","__defineGetter__","defineSetter","__defineSetter__","lookupGetter","__lookupGetter__","lookupSetter","__lookupSetter__","hasDefinePropertySupport","builtin","obj","prop","descriptor","hasValue","hasGet","hasSet","__proto__","set","defineProperty$1","setNonEnumerableReadOnly","configurable","enumerable","writable","isObjectLike","isBuffer","_isBuffer","constructor","reFunctionName","setReadOnly","predicate","len","arrayfun","RE_FUNCTION_NAME","constructorName","name","ctor","REGEXP","ctor2dtypes","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray","Complex64Array","Complex128Array","hasFloat64Array","Float64Array$1","bool","GlobalFloat64Array","NaN","hasFloat64ArraySupport","hasFloat32Array","FLOAT64_PINF","Number","POSITIVE_INFINITY","Float32Array$1","GlobalFloat32Array","PINF","hasFloat32ArraySupport","hasUint32Array","Uint32Array$1","GlobalUint32Array","UINT32_MAX","hasUint32ArraySupport","hasInt32Array","Int32Array$1","GlobalInt32Array","INT32_MAX","hasInt32ArraySupport","hasUint16Array","Uint16Array$1","GlobalUint16Array","UINT16_MAX","hasUint16ArraySupport","hasInt16Array","Int16Array$1","GlobalInt16Array","INT16_MAX","hasInt16ArraySupport","hasUint8Array","Uint8Array$1","GlobalUint8Array","UINT8_MAX","hasUint8ArraySupport","hasUint8ClampedArray","Uint8ClampedArray$1","GlobalUint8ClampedArray","hasUint8ClampedArraySupport","hasInt8Array","Int8Array$1","GlobalInt8Array","INT8_MAX","hasInt8ArraySupport","main$1","test","isPrimitive","isObject","FLOAT64_NINF","NEGATIVE_INFINITY","floor","isInteger","x","NINF","isInt","valueOf","isNonNegativeInteger","MAX_ARRAY_LENGTH","isArrayLikeObject","MAX_LENGTH","MAX_TYPED_ARRAY_LENGTH","isCollection","hasArrayBuffer","ArrayBuffer","isArrayBuffer","isString","isBoolean","Bool","Boolean","self","window","global","globalThis","root","codegen","Function","GlobalThis","Self","Win","Global","getGlobal","nodeList","document","childNodes","typedarray","ctorName","type","isFunction","typeOf","Complex128","real","imag","this","re","im","fround","FLOAT32_VIEW","float64ToFloat32$1","Complex64","float64ToFloat32","isComplexLike","isEven","BYTES_PER_ELEMENT","isComplex64Array","isComplex128Array","hasIteratorSymbolSupport","iterator","IteratorSymbol","setNonEnumerableReadOnlyAccessor","realf","z","imagf","reinterpret","offset","buffer","byteOffset","fromIterator","it","next","done","HAS_ITERATOR_SYMBOL","isComplexArray","_length","_buffer","isComplexArrayConstructor","getComplex64","buf","nargs","fromArray","RangeError","reinterpret64","reinterpret128","byteLength","ITERATOR_SYMBOL","src","thisArg","clbk","tmp","flg","accessorGetter","fromIteratorMap","target","start","copyWithin","iter","entries","end","fcn","searchElement","fromIndex","separator","sep","join","outbuf","reducer","initialValue","acc","N","sbuf","outlen","begin","index","getComplex128","CTORS","DTYPES","NTYPES","resolveGetter","dt","ctor2dtype","groups","xget","gget","g","o","a","u","encodeURIComponent"],"mappings":";6OA2BA,IAAIA,ECMgB,mBAAXC,QACoB,iBAApBA,OA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F,EAAQ7S,GAAI7C,YAEjBkB,EAAS4U,GACbA,EAAEzO,KAAM,CAAExE,EAAGlC,IAEbG,EAAK+U,GAAM,CAAE,CAAEhT,EAAGlC,IAGpB,OAAOG,CACR","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,195]} \ No newline at end of file diff --git a/lib/index.js b/lib/index.js deleted file mode 100644 index a858e1d..0000000 --- a/lib/index.js +++ /dev/null @@ -1,43 +0,0 @@ -/** -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -'use strict'; - -/** -* Group element entries as arrays associated with distinct keys. -* -* @module @stdlib/array-base-group-entries -* -* @example -* var groupEntries = require( '@stdlib/array-base-group-entries' ); -* -* var x = [ 'beep', 'boop', 'foo', 'bar' ]; -* var groups = [ 'b', 'b', 'f', 'b' ]; -* -* var out = groupEntries( x, groups ); -* // returns { 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], 'f': [ [ 2, 'foo' ] ] } -*/ - -// MODULES // - -var main = require( './main.js' ); - - -// EXPORTS // - -module.exports = main; diff --git a/lib/main.js b/lib/main.js deleted file mode 100644 index 57c2c31..0000000 --- a/lib/main.js +++ /dev/null @@ -1,81 +0,0 @@ -/** -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -'use strict'; - -// MODULES // - -var isArray = require( '@stdlib/assert-is-array' ); -var resolveGetter = require( '@stdlib/array-base-resolve-getter' ); - - -// MAIN // - -/** -* Groups element entries as arrays associated with distinct keys. -* -* @param {Collection} x - input array -* @param {Collection} groups - array defining which group an element in the input array belongs to -* @throws {RangeError} must provide arrays having the same length -* @returns {Object} group results -* -* @example -* var x = [ 'beep', 'boop', 'foo', 'bar' ]; -* var groups = [ 'b', 'b', 'f', 'b' ]; -* -* var out = groupEntries( x, groups ); -* // returns { 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], 'f': [ [ 2, 'foo' ] ] } -*/ -function groupEntries( x, groups ) { - var xget; - var gget; - var len; - var out; - var g; - var o; - var v; - var i; - - // Get the number of elements to group: - len = x.length; - if ( groups.length !== len ) { - throw new RangeError( 'invalid argument. The first and second arguments must have the same length.' ); - } - // Resolve accessors for retrieving array elements: - xget = resolveGetter( x ); - gget = resolveGetter( groups ); - - // Loop over the elements and assign each to a group... - out = {}; - for ( i = 0; i < len; i++ ) { - v = xget( x, i ); - g = gget( groups, i ).toString(); - o = out[ g ]; - if ( isArray( o ) ) { - o.push( [ i, v ] ); - } else { - out[ g ] = [ [ i, v ] ]; - } - } - return out; -} - - -// EXPORTS // - -module.exports = groupEntries; diff --git a/package.json b/package.json index 822a57d..86784fb 100644 --- a/package.json +++ b/package.json @@ -3,31 +3,7 @@ "version": "0.2.2", "description": "Group element entries as arrays associated with distinct keys.", "license": "Apache-2.0", - "author": { - "name": "The Stdlib Authors", - "url": "https://github.com/stdlib-js/stdlib/graphs/contributors" - }, - "contributors": [ - { - "name": "The Stdlib Authors", - "url": "https://github.com/stdlib-js/stdlib/graphs/contributors" - } - ], - "main": "./lib", - "directories": { - "benchmark": "./benchmark", - "doc": "./docs", - "example": "./examples", - "lib": "./lib", - "test": "./test" - }, - "types": "./docs/types", - "scripts": { - "test": "make test", - "test-cov": "make test-cov", - "examples": "make examples", - "benchmark": "make benchmark" - }, + "main": "./index.js", "homepage": "https://stdlib.io", "repository": { "type": "git", @@ -36,39 +12,6 @@ "bugs": { "url": "https://github.com/stdlib-js/stdlib/issues" }, - "dependencies": { - "@stdlib/array-base-resolve-getter": "^0.2.2", - "@stdlib/assert-is-array": "^0.2.2", - "@stdlib/types": "^0.4.3" - }, - "devDependencies": { - "@stdlib/array-base-take-indexed": "^0.2.2", - "@stdlib/array-base-to-accessor-array": "^0.2.2", - "@stdlib/array-base-zero-to": "^0.2.1", - "@stdlib/array-float64": "^0.2.2", - "@stdlib/assert-is-plain-object": "^0.2.2", - "@stdlib/math-base-special-pow": "^0.3.0", - "@stdlib/random-array-discrete-uniform": "^0.2.1", - "tape": "git+https://github.com/kgryte/tape.git#fix/globby", - "istanbul": "^0.4.1", - "tap-min": "git+https://github.com/Planeshifter/tap-min.git", - "@stdlib/bench-harness": "^0.2.2" - }, - "engines": { - "node": ">=0.10.0", - "npm": ">2.7.0" - }, - "os": [ - "aix", - "darwin", - "freebsd", - "linux", - "macos", - "openbsd", - "sunos", - "win32", - "windows" - ], "keywords": [ "stdlib", "stdtypes", diff --git a/stats_browser.html b/stats_browser.html new file mode 100644 index 0000000..64778d8 --- /dev/null +++ b/stats_browser.html @@ -0,0 +1,4842 @@ + +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta http-equiv="X-UA-Compatible" content="ie=edge" /> + <title>Rollup Visualizer</title> + <style> +:root { + --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, + "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; + --background-color: #2b2d42; + --text-color: #edf2f4; +} + +html { + box-sizing: border-box; +} + +*, +*:before, +*:after { + box-sizing: inherit; +} + +html { + background-color: var(--background-color); + color: var(--text-color); + font-family: var(--font-family); +} + +body { + padding: 0; + margin: 0; +} + +html, +body { + height: 100%; + width: 100%; + overflow: hidden; +} + +body { + display: flex; + flex-direction: column; +} + +svg { + vertical-align: middle; + width: 100%; + height: 100%; + max-height: 100vh; +} + +main { + flex-grow: 1; + height: 100vh; + padding: 20px; +} + +.tooltip { + position: absolute; + z-index: 1070; + border: 2px solid; + border-radius: 5px; + padding: 5px; + white-space: nowrap; + font-size: 0.875rem; + background-color: var(--background-color); + color: var(--text-color); +} + +.tooltip-hidden { + visibility: hidden; + opacity: 0; +} + +.sidebar { + position: fixed; + top: 0; + left: 0; + right: 0; + display: flex; + flex-direction: row; + font-size: 0.7rem; + align-items: center; + margin: 0 50px; + height: 20px; +} + +.size-selectors { + display: flex; + flex-direction: row; + align-items: center; +} + +.size-selector { + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + margin-right: 1rem; +} +.size-selector input { + margin: 0 0.3rem 0 0; +} + +.filters { + flex: 1; + display: flex; + flex-direction: row; + align-items: center; +} + +.module-filters { + display: flex; + flex-grow: 1; +} + +.module-filter { + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + flex: 1; +} +.module-filter input { + flex: 1; + height: 1rem; + padding: 0.01rem; + font-size: 0.7rem; + margin-left: 0.3rem; +} +.module-filter + .module-filter { + margin-left: 0.5rem; +} + +.node { + cursor: pointer; +} + </style> +</head> +<body> + <main></main> + <script> + /*<!--*/ +var drawChart = (function (exports) { + 'use strict'; + + var n,l$1,u$2,i$1,o$1,r$1,f$2,e$1,c$1={},s$1=[],a$1=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,h$1=Array.isArray;function v$1(n,l){for(var u in l)n[u]=l[u];return n}function p$1(n){var l=n.parentNode;l&&l.removeChild(n);}function y$1(l,u,t){var i,o,r,f={};for(r in u)"key"==r?i=u[r]:"ref"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),"function"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return d$1(l,f,i,o,null)}function d$1(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u$2:r,__i:-1,__u:0};return null==r&&null!=l$1.vnode&&l$1.vnode(f),f}function g$1(n){return n.children}function b$1(n,l){this.props=n,this.context=l;}function m$1(n,l){if(null==l)return n.__?m$1(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return "function"==typeof n.type?m$1(n):null}function k$1(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return k$1(n)}}function w$1(n){(!n.__d&&(n.__d=!0)&&i$1.push(n)&&!x.__r++||o$1!==l$1.debounceRendering)&&((o$1=l$1.debounceRendering)||r$1)(x);}function x(){var n,u,t,o,r,e,c,s,a;for(i$1.sort(f$2);n=i$1.shift();)n.__d&&(u=i$1.length,o=void 0,e=(r=(t=n).__v).__e,s=[],a=[],(c=t.__P)&&((o=v$1({},r)).__v=r.__v+1,l$1.vnode&&l$1.vnode(o),L(c,o,r,t.__n,void 0!==c.ownerSVGElement,32&r.__u?[e]:null,s,null==e?m$1(r):e,!!(32&r.__u),a),o.__.__k[o.__i]=o,M(s,o,a),o.__e!=e&&k$1(o)),i$1.length>u&&i$1.sort(f$2));x.__r=0;}function C(n,l,u,t,i,o,r,f,e,a,h){var v,p,y,d,_,g=t&&t.__k||s$1,b=l.length;for(u.__d=e,P(u,l,g),e=u.__d,v=0;v<b;v++)null!=(y=u.__k[v])&&"boolean"!=typeof y&&"function"!=typeof y&&(p=-1===y.__i?c$1:g[y.__i]||c$1,y.__i=v,L(n,y,p,i,o,r,f,e,a,h),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&z$1(p.ref,null,y),h.push(y.ref,y.__c||d,y)),null==_&&null!=d&&(_=d),65536&y.__u||p.__k===y.__k?e=S(y,e,n):"function"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=_;}function P(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)null!=(i=n.__k[t]=null==(i=l[t])||"boolean"==typeof i||"function"==typeof i?null:"string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?d$1(null,i,null,null,i):h$1(i)?d$1(g$1,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?d$1(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)?(i.__=n,i.__b=n.__b+1,f=H(i,u,r=t+a,s),i.__i=f,o=null,-1!==f&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,"function"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f===r+1?a++:f>r?s>e-r?a+=f-r:a--:a=f<r&&f==r-1?f-r:0,f!==t+a&&(i.__u|=65536))):(o=u[t])&&null==o.key&&o.__e&&(o.__e==n.__d&&(n.__d=m$1(o)),N(o,o,!1),u[t]=null,s--);if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=m$1(o)),N(o,o));}function S(n,l,u){var t,i;if("function"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=S(t[i],l,u));return l}return n.__e!=l&&(u.insertBefore(n.__e,l||null),l=n.__e),l&&l.nextSibling}function H(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type)return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--;}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++;}}return -1}function I(n,l,u){"-"===l[0]?n.setProperty(l,null==u?"":u):n[l]=null==u?"":"number"!=typeof u||a$1.test(l)?u:u+"px";}function T$1(n,l,u,t,i){var o;n:if("style"===l)if("string"==typeof u)n.style.cssText=u;else {if("string"==typeof t&&(n.style.cssText=t=""),t)for(l in t)u&&l in u||I(n.style,l,"");if(u)for(l in u)t&&u[l]===t[l]||I(n.style,l,u[l]);}else if("o"===l[0]&&"n"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/,"$1")),l=l.toLowerCase()in n?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=Date.now(),n.addEventListener(l,o?D:A,o)):n.removeEventListener(l,o?D:A,o);else {if(i)l=l.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!==l&&"height"!==l&&"href"!==l&&"list"!==l&&"form"!==l&&"tabIndex"!==l&&"download"!==l&&"rowSpan"!==l&&"colSpan"!==l&&"role"!==l&&l in n)try{n[l]=null==u?"":u;break n}catch(n){}"function"==typeof u||(null==u||!1===u&&"-"!==l[4]?n.removeAttribute(l):n.setAttribute(l,u));}}function A(n){var u=this.l[n.type+!1];if(n.t){if(n.t<=u.u)return}else n.t=Date.now();return u(l$1.event?l$1.event(n):n)}function D(n){return this.l[n.type+!0](l$1.event?l$1.event(n):n)}function L(n,u,t,i,o,r,f,e,c,s){var a,p,y,d,_,m,k,w,x,P,S,$,H,I,T,A=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l$1.__b)&&a(u);n:if("function"==typeof A)try{if(w=u.props,x=(a=A.contextType)&&i[a.__c],P=a?x?x.props.value:a.__:i,t.__c?k=(p=u.__c=t.__c).__=p.__E:("prototype"in A&&A.prototype.render?u.__c=p=new A(w,P):(u.__c=p=new b$1(w,P),p.constructor=A,p.render=O),x&&x.sub(p),p.props=w,p.state||(p.state={}),p.context=P,p.__n=i,y=p.__d=!0,p.__h=[],p._sb=[]),null==p.__s&&(p.__s=p.state),null!=A.getDerivedStateFromProps&&(p.__s==p.state&&(p.__s=v$1({},p.__s)),v$1(p.__s,A.getDerivedStateFromProps(w,p.__s))),d=p.props,_=p.state,p.__v=u,y)null==A.getDerivedStateFromProps&&null!=p.componentWillMount&&p.componentWillMount(),null!=p.componentDidMount&&p.__h.push(p.componentDidMount);else {if(null==A.getDerivedStateFromProps&&w!==d&&null!=p.componentWillReceiveProps&&p.componentWillReceiveProps(w,P),!p.__e&&(null!=p.shouldComponentUpdate&&!1===p.shouldComponentUpdate(w,p.__s,P)||u.__v===t.__v)){for(u.__v!==t.__v&&(p.props=w,p.state=p.__s,p.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.forEach(function(n){n&&(n.__=u);}),S=0;S<p._sb.length;S++)p.__h.push(p._sb[S]);p._sb=[],p.__h.length&&f.push(p);break n}null!=p.componentWillUpdate&&p.componentWillUpdate(w,p.__s,P),null!=p.componentDidUpdate&&p.__h.push(function(){p.componentDidUpdate(d,_,m);});}if(p.context=P,p.props=w,p.__P=n,p.__e=!1,$=l$1.__r,H=0,"prototype"in A&&A.prototype.render){for(p.state=p.__s,p.__d=!1,$&&$(u),a=p.render(p.props,p.state,p.context),I=0;I<p._sb.length;I++)p.__h.push(p._sb[I]);p._sb=[];}else do{p.__d=!1,$&&$(u),a=p.render(p.props,p.state,p.context),p.state=p.__s;}while(p.__d&&++H<25);p.state=p.__s,null!=p.getChildContext&&(i=v$1(v$1({},i),p.getChildContext())),y||null==p.getSnapshotBeforeUpdate||(m=p.getSnapshotBeforeUpdate(d,_)),C(n,h$1(T=null!=a&&a.type===g$1&&null==a.key?a.props.children:a)?T:[T],u,t,i,o,r,f,e,c,s),p.base=u.__e,u.__u&=-161,p.__h.length&&f.push(p),k&&(p.__E=p.__=null);}catch(n){u.__v=null,c||null!=r?(u.__e=e,u.__u|=c?160:32,r[r.indexOf(e)]=null):(u.__e=t.__e,u.__k=t.__k),l$1.__e(n,u,t);}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=j$1(t.__e,u,t,i,o,r,f,c,s);(a=l$1.diffed)&&a(u);}function M(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)z$1(t[i],t[++i],t[++i]);l$1.__c&&l$1.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u);});}catch(n){l$1.__e(n,u.__v);}});}function j$1(l,u,t,i,o,r,f,e,s){var a,v,y,d,_,g,b,k=t.props,w=u.props,x=u.type;if("svg"===x&&(o=!0),null!=r)for(a=0;a<r.length;a++)if((_=r[a])&&"setAttribute"in _==!!x&&(x?_.localName===x:3===_.nodeType)){l=_,r[a]=null;break}if(null==l){if(null===x)return document.createTextNode(w);l=o?document.createElementNS("http://www.w3.org/2000/svg",x):document.createElement(x,w.is&&w),r=null,e=!1;}if(null===x)k===w||e&&l.data===w||(l.data=w);else {if(r=r&&n.call(l.childNodes),k=t.props||c$1,!e&&null!=r)for(k={},a=0;a<l.attributes.length;a++)k[(_=l.attributes[a]).name]=_.value;for(a in k)_=k[a],"children"==a||("dangerouslySetInnerHTML"==a?y=_:"key"===a||a in w||T$1(l,a,null,_,o));for(a in w)_=w[a],"children"==a?d=_:"dangerouslySetInnerHTML"==a?v=_:"value"==a?g=_:"checked"==a?b=_:"key"===a||e&&"function"!=typeof _||k[a]===_||T$1(l,a,_,k[a],o);if(v)e||y&&(v.__html===y.__html||v.__html===l.innerHTML)||(l.innerHTML=v.__html),u.__k=[];else if(y&&(l.innerHTML=""),C(l,h$1(d)?d:[d],u,t,i,o&&"foreignObject"!==x,r,f,r?r[0]:t.__k&&m$1(t,0),e,s),null!=r)for(a=r.length;a--;)null!=r[a]&&p$1(r[a]);e||(a="value",void 0!==g&&(g!==l[a]||"progress"===x&&!g||"option"===x&&g!==k[a])&&T$1(l,a,g,k[a],!1),a="checked",void 0!==b&&b!==l[a]&&T$1(l,a,b,k[a],!1));}return l}function z$1(n,u,t){try{"function"==typeof n?n(u):n.current=u;}catch(n){l$1.__e(n,t);}}function N(n,u,t){var i,o;if(l$1.unmount&&l$1.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||z$1(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount();}catch(n){l$1.__e(n,u);}i.base=i.__P=null,n.__c=void 0;}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&N(i[o],u,t||"function"!=typeof n.type);t||null==n.__e||p$1(n.__e),n.__=n.__e=n.__d=void 0;}function O(n,l,u){return this.constructor(n,u)}function q$1(u,t,i){var o,r,f,e;l$1.__&&l$1.__(u,t),r=(o="function"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],L(t,u=(!o&&i||t).__k=y$1(g$1,null,[u]),r||c$1,c$1,void 0!==t.ownerSVGElement,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),M(f,u,e);}function F$1(n,l){var u={__c:l="__cC"+e$1++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,w$1(n);});},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u.splice(u.indexOf(n),1),l&&l.call(n);};}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=s$1.slice,l$1={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l;}throw n}},u$2=0,b$1.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=v$1({},this.state),"function"==typeof n&&(n=n(v$1({},u),this.props)),n&&v$1(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),w$1(this));},b$1.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),w$1(this));},b$1.prototype.render=g$1,i$1=[],r$1="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f$2=function(n,l){return n.__v.__b-l.__v.__b},x.__r=0,e$1=0; + + var f$1=0;function u$1(e,t,n,o,i,u){var a,c,p={};for(c in t)"ref"==c?a=t[c]:p[c]=t[c];var l={type:e,props:p,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f$1,__i:-1,__u:0,__source:i,__self:u};if("function"==typeof e&&(a=e.defaultProps))for(c in a)void 0===p[c]&&(p[c]=a[c]);return l$1.vnode&&l$1.vnode(l),l} + + function count$1(node) { + var sum = 0, + children = node.children, + i = children && children.length; + if (!i) sum = 1; + else while (--i >= 0) sum += children[i].value; + node.value = sum; + } + + function node_count() { + return this.eachAfter(count$1); + } + + function node_each(callback, that) { + let index = -1; + for (const node of this) { + callback.call(that, node, ++index, this); + } + return this; + } + + function node_eachBefore(callback, that) { + var node = this, nodes = [node], children, i, index = -1; + while (node = nodes.pop()) { + callback.call(that, node, ++index, this); + if (children = node.children) { + for (i = children.length - 1; i >= 0; --i) { + nodes.push(children[i]); + } + } + } + return this; + } + + function node_eachAfter(callback, that) { + var node = this, nodes = [node], next = [], children, i, n, index = -1; + while (node = nodes.pop()) { + next.push(node); + if (children = node.children) { + for (i = 0, n = children.length; i < n; ++i) { + nodes.push(children[i]); + } + } + } + while (node = next.pop()) { + callback.call(that, node, ++index, this); + } + return this; + } + + function node_find(callback, that) { + let index = -1; + for (const node of this) { + if (callback.call(that, node, ++index, this)) { + return node; + } + } + } + + function node_sum(value) { + return this.eachAfter(function(node) { + var sum = +value(node.data) || 0, + children = node.children, + i = children && children.length; + while (--i >= 0) sum += children[i].value; + node.value = sum; + }); + } + + function node_sort(compare) { + return this.eachBefore(function(node) { + if (node.children) { + node.children.sort(compare); + } + }); + } + + function node_path(end) { + var start = this, + ancestor = leastCommonAncestor(start, end), + nodes = [start]; + while (start !== ancestor) { + start = start.parent; + nodes.push(start); + } + var k = nodes.length; + while (end !== ancestor) { + nodes.splice(k, 0, end); + end = end.parent; + } + return nodes; + } + + function leastCommonAncestor(a, b) { + if (a === b) return a; + var aNodes = a.ancestors(), + bNodes = b.ancestors(), + c = null; + a = aNodes.pop(); + b = bNodes.pop(); + while (a === b) { + c = a; + a = aNodes.pop(); + b = bNodes.pop(); + } + return c; + } + + function node_ancestors() { + var node = this, nodes = [node]; + while (node = node.parent) { + nodes.push(node); + } + return nodes; + } + + function node_descendants() { + return Array.from(this); + } + + function node_leaves() { + var leaves = []; + this.eachBefore(function(node) { + if (!node.children) { + leaves.push(node); + } + }); + return leaves; + } + + function node_links() { + var root = this, links = []; + root.each(function(node) { + if (node !== root) { // Don’t include the root’s parent, if any. + links.push({source: node.parent, target: node}); + } + }); + return links; + } + + function* node_iterator() { + var node = this, current, next = [node], children, i, n; + do { + current = next.reverse(), next = []; + while (node = current.pop()) { + yield node; + if (children = node.children) { + for (i = 0, n = children.length; i < n; ++i) { + next.push(children[i]); + } + } + } + } while (next.length); + } + + function hierarchy(data, children) { + if (data instanceof Map) { + data = [undefined, data]; + if (children === undefined) children = mapChildren; + } else if (children === undefined) { + children = objectChildren; + } + + var root = new Node$1(data), + node, + nodes = [root], + child, + childs, + i, + n; + + while (node = nodes.pop()) { + if ((childs = children(node.data)) && (n = (childs = Array.from(childs)).length)) { + node.children = childs; + for (i = n - 1; i >= 0; --i) { + nodes.push(child = childs[i] = new Node$1(childs[i])); + child.parent = node; + child.depth = node.depth + 1; + } + } + } + + return root.eachBefore(computeHeight); + } + + function node_copy() { + return hierarchy(this).eachBefore(copyData); + } + + function objectChildren(d) { + return d.children; + } + + function mapChildren(d) { + return Array.isArray(d) ? d[1] : null; + } + + function copyData(node) { + if (node.data.value !== undefined) node.value = node.data.value; + node.data = node.data.data; + } + + function computeHeight(node) { + var height = 0; + do node.height = height; + while ((node = node.parent) && (node.height < ++height)); + } + + function Node$1(data) { + this.data = data; + this.depth = + this.height = 0; + this.parent = null; + } + + Node$1.prototype = hierarchy.prototype = { + constructor: Node$1, + count: node_count, + each: node_each, + eachAfter: node_eachAfter, + eachBefore: node_eachBefore, + find: node_find, + sum: node_sum, + sort: node_sort, + path: node_path, + ancestors: node_ancestors, + descendants: node_descendants, + leaves: node_leaves, + links: node_links, + copy: node_copy, + [Symbol.iterator]: node_iterator + }; + + function required(f) { + if (typeof f !== "function") throw new Error; + return f; + } + + function constantZero() { + return 0; + } + + function constant$1(x) { + return function() { + return x; + }; + } + + function roundNode(node) { + node.x0 = Math.round(node.x0); + node.y0 = Math.round(node.y0); + node.x1 = Math.round(node.x1); + node.y1 = Math.round(node.y1); + } + + function treemapDice(parent, x0, y0, x1, y1) { + var nodes = parent.children, + node, + i = -1, + n = nodes.length, + k = parent.value && (x1 - x0) / parent.value; + + while (++i < n) { + node = nodes[i], node.y0 = y0, node.y1 = y1; + node.x0 = x0, node.x1 = x0 += node.value * k; + } + } + + function treemapSlice(parent, x0, y0, x1, y1) { + var nodes = parent.children, + node, + i = -1, + n = nodes.length, + k = parent.value && (y1 - y0) / parent.value; + + while (++i < n) { + node = nodes[i], node.x0 = x0, node.x1 = x1; + node.y0 = y0, node.y1 = y0 += node.value * k; + } + } + + var phi = (1 + Math.sqrt(5)) / 2; + + function squarifyRatio(ratio, parent, x0, y0, x1, y1) { + var rows = [], + nodes = parent.children, + row, + nodeValue, + i0 = 0, + i1 = 0, + n = nodes.length, + dx, dy, + value = parent.value, + sumValue, + minValue, + maxValue, + newRatio, + minRatio, + alpha, + beta; + + while (i0 < n) { + dx = x1 - x0, dy = y1 - y0; + + // Find the next non-empty node. + do sumValue = nodes[i1++].value; while (!sumValue && i1 < n); + minValue = maxValue = sumValue; + alpha = Math.max(dy / dx, dx / dy) / (value * ratio); + beta = sumValue * sumValue * alpha; + minRatio = Math.max(maxValue / beta, beta / minValue); + + // Keep adding nodes while the aspect ratio maintains or improves. + for (; i1 < n; ++i1) { + sumValue += nodeValue = nodes[i1].value; + if (nodeValue < minValue) minValue = nodeValue; + if (nodeValue > maxValue) maxValue = nodeValue; + beta = sumValue * sumValue * alpha; + newRatio = Math.max(maxValue / beta, beta / minValue); + if (newRatio > minRatio) { sumValue -= nodeValue; break; } + minRatio = newRatio; + } + + // Position and record the row orientation. + rows.push(row = {value: sumValue, dice: dx < dy, children: nodes.slice(i0, i1)}); + if (row.dice) treemapDice(row, x0, y0, x1, value ? y0 += dy * sumValue / value : y1); + else treemapSlice(row, x0, y0, value ? x0 += dx * sumValue / value : x1, y1); + value -= sumValue, i0 = i1; + } + + return rows; + } + + var squarify = (function custom(ratio) { + + function squarify(parent, x0, y0, x1, y1) { + squarifyRatio(ratio, parent, x0, y0, x1, y1); + } + + squarify.ratio = function(x) { + return custom((x = +x) > 1 ? x : 1); + }; + + return squarify; + })(phi); + + function treemap() { + var tile = squarify, + round = false, + dx = 1, + dy = 1, + paddingStack = [0], + paddingInner = constantZero, + paddingTop = constantZero, + paddingRight = constantZero, + paddingBottom = constantZero, + paddingLeft = constantZero; + + function treemap(root) { + root.x0 = + root.y0 = 0; + root.x1 = dx; + root.y1 = dy; + root.eachBefore(positionNode); + paddingStack = [0]; + if (round) root.eachBefore(roundNode); + return root; + } + + function positionNode(node) { + var p = paddingStack[node.depth], + x0 = node.x0 + p, + y0 = node.y0 + p, + x1 = node.x1 - p, + y1 = node.y1 - p; + if (x1 < x0) x0 = x1 = (x0 + x1) / 2; + if (y1 < y0) y0 = y1 = (y0 + y1) / 2; + node.x0 = x0; + node.y0 = y0; + node.x1 = x1; + node.y1 = y1; + if (node.children) { + p = paddingStack[node.depth + 1] = paddingInner(node) / 2; + x0 += paddingLeft(node) - p; + y0 += paddingTop(node) - p; + x1 -= paddingRight(node) - p; + y1 -= paddingBottom(node) - p; + if (x1 < x0) x0 = x1 = (x0 + x1) / 2; + if (y1 < y0) y0 = y1 = (y0 + y1) / 2; + tile(node, x0, y0, x1, y1); + } + } + + treemap.round = function(x) { + return arguments.length ? (round = !!x, treemap) : round; + }; + + treemap.size = function(x) { + return arguments.length ? (dx = +x[0], dy = +x[1], treemap) : [dx, dy]; + }; + + treemap.tile = function(x) { + return arguments.length ? (tile = required(x), treemap) : tile; + }; + + treemap.padding = function(x) { + return arguments.length ? treemap.paddingInner(x).paddingOuter(x) : treemap.paddingInner(); + }; + + treemap.paddingInner = function(x) { + return arguments.length ? (paddingInner = typeof x === "function" ? x : constant$1(+x), treemap) : paddingInner; + }; + + treemap.paddingOuter = function(x) { + return arguments.length ? treemap.paddingTop(x).paddingRight(x).paddingBottom(x).paddingLeft(x) : treemap.paddingTop(); + }; + + treemap.paddingTop = function(x) { + return arguments.length ? (paddingTop = typeof x === "function" ? x : constant$1(+x), treemap) : paddingTop; + }; + + treemap.paddingRight = function(x) { + return arguments.length ? (paddingRight = typeof x === "function" ? x : constant$1(+x), treemap) : paddingRight; + }; + + treemap.paddingBottom = function(x) { + return arguments.length ? (paddingBottom = typeof x === "function" ? x : constant$1(+x), treemap) : paddingBottom; + }; + + treemap.paddingLeft = function(x) { + return arguments.length ? (paddingLeft = typeof x === "function" ? x : constant$1(+x), treemap) : paddingLeft; + }; + + return treemap; + } + + var treemapResquarify = (function custom(ratio) { + + function resquarify(parent, x0, y0, x1, y1) { + if ((rows = parent._squarify) && (rows.ratio === ratio)) { + var rows, + row, + nodes, + i, + j = -1, + n, + m = rows.length, + value = parent.value; + + while (++j < m) { + row = rows[j], nodes = row.children; + for (i = row.value = 0, n = nodes.length; i < n; ++i) row.value += nodes[i].value; + if (row.dice) treemapDice(row, x0, y0, x1, value ? y0 += (y1 - y0) * row.value / value : y1); + else treemapSlice(row, x0, y0, value ? x0 += (x1 - x0) * row.value / value : x1, y1); + value -= row.value; + } + } else { + parent._squarify = rows = squarifyRatio(ratio, parent, x0, y0, x1, y1); + rows.ratio = ratio; + } + } + + resquarify.ratio = function(x) { + return custom((x = +x) > 1 ? x : 1); + }; + + return resquarify; + })(phi); + + const isModuleTree = (mod) => "children" in mod; + + let count = 0; + class Id { + constructor(id) { + this._id = id; + const url = new URL(window.location.href); + url.hash = id; + this._href = url.toString(); + } + get id() { + return this._id; + } + get href() { + return this._href; + } + toString() { + return `url(${this.href})`; + } + } + function generateUniqueId(name) { + count += 1; + const id = ["O", name, count].filter(Boolean).join("-"); + return new Id(id); + } + + const LABELS = { + renderedLength: "Rendered", + gzipLength: "Gzip", + brotliLength: "Brotli", + }; + const getAvailableSizeOptions = (options) => { + const availableSizeProperties = ["renderedLength"]; + if (options.gzip) { + availableSizeProperties.push("gzipLength"); + } + if (options.brotli) { + availableSizeProperties.push("brotliLength"); + } + return availableSizeProperties; + }; + + var t,r,u,i,o=0,f=[],c=[],e=l$1.__b,a=l$1.__r,v=l$1.diffed,l=l$1.__c,m=l$1.unmount;function d(t,u){l$1.__h&&l$1.__h(r,t,o||u),o=0;var i=r.__H||(r.__H={__:[],__h:[]});return t>=i.__.length&&i.__.push({__V:c}),i.__[t]}function h(n){return o=1,s(B,n)}function s(n,u,i){var o=d(t++,2);if(o.t=n,!o.__c&&(o.__=[i?i(u):B(void 0,u),function(n){var t=o.__N?o.__N[0]:o.__[0],r=o.t(t,n);t!==r&&(o.__N=[r,o.__[1]],o.__c.setState({}));}],o.__c=r,!r.u)){var f=function(n,t,r){if(!o.__c.__H)return !0;var u=o.__c.__H.__.filter(function(n){return n.__c});if(u.every(function(n){return !n.__N}))return !c||c.call(this,n,t,r);var i=!1;return u.forEach(function(n){if(n.__N){var t=n.__[0];n.__=n.__N,n.__N=void 0,t!==n.__[0]&&(i=!0);}}),!(!i&&o.__c.props===n)&&(!c||c.call(this,n,t,r))};r.u=!0;var c=r.shouldComponentUpdate,e=r.componentWillUpdate;r.componentWillUpdate=function(n,t,r){if(this.__e){var u=c;c=void 0,f(n,t,r),c=u;}e&&e.call(this,n,t,r);},r.shouldComponentUpdate=f;}return o.__N||o.__}function p(u,i){var o=d(t++,3);!l$1.__s&&z(o.__H,i)&&(o.__=u,o.i=i,r.__H.__h.push(o));}function y(u,i){var o=d(t++,4);!l$1.__s&&z(o.__H,i)&&(o.__=u,o.i=i,r.__h.push(o));}function _(n){return o=5,F(function(){return {current:n}},[])}function F(n,r){var u=d(t++,7);return z(u.__H,r)?(u.__V=n(),u.i=r,u.__h=n,u.__V):u.__}function T(n,t){return o=8,F(function(){return n},t)}function q(n){var u=r.context[n.__c],i=d(t++,9);return i.c=n,u?(null==i.__&&(i.__=!0,u.sub(r)),u.props.value):n.__}function b(){for(var t;t=f.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(k),t.__H.__h.forEach(w),t.__H.__h=[];}catch(r){t.__H.__h=[],l$1.__e(r,t.__v);}}l$1.__b=function(n){r=null,e&&e(n);},l$1.__r=function(n){a&&a(n),t=0;var i=(r=n.__c).__H;i&&(u===r?(i.__h=[],r.__h=[],i.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=c,n.__N=n.i=void 0;})):(i.__h.forEach(k),i.__h.forEach(w),i.__h=[],t=0)),u=r;},l$1.diffed=function(t){v&&v(t);var o=t.__c;o&&o.__H&&(o.__H.__h.length&&(1!==f.push(o)&&i===l$1.requestAnimationFrame||((i=l$1.requestAnimationFrame)||j)(b)),o.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==c&&(n.__=n.__V),n.i=void 0,n.__V=c;})),u=r=null;},l$1.__c=function(t,r){r.some(function(t){try{t.__h.forEach(k),t.__h=t.__h.filter(function(n){return !n.__||w(n)});}catch(u){r.some(function(n){n.__h&&(n.__h=[]);}),r=[],l$1.__e(u,t.__v);}}),l&&l(t,r);},l$1.unmount=function(t){m&&m(t);var r,u=t.__c;u&&u.__H&&(u.__H.__.forEach(function(n){try{k(n);}catch(n){r=n;}}),u.__H=void 0,r&&l$1.__e(r,u.__v));};var g="function"==typeof requestAnimationFrame;function j(n){var t,r=function(){clearTimeout(u),g&&cancelAnimationFrame(t),setTimeout(n);},u=setTimeout(r,100);g&&(t=requestAnimationFrame(r));}function k(n){var t=r,u=n.__c;"function"==typeof u&&(n.__c=void 0,u()),r=t;}function w(n){var t=r;n.__c=n.__(),r=t;}function z(n,t){return !n||n.length!==t.length||t.some(function(t,r){return t!==n[r]})}function B(n,t){return "function"==typeof t?t(n):t} + + const PLACEHOLDER = "*/**/file.js"; + const SideBar = ({ availableSizeProperties, sizeProperty, setSizeProperty, onExcludeChange, onIncludeChange, }) => { + const [includeValue, setIncludeValue] = h(""); + const [excludeValue, setExcludeValue] = h(""); + const handleSizePropertyChange = (sizeProp) => () => { + if (sizeProp !== sizeProperty) { + setSizeProperty(sizeProp); + } + }; + const handleIncludeChange = (event) => { + const value = event.currentTarget.value; + setIncludeValue(value); + onIncludeChange(value); + }; + const handleExcludeChange = (event) => { + const value = event.currentTarget.value; + setExcludeValue(value); + onExcludeChange(value); + }; + return (u$1("aside", { className: "sidebar", children: [u$1("div", { className: "size-selectors", children: availableSizeProperties.length > 1 && + availableSizeProperties.map((sizeProp) => { + const id = `selector-${sizeProp}`; + return (u$1("div", { className: "size-selector", children: [u$1("input", { type: "radio", id: id, checked: sizeProp === sizeProperty, onChange: handleSizePropertyChange(sizeProp) }), u$1("label", { htmlFor: id, children: LABELS[sizeProp] })] }, sizeProp)); + }) }), u$1("div", { className: "module-filters", children: [u$1("div", { className: "module-filter", children: [u$1("label", { htmlFor: "module-filter-exclude", children: "Exclude" }), u$1("input", { type: "text", id: "module-filter-exclude", value: excludeValue, onInput: handleExcludeChange, placeholder: PLACEHOLDER })] }), u$1("div", { className: "module-filter", children: [u$1("label", { htmlFor: "module-filter-include", children: "Include" }), u$1("input", { type: "text", id: "module-filter-include", value: includeValue, onInput: handleIncludeChange, placeholder: PLACEHOLDER })] })] })] })); + }; + + function getDefaultExportFromCjs (x) { + return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x; + } + + var utils$3 = {}; + + const WIN_SLASH = '\\\\/'; + const WIN_NO_SLASH = `[^${WIN_SLASH}]`; + + /** + * Posix glob regex + */ + + const DOT_LITERAL = '\\.'; + const PLUS_LITERAL = '\\+'; + const QMARK_LITERAL = '\\?'; + const SLASH_LITERAL = '\\/'; + const ONE_CHAR = '(?=.)'; + const QMARK = '[^/]'; + const END_ANCHOR = `(?:${SLASH_LITERAL}|$)`; + const START_ANCHOR = `(?:^|${SLASH_LITERAL})`; + const DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`; + const NO_DOT = `(?!${DOT_LITERAL})`; + const NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`; + const NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`; + const NO_DOTS_SLASH = `(?!${DOTS_SLASH})`; + const QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`; + const STAR = `${QMARK}*?`; + const SEP = '/'; + + const POSIX_CHARS = { + DOT_LITERAL, + PLUS_LITERAL, + QMARK_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + QMARK, + END_ANCHOR, + DOTS_SLASH, + NO_DOT, + NO_DOTS, + NO_DOT_SLASH, + NO_DOTS_SLASH, + QMARK_NO_DOT, + STAR, + START_ANCHOR, + SEP + }; + + /** + * Windows glob regex + */ + + const WINDOWS_CHARS = { + ...POSIX_CHARS, + + SLASH_LITERAL: `[${WIN_SLASH}]`, + QMARK: WIN_NO_SLASH, + STAR: `${WIN_NO_SLASH}*?`, + DOTS_SLASH: `${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$)`, + NO_DOT: `(?!${DOT_LITERAL})`, + NO_DOTS: `(?!(?:^|[${WIN_SLASH}])${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, + NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}(?:[${WIN_SLASH}]|$))`, + NO_DOTS_SLASH: `(?!${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, + QMARK_NO_DOT: `[^.${WIN_SLASH}]`, + START_ANCHOR: `(?:^|[${WIN_SLASH}])`, + END_ANCHOR: `(?:[${WIN_SLASH}]|$)`, + SEP: '\\' + }; + + /** + * POSIX Bracket Regex + */ + + const POSIX_REGEX_SOURCE$1 = { + alnum: 'a-zA-Z0-9', + alpha: 'a-zA-Z', + ascii: '\\x00-\\x7F', + blank: ' \\t', + cntrl: '\\x00-\\x1F\\x7F', + digit: '0-9', + graph: '\\x21-\\x7E', + lower: 'a-z', + print: '\\x20-\\x7E ', + punct: '\\-!"#$%&\'()\\*+,./:;<=>?@[\\]^_`{|}~', + space: ' \\t\\r\\n\\v\\f', + upper: 'A-Z', + word: 'A-Za-z0-9_', + xdigit: 'A-Fa-f0-9' + }; + + var constants$3 = { + MAX_LENGTH: 1024 * 64, + POSIX_REGEX_SOURCE: POSIX_REGEX_SOURCE$1, + + // regular expressions + REGEX_BACKSLASH: /\\(?![*+?^${}(|)[\]])/g, + REGEX_NON_SPECIAL_CHARS: /^[^@![\].,$*+?^{}()|\\/]+/, + REGEX_SPECIAL_CHARS: /[-*+?.^${}(|)[\]]/, + REGEX_SPECIAL_CHARS_BACKREF: /(\\?)((\W)(\3*))/g, + REGEX_SPECIAL_CHARS_GLOBAL: /([-*+?.^${}(|)[\]])/g, + REGEX_REMOVE_BACKSLASH: /(?:\[.*?[^\\]\]|\\(?=.))/g, + + // Replace globs with equivalent patterns to reduce parsing time. + REPLACEMENTS: { + '***': '*', + '**/**': '**', + '**/**/**': '**' + }, + + // Digits + CHAR_0: 48, /* 0 */ + CHAR_9: 57, /* 9 */ + + // Alphabet chars. + CHAR_UPPERCASE_A: 65, /* A */ + CHAR_LOWERCASE_A: 97, /* a */ + CHAR_UPPERCASE_Z: 90, /* Z */ + CHAR_LOWERCASE_Z: 122, /* z */ + + CHAR_LEFT_PARENTHESES: 40, /* ( */ + CHAR_RIGHT_PARENTHESES: 41, /* ) */ + + CHAR_ASTERISK: 42, /* * */ + + // Non-alphabetic chars. + CHAR_AMPERSAND: 38, /* & */ + CHAR_AT: 64, /* @ */ + CHAR_BACKWARD_SLASH: 92, /* \ */ + CHAR_CARRIAGE_RETURN: 13, /* \r */ + CHAR_CIRCUMFLEX_ACCENT: 94, /* ^ */ + CHAR_COLON: 58, /* : */ + CHAR_COMMA: 44, /* , */ + CHAR_DOT: 46, /* . */ + CHAR_DOUBLE_QUOTE: 34, /* " */ + CHAR_EQUAL: 61, /* = */ + CHAR_EXCLAMATION_MARK: 33, /* ! */ + CHAR_FORM_FEED: 12, /* \f */ + CHAR_FORWARD_SLASH: 47, /* / */ + CHAR_GRAVE_ACCENT: 96, /* ` */ + CHAR_HASH: 35, /* # */ + CHAR_HYPHEN_MINUS: 45, /* - */ + CHAR_LEFT_ANGLE_BRACKET: 60, /* < */ + CHAR_LEFT_CURLY_BRACE: 123, /* { */ + CHAR_LEFT_SQUARE_BRACKET: 91, /* [ */ + CHAR_LINE_FEED: 10, /* \n */ + CHAR_NO_BREAK_SPACE: 160, /* \u00A0 */ + CHAR_PERCENT: 37, /* % */ + CHAR_PLUS: 43, /* + */ + CHAR_QUESTION_MARK: 63, /* ? */ + CHAR_RIGHT_ANGLE_BRACKET: 62, /* > */ + CHAR_RIGHT_CURLY_BRACE: 125, /* } */ + CHAR_RIGHT_SQUARE_BRACKET: 93, /* ] */ + CHAR_SEMICOLON: 59, /* ; */ + CHAR_SINGLE_QUOTE: 39, /* ' */ + CHAR_SPACE: 32, /* */ + CHAR_TAB: 9, /* \t */ + CHAR_UNDERSCORE: 95, /* _ */ + CHAR_VERTICAL_LINE: 124, /* | */ + CHAR_ZERO_WIDTH_NOBREAK_SPACE: 65279, /* \uFEFF */ + + /** + * Create EXTGLOB_CHARS + */ + + extglobChars(chars) { + return { + '!': { type: 'negate', open: '(?:(?!(?:', close: `))${chars.STAR})` }, + '?': { type: 'qmark', open: '(?:', close: ')?' }, + '+': { type: 'plus', open: '(?:', close: ')+' }, + '*': { type: 'star', open: '(?:', close: ')*' }, + '@': { type: 'at', open: '(?:', close: ')' } + }; + }, + + /** + * Create GLOB_CHARS + */ + + globChars(win32) { + return win32 === true ? WINDOWS_CHARS : POSIX_CHARS; + } + }; + + (function (exports) { + + const { + REGEX_BACKSLASH, + REGEX_REMOVE_BACKSLASH, + REGEX_SPECIAL_CHARS, + REGEX_SPECIAL_CHARS_GLOBAL + } = constants$3; + + exports.isObject = val => val !== null && typeof val === 'object' && !Array.isArray(val); + exports.hasRegexChars = str => REGEX_SPECIAL_CHARS.test(str); + exports.isRegexChar = str => str.length === 1 && exports.hasRegexChars(str); + exports.escapeRegex = str => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, '\\$1'); + exports.toPosixSlashes = str => str.replace(REGEX_BACKSLASH, '/'); + + exports.removeBackslashes = str => { + return str.replace(REGEX_REMOVE_BACKSLASH, match => { + return match === '\\' ? '' : match; + }); + }; + + exports.supportsLookbehinds = () => { + const segs = process.version.slice(1).split('.').map(Number); + if (segs.length === 3 && segs[0] >= 9 || (segs[0] === 8 && segs[1] >= 10)) { + return true; + } + return false; + }; + + exports.escapeLast = (input, char, lastIdx) => { + const idx = input.lastIndexOf(char, lastIdx); + if (idx === -1) return input; + if (input[idx - 1] === '\\') return exports.escapeLast(input, char, idx - 1); + return `${input.slice(0, idx)}\\${input.slice(idx)}`; + }; + + exports.removePrefix = (input, state = {}) => { + let output = input; + if (output.startsWith('./')) { + output = output.slice(2); + state.prefix = './'; + } + return output; + }; + + exports.wrapOutput = (input, state = {}, options = {}) => { + const prepend = options.contains ? '' : '^'; + const append = options.contains ? '' : '$'; + + let output = `${prepend}(?:${input})${append}`; + if (state.negated === true) { + output = `(?:^(?!${output}).*$)`; + } + return output; + }; + + exports.basename = (path, { windows } = {}) => { + if (windows) { + return path.replace(/[\\/]$/, '').replace(/.*[\\/]/, ''); + } else { + return path.replace(/\/$/, '').replace(/.*\//, ''); + } + }; + } (utils$3)); + + const utils$2 = utils$3; + const { + CHAR_ASTERISK, /* * */ + CHAR_AT, /* @ */ + CHAR_BACKWARD_SLASH, /* \ */ + CHAR_COMMA, /* , */ + CHAR_DOT, /* . */ + CHAR_EXCLAMATION_MARK, /* ! */ + CHAR_FORWARD_SLASH, /* / */ + CHAR_LEFT_CURLY_BRACE, /* { */ + CHAR_LEFT_PARENTHESES, /* ( */ + CHAR_LEFT_SQUARE_BRACKET, /* [ */ + CHAR_PLUS, /* + */ + CHAR_QUESTION_MARK, /* ? */ + CHAR_RIGHT_CURLY_BRACE, /* } */ + CHAR_RIGHT_PARENTHESES, /* ) */ + CHAR_RIGHT_SQUARE_BRACKET /* ] */ + } = constants$3; + + const isPathSeparator = code => { + return code === CHAR_FORWARD_SLASH || code === CHAR_BACKWARD_SLASH; + }; + + const depth = token => { + if (token.isPrefix !== true) { + token.depth = token.isGlobstar ? Infinity : 1; + } + }; + + /** + * Quickly scans a glob pattern and returns an object with a handful of + * useful properties, like `isGlob`, `path` (the leading non-glob, if it exists), + * `glob` (the actual pattern), and `negated` (true if the path starts with `!`). + * + * ```js + * const pm = require('picomatch'); + * console.log(pm.scan('foo/bar/*.js')); + * { isGlob: true, input: 'foo/bar/*.js', base: 'foo/bar', glob: '*.js' } + * ``` + * @param {String} `str` + * @param {Object} `options` + * @return {Object} Returns an object with tokens and regex source string. + * @api public + */ + + const scan$1 = (input, options) => { + const opts = options || {}; + + const length = input.length - 1; + const scanToEnd = opts.parts === true || opts.scanToEnd === true; + const slashes = []; + const tokens = []; + const parts = []; + + let str = input; + let index = -1; + let start = 0; + let lastIndex = 0; + let isBrace = false; + let isBracket = false; + let isGlob = false; + let isExtglob = false; + let isGlobstar = false; + let braceEscaped = false; + let backslashes = false; + let negated = false; + let finished = false; + let braces = 0; + let prev; + let code; + let token = { value: '', depth: 0, isGlob: false }; + + const eos = () => index >= length; + const peek = () => str.charCodeAt(index + 1); + const advance = () => { + prev = code; + return str.charCodeAt(++index); + }; + + while (index < length) { + code = advance(); + let next; + + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + code = advance(); + + if (code === CHAR_LEFT_CURLY_BRACE) { + braceEscaped = true; + } + continue; + } + + if (braceEscaped === true || code === CHAR_LEFT_CURLY_BRACE) { + braces++; + + while (eos() !== true && (code = advance())) { + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + advance(); + continue; + } + + if (code === CHAR_LEFT_CURLY_BRACE) { + braces++; + continue; + } + + if (braceEscaped !== true && code === CHAR_DOT && (code = advance()) === CHAR_DOT) { + isBrace = token.isBrace = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + + break; + } + + if (braceEscaped !== true && code === CHAR_COMMA) { + isBrace = token.isBrace = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + + break; + } + + if (code === CHAR_RIGHT_CURLY_BRACE) { + braces--; + + if (braces === 0) { + braceEscaped = false; + isBrace = token.isBrace = true; + finished = true; + break; + } + } + } + + if (scanToEnd === true) { + continue; + } + + break; + } + + if (code === CHAR_FORWARD_SLASH) { + slashes.push(index); + tokens.push(token); + token = { value: '', depth: 0, isGlob: false }; + + if (finished === true) continue; + if (prev === CHAR_DOT && index === (start + 1)) { + start += 2; + continue; + } + + lastIndex = index + 1; + continue; + } + + if (opts.noext !== true) { + const isExtglobChar = code === CHAR_PLUS + || code === CHAR_AT + || code === CHAR_ASTERISK + || code === CHAR_QUESTION_MARK + || code === CHAR_EXCLAMATION_MARK; + + if (isExtglobChar === true && peek() === CHAR_LEFT_PARENTHESES) { + isGlob = token.isGlob = true; + isExtglob = token.isExtglob = true; + finished = true; + + if (scanToEnd === true) { + while (eos() !== true && (code = advance())) { + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + code = advance(); + continue; + } + + if (code === CHAR_RIGHT_PARENTHESES) { + isGlob = token.isGlob = true; + finished = true; + break; + } + } + continue; + } + break; + } + } + + if (code === CHAR_ASTERISK) { + if (prev === CHAR_ASTERISK) isGlobstar = token.isGlobstar = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + break; + } + + if (code === CHAR_QUESTION_MARK) { + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + break; + } + + if (code === CHAR_LEFT_SQUARE_BRACKET) { + while (eos() !== true && (next = advance())) { + if (next === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + advance(); + continue; + } + + if (next === CHAR_RIGHT_SQUARE_BRACKET) { + isBracket = token.isBracket = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + break; + } + } + } + + if (opts.nonegate !== true && code === CHAR_EXCLAMATION_MARK && index === start) { + negated = token.negated = true; + start++; + continue; + } + + if (opts.noparen !== true && code === CHAR_LEFT_PARENTHESES) { + isGlob = token.isGlob = true; + + if (scanToEnd === true) { + while (eos() !== true && (code = advance())) { + if (code === CHAR_LEFT_PARENTHESES) { + backslashes = token.backslashes = true; + code = advance(); + continue; + } + + if (code === CHAR_RIGHT_PARENTHESES) { + finished = true; + break; + } + } + continue; + } + break; + } + + if (isGlob === true) { + finished = true; + + if (scanToEnd === true) { + continue; + } + + break; + } + } + + if (opts.noext === true) { + isExtglob = false; + isGlob = false; + } + + let base = str; + let prefix = ''; + let glob = ''; + + if (start > 0) { + prefix = str.slice(0, start); + str = str.slice(start); + lastIndex -= start; + } + + if (base && isGlob === true && lastIndex > 0) { + base = str.slice(0, lastIndex); + glob = str.slice(lastIndex); + } else if (isGlob === true) { + base = ''; + glob = str; + } else { + base = str; + } + + if (base && base !== '' && base !== '/' && base !== str) { + if (isPathSeparator(base.charCodeAt(base.length - 1))) { + base = base.slice(0, -1); + } + } + + if (opts.unescape === true) { + if (glob) glob = utils$2.removeBackslashes(glob); + + if (base && backslashes === true) { + base = utils$2.removeBackslashes(base); + } + } + + const state = { + prefix, + input, + start, + base, + glob, + isBrace, + isBracket, + isGlob, + isExtglob, + isGlobstar, + negated + }; + + if (opts.tokens === true) { + state.maxDepth = 0; + if (!isPathSeparator(code)) { + tokens.push(token); + } + state.tokens = tokens; + } + + if (opts.parts === true || opts.tokens === true) { + let prevIndex; + + for (let idx = 0; idx < slashes.length; idx++) { + const n = prevIndex ? prevIndex + 1 : start; + const i = slashes[idx]; + const value = input.slice(n, i); + if (opts.tokens) { + if (idx === 0 && start !== 0) { + tokens[idx].isPrefix = true; + tokens[idx].value = prefix; + } else { + tokens[idx].value = value; + } + depth(tokens[idx]); + state.maxDepth += tokens[idx].depth; + } + if (idx !== 0 || value !== '') { + parts.push(value); + } + prevIndex = i; + } + + if (prevIndex && prevIndex + 1 < input.length) { + const value = input.slice(prevIndex + 1); + parts.push(value); + + if (opts.tokens) { + tokens[tokens.length - 1].value = value; + depth(tokens[tokens.length - 1]); + state.maxDepth += tokens[tokens.length - 1].depth; + } + } + + state.slashes = slashes; + state.parts = parts; + } + + return state; + }; + + var scan_1 = scan$1; + + const constants$2 = constants$3; + const utils$1 = utils$3; + + /** + * Constants + */ + + const { + MAX_LENGTH, + POSIX_REGEX_SOURCE, + REGEX_NON_SPECIAL_CHARS, + REGEX_SPECIAL_CHARS_BACKREF, + REPLACEMENTS + } = constants$2; + + /** + * Helpers + */ + + const expandRange = (args, options) => { + if (typeof options.expandRange === 'function') { + return options.expandRange(...args, options); + } + + args.sort(); + const value = `[${args.join('-')}]`; + + try { + /* eslint-disable-next-line no-new */ + new RegExp(value); + } catch (ex) { + return args.map(v => utils$1.escapeRegex(v)).join('..'); + } + + return value; + }; + + /** + * Create the message for a syntax error + */ + + const syntaxError = (type, char) => { + return `Missing ${type}: "${char}" - use "\\\\${char}" to match literal characters`; + }; + + /** + * Parse the given input string. + * @param {String} input + * @param {Object} options + * @return {Object} + */ + + const parse$2 = (input, options) => { + if (typeof input !== 'string') { + throw new TypeError('Expected a string'); + } + + input = REPLACEMENTS[input] || input; + + const opts = { ...options }; + const max = typeof opts.maxLength === 'number' ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; + + let len = input.length; + if (len > max) { + throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`); + } + + const bos = { type: 'bos', value: '', output: opts.prepend || '' }; + const tokens = [bos]; + + const capture = opts.capture ? '' : '?:'; + + // create constants based on platform, for windows or posix + const PLATFORM_CHARS = constants$2.globChars(opts.windows); + const EXTGLOB_CHARS = constants$2.extglobChars(PLATFORM_CHARS); + + const { + DOT_LITERAL, + PLUS_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + DOTS_SLASH, + NO_DOT, + NO_DOT_SLASH, + NO_DOTS_SLASH, + QMARK, + QMARK_NO_DOT, + STAR, + START_ANCHOR + } = PLATFORM_CHARS; + + const globstar = (opts) => { + return `(${capture}(?:(?!${START_ANCHOR}${opts.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; + }; + + const nodot = opts.dot ? '' : NO_DOT; + const qmarkNoDot = opts.dot ? QMARK : QMARK_NO_DOT; + let star = opts.bash === true ? globstar(opts) : STAR; + + if (opts.capture) { + star = `(${star})`; + } + + // minimatch options support + if (typeof opts.noext === 'boolean') { + opts.noextglob = opts.noext; + } + + const state = { + input, + index: -1, + start: 0, + dot: opts.dot === true, + consumed: '', + output: '', + prefix: '', + backtrack: false, + negated: false, + brackets: 0, + braces: 0, + parens: 0, + quotes: 0, + globstar: false, + tokens + }; + + input = utils$1.removePrefix(input, state); + len = input.length; + + const extglobs = []; + const braces = []; + const stack = []; + let prev = bos; + let value; + + /** + * Tokenizing helpers + */ + + const eos = () => state.index === len - 1; + const peek = state.peek = (n = 1) => input[state.index + n]; + const advance = state.advance = () => input[++state.index]; + const remaining = () => input.slice(state.index + 1); + const consume = (value = '', num = 0) => { + state.consumed += value; + state.index += num; + }; + const append = token => { + state.output += token.output != null ? token.output : token.value; + consume(token.value); + }; + + const negate = () => { + let count = 1; + + while (peek() === '!' && (peek(2) !== '(' || peek(3) === '?')) { + advance(); + state.start++; + count++; + } + + if (count % 2 === 0) { + return false; + } + + state.negated = true; + state.start++; + return true; + }; + + const increment = type => { + state[type]++; + stack.push(type); + }; + + const decrement = type => { + state[type]--; + stack.pop(); + }; + + /** + * Push tokens onto the tokens array. This helper speeds up + * tokenizing by 1) helping us avoid backtracking as much as possible, + * and 2) helping us avoid creating extra tokens when consecutive + * characters are plain text. This improves performance and simplifies + * lookbehinds. + */ + + const push = tok => { + if (prev.type === 'globstar') { + const isBrace = state.braces > 0 && (tok.type === 'comma' || tok.type === 'brace'); + const isExtglob = tok.extglob === true || (extglobs.length && (tok.type === 'pipe' || tok.type === 'paren')); + + if (tok.type !== 'slash' && tok.type !== 'paren' && !isBrace && !isExtglob) { + state.output = state.output.slice(0, -prev.output.length); + prev.type = 'star'; + prev.value = '*'; + prev.output = star; + state.output += prev.output; + } + } + + if (extglobs.length && tok.type !== 'paren' && !EXTGLOB_CHARS[tok.value]) { + extglobs[extglobs.length - 1].inner += tok.value; + } + + if (tok.value || tok.output) append(tok); + if (prev && prev.type === 'text' && tok.type === 'text') { + prev.value += tok.value; + prev.output = (prev.output || '') + tok.value; + return; + } + + tok.prev = prev; + tokens.push(tok); + prev = tok; + }; + + const extglobOpen = (type, value) => { + const token = { ...EXTGLOB_CHARS[value], conditions: 1, inner: '' }; + + token.prev = prev; + token.parens = state.parens; + token.output = state.output; + const output = (opts.capture ? '(' : '') + token.open; + + increment('parens'); + push({ type, value, output: state.output ? '' : ONE_CHAR }); + push({ type: 'paren', extglob: true, value: advance(), output }); + extglobs.push(token); + }; + + const extglobClose = token => { + let output = token.close + (opts.capture ? ')' : ''); + + if (token.type === 'negate') { + let extglobStar = star; + + if (token.inner && token.inner.length > 1 && token.inner.includes('/')) { + extglobStar = globstar(opts); + } + + if (extglobStar !== star || eos() || /^\)+$/.test(remaining())) { + output = token.close = `)$))${extglobStar}`; + } + + if (token.prev.type === 'bos' && eos()) { + state.negatedExtglob = true; + } + } + + push({ type: 'paren', extglob: true, value, output }); + decrement('parens'); + }; + + /** + * Fast paths + */ + + if (opts.fastpaths !== false && !/(^[*!]|[/()[\]{}"])/.test(input)) { + let backslashes = false; + + let output = input.replace(REGEX_SPECIAL_CHARS_BACKREF, (m, esc, chars, first, rest, index) => { + if (first === '\\') { + backslashes = true; + return m; + } + + if (first === '?') { + if (esc) { + return esc + first + (rest ? QMARK.repeat(rest.length) : ''); + } + if (index === 0) { + return qmarkNoDot + (rest ? QMARK.repeat(rest.length) : ''); + } + return QMARK.repeat(chars.length); + } + + if (first === '.') { + return DOT_LITERAL.repeat(chars.length); + } + + if (first === '*') { + if (esc) { + return esc + first + (rest ? star : ''); + } + return star; + } + return esc ? m : `\\${m}`; + }); + + if (backslashes === true) { + if (opts.unescape === true) { + output = output.replace(/\\/g, ''); + } else { + output = output.replace(/\\+/g, m => { + return m.length % 2 === 0 ? '\\\\' : (m ? '\\' : ''); + }); + } + } + + if (output === input && opts.contains === true) { + state.output = input; + return state; + } + + state.output = utils$1.wrapOutput(output, state, options); + return state; + } + + /** + * Tokenize input until we reach end-of-string + */ + + while (!eos()) { + value = advance(); + + if (value === '\u0000') { + continue; + } + + /** + * Escaped characters + */ + + if (value === '\\') { + const next = peek(); + + if (next === '/' && opts.bash !== true) { + continue; + } + + if (next === '.' || next === ';') { + continue; + } + + if (!next) { + value += '\\'; + push({ type: 'text', value }); + continue; + } + + // collapse slashes to reduce potential for exploits + const match = /^\\+/.exec(remaining()); + let slashes = 0; + + if (match && match[0].length > 2) { + slashes = match[0].length; + state.index += slashes; + if (slashes % 2 !== 0) { + value += '\\'; + } + } + + if (opts.unescape === true) { + value = advance() || ''; + } else { + value += advance() || ''; + } + + if (state.brackets === 0) { + push({ type: 'text', value }); + continue; + } + } + + /** + * If we're inside a regex character class, continue + * until we reach the closing bracket. + */ + + if (state.brackets > 0 && (value !== ']' || prev.value === '[' || prev.value === '[^')) { + if (opts.posix !== false && value === ':') { + const inner = prev.value.slice(1); + if (inner.includes('[')) { + prev.posix = true; + + if (inner.includes(':')) { + const idx = prev.value.lastIndexOf('['); + const pre = prev.value.slice(0, idx); + const rest = prev.value.slice(idx + 2); + const posix = POSIX_REGEX_SOURCE[rest]; + if (posix) { + prev.value = pre + posix; + state.backtrack = true; + advance(); + + if (!bos.output && tokens.indexOf(prev) === 1) { + bos.output = ONE_CHAR; + } + continue; + } + } + } + } + + if ((value === '[' && peek() !== ':') || (value === '-' && peek() === ']')) { + value = `\\${value}`; + } + + if (value === ']' && (prev.value === '[' || prev.value === '[^')) { + value = `\\${value}`; + } + + if (opts.posix === true && value === '!' && prev.value === '[') { + value = '^'; + } + + prev.value += value; + append({ value }); + continue; + } + + /** + * If we're inside a quoted string, continue + * until we reach the closing double quote. + */ + + if (state.quotes === 1 && value !== '"') { + value = utils$1.escapeRegex(value); + prev.value += value; + append({ value }); + continue; + } + + /** + * Double quotes + */ + + if (value === '"') { + state.quotes = state.quotes === 1 ? 0 : 1; + if (opts.keepQuotes === true) { + push({ type: 'text', value }); + } + continue; + } + + /** + * Parentheses + */ + + if (value === '(') { + increment('parens'); + push({ type: 'paren', value }); + continue; + } + + if (value === ')') { + if (state.parens === 0 && opts.strictBrackets === true) { + throw new SyntaxError(syntaxError('opening', '(')); + } + + const extglob = extglobs[extglobs.length - 1]; + if (extglob && state.parens === extglob.parens + 1) { + extglobClose(extglobs.pop()); + continue; + } + + push({ type: 'paren', value, output: state.parens ? ')' : '\\)' }); + decrement('parens'); + continue; + } + + /** + * Square brackets + */ + + if (value === '[') { + if (opts.nobracket === true || !remaining().includes(']')) { + if (opts.nobracket !== true && opts.strictBrackets === true) { + throw new SyntaxError(syntaxError('closing', ']')); + } + + value = `\\${value}`; + } else { + increment('brackets'); + } + + push({ type: 'bracket', value }); + continue; + } + + if (value === ']') { + if (opts.nobracket === true || (prev && prev.type === 'bracket' && prev.value.length === 1)) { + push({ type: 'text', value, output: `\\${value}` }); + continue; + } + + if (state.brackets === 0) { + if (opts.strictBrackets === true) { + throw new SyntaxError(syntaxError('opening', '[')); + } + + push({ type: 'text', value, output: `\\${value}` }); + continue; + } + + decrement('brackets'); + + const prevValue = prev.value.slice(1); + if (prev.posix !== true && prevValue[0] === '^' && !prevValue.includes('/')) { + value = `/${value}`; + } + + prev.value += value; + append({ value }); + + // when literal brackets are explicitly disabled + // assume we should match with a regex character class + if (opts.literalBrackets === false || utils$1.hasRegexChars(prevValue)) { + continue; + } + + const escaped = utils$1.escapeRegex(prev.value); + state.output = state.output.slice(0, -prev.value.length); + + // when literal brackets are explicitly enabled + // assume we should escape the brackets to match literal characters + if (opts.literalBrackets === true) { + state.output += escaped; + prev.value = escaped; + continue; + } + + // when the user specifies nothing, try to match both + prev.value = `(${capture}${escaped}|${prev.value})`; + state.output += prev.value; + continue; + } + + /** + * Braces + */ + + if (value === '{' && opts.nobrace !== true) { + increment('braces'); + + const open = { + type: 'brace', + value, + output: '(', + outputIndex: state.output.length, + tokensIndex: state.tokens.length + }; + + braces.push(open); + push(open); + continue; + } + + if (value === '}') { + const brace = braces[braces.length - 1]; + + if (opts.nobrace === true || !brace) { + push({ type: 'text', value, output: value }); + continue; + } + + let output = ')'; + + if (brace.dots === true) { + const arr = tokens.slice(); + const range = []; + + for (let i = arr.length - 1; i >= 0; i--) { + tokens.pop(); + if (arr[i].type === 'brace') { + break; + } + if (arr[i].type !== 'dots') { + range.unshift(arr[i].value); + } + } + + output = expandRange(range, opts); + state.backtrack = true; + } + + if (brace.comma !== true && brace.dots !== true) { + const out = state.output.slice(0, brace.outputIndex); + const toks = state.tokens.slice(brace.tokensIndex); + brace.value = brace.output = '\\{'; + value = output = '\\}'; + state.output = out; + for (const t of toks) { + state.output += (t.output || t.value); + } + } + + push({ type: 'brace', value, output }); + decrement('braces'); + braces.pop(); + continue; + } + + /** + * Pipes + */ + + if (value === '|') { + if (extglobs.length > 0) { + extglobs[extglobs.length - 1].conditions++; + } + push({ type: 'text', value }); + continue; + } + + /** + * Commas + */ + + if (value === ',') { + let output = value; + + const brace = braces[braces.length - 1]; + if (brace && stack[stack.length - 1] === 'braces') { + brace.comma = true; + output = '|'; + } + + push({ type: 'comma', value, output }); + continue; + } + + /** + * Slashes + */ + + if (value === '/') { + // if the beginning of the glob is "./", advance the start + // to the current index, and don't add the "./" characters + // to the state. This greatly simplifies lookbehinds when + // checking for BOS characters like "!" and "." (not "./") + if (prev.type === 'dot' && state.index === state.start + 1) { + state.start = state.index + 1; + state.consumed = ''; + state.output = ''; + tokens.pop(); + prev = bos; // reset "prev" to the first token + continue; + } + + push({ type: 'slash', value, output: SLASH_LITERAL }); + continue; + } + + /** + * Dots + */ + + if (value === '.') { + if (state.braces > 0 && prev.type === 'dot') { + if (prev.value === '.') prev.output = DOT_LITERAL; + const brace = braces[braces.length - 1]; + prev.type = 'dots'; + prev.output += value; + prev.value += value; + brace.dots = true; + continue; + } + + if ((state.braces + state.parens) === 0 && prev.type !== 'bos' && prev.type !== 'slash') { + push({ type: 'text', value, output: DOT_LITERAL }); + continue; + } + + push({ type: 'dot', value, output: DOT_LITERAL }); + continue; + } + + /** + * Question marks + */ + + if (value === '?') { + const isGroup = prev && prev.value === '('; + if (!isGroup && opts.noextglob !== true && peek() === '(' && peek(2) !== '?') { + extglobOpen('qmark', value); + continue; + } + + if (prev && prev.type === 'paren') { + const next = peek(); + let output = value; + + if (next === '<' && !utils$1.supportsLookbehinds()) { + throw new Error('Node.js v10 or higher is required for regex lookbehinds'); + } + + if ((prev.value === '(' && !/[!=<:]/.test(next)) || (next === '<' && !/<([!=]|\w+>)/.test(remaining()))) { + output = `\\${value}`; + } + + push({ type: 'text', value, output }); + continue; + } + + if (opts.dot !== true && (prev.type === 'slash' || prev.type === 'bos')) { + push({ type: 'qmark', value, output: QMARK_NO_DOT }); + continue; + } + + push({ type: 'qmark', value, output: QMARK }); + continue; + } + + /** + * Exclamation + */ + + if (value === '!') { + if (opts.noextglob !== true && peek() === '(') { + if (peek(2) !== '?' || !/[!=<:]/.test(peek(3))) { + extglobOpen('negate', value); + continue; + } + } + + if (opts.nonegate !== true && state.index === 0) { + negate(); + continue; + } + } + + /** + * Plus + */ + + if (value === '+') { + if (opts.noextglob !== true && peek() === '(' && peek(2) !== '?') { + extglobOpen('plus', value); + continue; + } + + if ((prev && prev.value === '(') || opts.regex === false) { + push({ type: 'plus', value, output: PLUS_LITERAL }); + continue; + } + + if ((prev && (prev.type === 'bracket' || prev.type === 'paren' || prev.type === 'brace')) || state.parens > 0) { + push({ type: 'plus', value }); + continue; + } + + push({ type: 'plus', value: PLUS_LITERAL }); + continue; + } + + /** + * Plain text + */ + + if (value === '@') { + if (opts.noextglob !== true && peek() === '(' && peek(2) !== '?') { + push({ type: 'at', extglob: true, value, output: '' }); + continue; + } + + push({ type: 'text', value }); + continue; + } + + /** + * Plain text + */ + + if (value !== '*') { + if (value === '$' || value === '^') { + value = `\\${value}`; + } + + const match = REGEX_NON_SPECIAL_CHARS.exec(remaining()); + if (match) { + value += match[0]; + state.index += match[0].length; + } + + push({ type: 'text', value }); + continue; + } + + /** + * Stars + */ + + if (prev && (prev.type === 'globstar' || prev.star === true)) { + prev.type = 'star'; + prev.star = true; + prev.value += value; + prev.output = star; + state.backtrack = true; + state.globstar = true; + consume(value); + continue; + } + + let rest = remaining(); + if (opts.noextglob !== true && /^\([^?]/.test(rest)) { + extglobOpen('star', value); + continue; + } + + if (prev.type === 'star') { + if (opts.noglobstar === true) { + consume(value); + continue; + } + + const prior = prev.prev; + const before = prior.prev; + const isStart = prior.type === 'slash' || prior.type === 'bos'; + const afterStar = before && (before.type === 'star' || before.type === 'globstar'); + + if (opts.bash === true && (!isStart || (rest[0] && rest[0] !== '/'))) { + push({ type: 'star', value, output: '' }); + continue; + } + + const isBrace = state.braces > 0 && (prior.type === 'comma' || prior.type === 'brace'); + const isExtglob = extglobs.length && (prior.type === 'pipe' || prior.type === 'paren'); + if (!isStart && prior.type !== 'paren' && !isBrace && !isExtglob) { + push({ type: 'star', value, output: '' }); + continue; + } + + // strip consecutive `/**/` + while (rest.slice(0, 3) === '/**') { + const after = input[state.index + 4]; + if (after && after !== '/') { + break; + } + rest = rest.slice(3); + consume('/**', 3); + } + + if (prior.type === 'bos' && eos()) { + prev.type = 'globstar'; + prev.value += value; + prev.output = globstar(opts); + state.output = prev.output; + state.globstar = true; + consume(value); + continue; + } + + if (prior.type === 'slash' && prior.prev.type !== 'bos' && !afterStar && eos()) { + state.output = state.output.slice(0, -(prior.output + prev.output).length); + prior.output = `(?:${prior.output}`; + + prev.type = 'globstar'; + prev.output = globstar(opts) + (opts.strictSlashes ? ')' : '|$)'); + prev.value += value; + state.globstar = true; + state.output += prior.output + prev.output; + consume(value); + continue; + } + + if (prior.type === 'slash' && prior.prev.type !== 'bos' && rest[0] === '/') { + const end = rest[1] !== void 0 ? '|$' : ''; + + state.output = state.output.slice(0, -(prior.output + prev.output).length); + prior.output = `(?:${prior.output}`; + + prev.type = 'globstar'; + prev.output = `${globstar(opts)}${SLASH_LITERAL}|${SLASH_LITERAL}${end})`; + prev.value += value; + + state.output += prior.output + prev.output; + state.globstar = true; + + consume(value + advance()); + + push({ type: 'slash', value: '/', output: '' }); + continue; + } + + if (prior.type === 'bos' && rest[0] === '/') { + prev.type = 'globstar'; + prev.value += value; + prev.output = `(?:^|${SLASH_LITERAL}|${globstar(opts)}${SLASH_LITERAL})`; + state.output = prev.output; + state.globstar = true; + consume(value + advance()); + push({ type: 'slash', value: '/', output: '' }); + continue; + } + + // remove single star from output + state.output = state.output.slice(0, -prev.output.length); + + // reset previous token to globstar + prev.type = 'globstar'; + prev.output = globstar(opts); + prev.value += value; + + // reset output with globstar + state.output += prev.output; + state.globstar = true; + consume(value); + continue; + } + + const token = { type: 'star', value, output: star }; + + if (opts.bash === true) { + token.output = '.*?'; + if (prev.type === 'bos' || prev.type === 'slash') { + token.output = nodot + token.output; + } + push(token); + continue; + } + + if (prev && (prev.type === 'bracket' || prev.type === 'paren') && opts.regex === true) { + token.output = value; + push(token); + continue; + } + + if (state.index === state.start || prev.type === 'slash' || prev.type === 'dot') { + if (prev.type === 'dot') { + state.output += NO_DOT_SLASH; + prev.output += NO_DOT_SLASH; + + } else if (opts.dot === true) { + state.output += NO_DOTS_SLASH; + prev.output += NO_DOTS_SLASH; + + } else { + state.output += nodot; + prev.output += nodot; + } + + if (peek() !== '*') { + state.output += ONE_CHAR; + prev.output += ONE_CHAR; + } + } + + push(token); + } + + while (state.brackets > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', ']')); + state.output = utils$1.escapeLast(state.output, '['); + decrement('brackets'); + } + + while (state.parens > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', ')')); + state.output = utils$1.escapeLast(state.output, '('); + decrement('parens'); + } + + while (state.braces > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', '}')); + state.output = utils$1.escapeLast(state.output, '{'); + decrement('braces'); + } + + if (opts.strictSlashes !== true && (prev.type === 'star' || prev.type === 'bracket')) { + push({ type: 'maybe_slash', value: '', output: `${SLASH_LITERAL}?` }); + } + + // rebuild the output if we had to backtrack at any point + if (state.backtrack === true) { + state.output = ''; + + for (const token of state.tokens) { + state.output += token.output != null ? token.output : token.value; + + if (token.suffix) { + state.output += token.suffix; + } + } + } + + return state; + }; + + /** + * Fast paths for creating regular expressions for common glob patterns. + * This can significantly speed up processing and has very little downside + * impact when none of the fast paths match. + */ + + parse$2.fastpaths = (input, options) => { + const opts = { ...options }; + const max = typeof opts.maxLength === 'number' ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; + const len = input.length; + if (len > max) { + throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`); + } + + input = REPLACEMENTS[input] || input; + + // create constants based on platform, for windows or posix + const { + DOT_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + DOTS_SLASH, + NO_DOT, + NO_DOTS, + NO_DOTS_SLASH, + STAR, + START_ANCHOR + } = constants$2.globChars(opts.windows); + + const nodot = opts.dot ? NO_DOTS : NO_DOT; + const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT; + const capture = opts.capture ? '' : '?:'; + const state = { negated: false, prefix: '' }; + let star = opts.bash === true ? '.*?' : STAR; + + if (opts.capture) { + star = `(${star})`; + } + + const globstar = (opts) => { + if (opts.noglobstar === true) return star; + return `(${capture}(?:(?!${START_ANCHOR}${opts.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; + }; + + const create = str => { + switch (str) { + case '*': + return `${nodot}${ONE_CHAR}${star}`; + + case '.*': + return `${DOT_LITERAL}${ONE_CHAR}${star}`; + + case '*.*': + return `${nodot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; + + case '*/*': + return `${nodot}${star}${SLASH_LITERAL}${ONE_CHAR}${slashDot}${star}`; + + case '**': + return nodot + globstar(opts); + + case '**/*': + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${ONE_CHAR}${star}`; + + case '**/*.*': + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; + + case '**/.*': + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`; + + default: { + const match = /^(.*?)\.(\w+)$/.exec(str); + if (!match) return; + + const source = create(match[1]); + if (!source) return; + + return source + DOT_LITERAL + match[2]; + } + } + }; + + const output = utils$1.removePrefix(input, state); + let source = create(output); + + if (source && opts.strictSlashes !== true) { + source += `${SLASH_LITERAL}?`; + } + + return source; + }; + + var parse_1 = parse$2; + + const scan = scan_1; + const parse$1 = parse_1; + const utils = utils$3; + const constants$1 = constants$3; + const isObject = val => val && typeof val === 'object' && !Array.isArray(val); + + /** + * Creates a matcher function from one or more glob patterns. The + * returned function takes a string to match as its first argument, + * and returns true if the string is a match. The returned matcher + * function also takes a boolean as the second argument that, when true, + * returns an object with additional information. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch(glob[, options]); + * + * const isMatch = picomatch('*.!(*a)'); + * console.log(isMatch('a.a')); //=> false + * console.log(isMatch('a.b')); //=> true + * ``` + * @name picomatch + * @param {String|Array} `globs` One or more glob patterns. + * @param {Object=} `options` + * @return {Function=} Returns a matcher function. + * @api public + */ + + const picomatch = (glob, options, returnState = false) => { + if (Array.isArray(glob)) { + const fns = glob.map(input => picomatch(input, options, returnState)); + const arrayMatcher = str => { + for (const isMatch of fns) { + const state = isMatch(str); + if (state) return state; + } + return false; + }; + return arrayMatcher; + } + + const isState = isObject(glob) && glob.tokens && glob.input; + + if (glob === '' || (typeof glob !== 'string' && !isState)) { + throw new TypeError('Expected pattern to be a non-empty string'); + } + + const opts = options || {}; + const posix = opts.windows; + const regex = isState + ? picomatch.compileRe(glob, options) + : picomatch.makeRe(glob, options, false, true); + + const state = regex.state; + delete regex.state; + + let isIgnored = () => false; + if (opts.ignore) { + const ignoreOpts = { ...options, ignore: null, onMatch: null, onResult: null }; + isIgnored = picomatch(opts.ignore, ignoreOpts, returnState); + } + + const matcher = (input, returnObject = false) => { + const { isMatch, match, output } = picomatch.test(input, regex, options, { glob, posix }); + const result = { glob, state, regex, posix, input, output, match, isMatch }; + + if (typeof opts.onResult === 'function') { + opts.onResult(result); + } + + if (isMatch === false) { + result.isMatch = false; + return returnObject ? result : false; + } + + if (isIgnored(input)) { + if (typeof opts.onIgnore === 'function') { + opts.onIgnore(result); + } + result.isMatch = false; + return returnObject ? result : false; + } + + if (typeof opts.onMatch === 'function') { + opts.onMatch(result); + } + return returnObject ? result : true; + }; + + if (returnState) { + matcher.state = state; + } + + return matcher; + }; + + /** + * Test `input` with the given `regex`. This is used by the main + * `picomatch()` function to test the input string. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.test(input, regex[, options]); + * + * console.log(picomatch.test('foo/bar', /^(?:([^/]*?)\/([^/]*?))$/)); + * // { isMatch: true, match: [ 'foo/', 'foo', 'bar' ], output: 'foo/bar' } + * ``` + * @param {String} `input` String to test. + * @param {RegExp} `regex` + * @return {Object} Returns an object with matching info. + * @api public + */ + + picomatch.test = (input, regex, options, { glob, posix } = {}) => { + if (typeof input !== 'string') { + throw new TypeError('Expected input to be a string'); + } + + if (input === '') { + return { isMatch: false, output: '' }; + } + + const opts = options || {}; + const format = opts.format || (posix ? utils.toPosixSlashes : null); + let match = input === glob; + let output = (match && format) ? format(input) : input; + + if (match === false) { + output = format ? format(input) : input; + match = output === glob; + } + + if (match === false || opts.capture === true) { + if (opts.matchBase === true || opts.basename === true) { + match = picomatch.matchBase(input, regex, options, posix); + } else { + match = regex.exec(output); + } + } + + return { isMatch: Boolean(match), match, output }; + }; + + /** + * Match the basename of a filepath. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.matchBase(input, glob[, options]); + * console.log(picomatch.matchBase('foo/bar.js', '*.js'); // true + * ``` + * @param {String} `input` String to test. + * @param {RegExp|String} `glob` Glob pattern or regex created by [.makeRe](#makeRe). + * @return {Boolean} + * @api public + */ + + picomatch.matchBase = (input, glob, options) => { + const regex = glob instanceof RegExp ? glob : picomatch.makeRe(glob, options); + return regex.test(utils.basename(input)); + }; + + /** + * Returns true if **any** of the given glob `patterns` match the specified `string`. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.isMatch(string, patterns[, options]); + * + * console.log(picomatch.isMatch('a.a', ['b.*', '*.a'])); //=> true + * console.log(picomatch.isMatch('a.a', 'b.*')); //=> false + * ``` + * @param {String|Array} str The string to test. + * @param {String|Array} patterns One or more glob patterns to use for matching. + * @param {Object} [options] See available [options](#options). + * @return {Boolean} Returns true if any patterns match `str` + * @api public + */ + + picomatch.isMatch = (str, patterns, options) => picomatch(patterns, options)(str); + + /** + * Parse a glob pattern to create the source string for a regular + * expression. + * + * ```js + * const picomatch = require('picomatch'); + * const result = picomatch.parse(pattern[, options]); + * ``` + * @param {String} `pattern` + * @param {Object} `options` + * @return {Object} Returns an object with useful properties and output to be used as a regex source string. + * @api public + */ + + picomatch.parse = (pattern, options) => { + if (Array.isArray(pattern)) return pattern.map(p => picomatch.parse(p, options)); + return parse$1(pattern, { ...options, fastpaths: false }); + }; + + /** + * Scan a glob pattern to separate the pattern into segments. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.scan(input[, options]); + * + * const result = picomatch.scan('!./foo/*.js'); + * console.log(result); + * { prefix: '!./', + * input: '!./foo/*.js', + * start: 3, + * base: 'foo', + * glob: '*.js', + * isBrace: false, + * isBracket: false, + * isGlob: true, + * isExtglob: false, + * isGlobstar: false, + * negated: true } + * ``` + * @param {String} `input` Glob pattern to scan. + * @param {Object} `options` + * @return {Object} Returns an object with + * @api public + */ + + picomatch.scan = (input, options) => scan(input, options); + + /** + * Create a regular expression from a parsed glob pattern. + * + * ```js + * const picomatch = require('picomatch'); + * const state = picomatch.parse('*.js'); + * // picomatch.compileRe(state[, options]); + * + * console.log(picomatch.compileRe(state)); + * //=> /^(?:(?!\.)(?=.)[^/]*?\.js)$/ + * ``` + * @param {String} `state` The object returned from the `.parse` method. + * @param {Object} `options` + * @return {RegExp} Returns a regex created from the given pattern. + * @api public + */ + + picomatch.compileRe = (parsed, options, returnOutput = false, returnState = false) => { + if (returnOutput === true) { + return parsed.output; + } + + const opts = options || {}; + const prepend = opts.contains ? '' : '^'; + const append = opts.contains ? '' : '$'; + + let source = `${prepend}(?:${parsed.output})${append}`; + if (parsed && parsed.negated === true) { + source = `^(?!${source}).*$`; + } + + const regex = picomatch.toRegex(source, options); + if (returnState === true) { + regex.state = parsed; + } + + return regex; + }; + + picomatch.makeRe = (input, options, returnOutput = false, returnState = false) => { + if (!input || typeof input !== 'string') { + throw new TypeError('Expected a non-empty string'); + } + + const opts = options || {}; + let parsed = { negated: false, fastpaths: true }; + let prefix = ''; + let output; + + if (input.startsWith('./')) { + input = input.slice(2); + prefix = parsed.prefix = './'; + } + + if (opts.fastpaths !== false && (input[0] === '.' || input[0] === '*')) { + output = parse$1.fastpaths(input, options); + } + + if (output === undefined) { + parsed = parse$1(input, options); + parsed.prefix = prefix + (parsed.prefix || ''); + } else { + parsed.output = output; + } + + return picomatch.compileRe(parsed, options, returnOutput, returnState); + }; + + /** + * Create a regular expression from the given regex source string. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.toRegex(source[, options]); + * + * const { output } = picomatch.parse('*.js'); + * console.log(picomatch.toRegex(output)); + * //=> /^(?:(?!\.)(?=.)[^/]*?\.js)$/ + * ``` + * @param {String} `source` Regular expression source string. + * @param {Object} `options` + * @return {RegExp} + * @api public + */ + + picomatch.toRegex = (source, options) => { + try { + const opts = options || {}; + return new RegExp(source, opts.flags || (opts.nocase ? 'i' : '')); + } catch (err) { + if (options && options.debug === true) throw err; + return /$^/; + } + }; + + /** + * Picomatch constants. + * @return {Object} + */ + + picomatch.constants = constants$1; + + /** + * Expose "picomatch" + */ + + var picomatch_1 = picomatch; + + var picomatchBrowser = picomatch_1; + + var pm = /*@__PURE__*/getDefaultExportFromCjs(picomatchBrowser); + + function isArray(arg) { + return Array.isArray(arg); + } + function ensureArray(thing) { + if (isArray(thing)) + return thing; + if (thing == null) + return []; + return [thing]; + } + const globToTest = (glob) => { + const pattern = glob; + const fn = pm(pattern, { dot: true }); + return { + test: (what) => { + const result = fn(what); + return result; + }, + }; + }; + const testTrue = { + test: () => true, + }; + const getMatcher = (filter) => { + const bundleTest = "bundle" in filter && filter.bundle != null ? globToTest(filter.bundle) : testTrue; + const fileTest = "file" in filter && filter.file != null ? globToTest(filter.file) : testTrue; + return { bundleTest, fileTest }; + }; + const createFilter = (include, exclude) => { + const includeMatchers = ensureArray(include).map(getMatcher); + const excludeMatchers = ensureArray(exclude).map(getMatcher); + return (bundleId, id) => { + for (let i = 0; i < excludeMatchers.length; ++i) { + const { bundleTest, fileTest } = excludeMatchers[i]; + if (bundleTest.test(bundleId) && fileTest.test(id)) + return false; + } + for (let i = 0; i < includeMatchers.length; ++i) { + const { bundleTest, fileTest } = includeMatchers[i]; + if (bundleTest.test(bundleId) && fileTest.test(id)) + return true; + } + return !includeMatchers.length; + }; + }; + + const throttleFilter = (callback, limit) => { + let waiting = false; + return (val) => { + if (!waiting) { + callback(val); + waiting = true; + setTimeout(() => { + waiting = false; + }, limit); + } + }; + }; + const prepareFilter = (filt) => { + if (filt === "") + return []; + return (filt + .split(",") + // remove spaces before and after + .map((entry) => entry.trim()) + // unquote " + .map((entry) => entry.startsWith('"') && entry.endsWith('"') ? entry.substring(1, entry.length - 1) : entry) + // unquote ' + .map((entry) => entry.startsWith("'") && entry.endsWith("'") ? entry.substring(1, entry.length - 1) : entry) + // remove empty strings + .filter((entry) => entry) + // parse bundle:file + .map((entry) => entry.split(":")) + // normalize entry just in case + .flatMap((entry) => { + if (entry.length === 0) + return []; + let bundle = null; + let file = null; + if (entry.length === 1 && entry[0]) { + file = entry[0]; + return [{ file, bundle }]; + } + bundle = entry[0] || null; + file = entry.slice(1).join(":") || null; + return [{ bundle, file }]; + })); + }; + const useFilter = () => { + const [includeFilter, setIncludeFilter] = h(""); + const [excludeFilter, setExcludeFilter] = h(""); + const setIncludeFilterTrottled = F(() => throttleFilter(setIncludeFilter, 200), []); + const setExcludeFilterTrottled = F(() => throttleFilter(setExcludeFilter, 200), []); + const isIncluded = F(() => createFilter(prepareFilter(includeFilter), prepareFilter(excludeFilter)), [includeFilter, excludeFilter]); + const getModuleFilterMultiplier = T((bundleId, data) => { + return isIncluded(bundleId, data.id) ? 1 : 0; + }, [isIncluded]); + return { + getModuleFilterMultiplier, + includeFilter, + excludeFilter, + setExcludeFilter: setExcludeFilterTrottled, + setIncludeFilter: setIncludeFilterTrottled, + }; + }; + + function ascending(a, b) { + return a == null || b == null ? NaN : a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN; + } + + function descending(a, b) { + return a == null || b == null ? NaN + : b < a ? -1 + : b > a ? 1 + : b >= a ? 0 + : NaN; + } + + function bisector(f) { + let compare1, compare2, delta; + + // If an accessor is specified, promote it to a comparator. In this case we + // can test whether the search value is (self-) comparable. We can’t do this + // for a comparator (except for specific, known comparators) because we can’t + // tell if the comparator is symmetric, and an asymmetric comparator can’t be + // used to test whether a single value is comparable. + if (f.length !== 2) { + compare1 = ascending; + compare2 = (d, x) => ascending(f(d), x); + delta = (d, x) => f(d) - x; + } else { + compare1 = f === ascending || f === descending ? f : zero$1; + compare2 = f; + delta = f; + } + + function left(a, x, lo = 0, hi = a.length) { + if (lo < hi) { + if (compare1(x, x) !== 0) return hi; + do { + const mid = (lo + hi) >>> 1; + if (compare2(a[mid], x) < 0) lo = mid + 1; + else hi = mid; + } while (lo < hi); + } + return lo; + } + + function right(a, x, lo = 0, hi = a.length) { + if (lo < hi) { + if (compare1(x, x) !== 0) return hi; + do { + const mid = (lo + hi) >>> 1; + if (compare2(a[mid], x) <= 0) lo = mid + 1; + else hi = mid; + } while (lo < hi); + } + return lo; + } + + function center(a, x, lo = 0, hi = a.length) { + const i = left(a, x, lo, hi - 1); + return i > lo && delta(a[i - 1], x) > -delta(a[i], x) ? i - 1 : i; + } + + return {left, center, right}; + } + + function zero$1() { + return 0; + } + + function number$1(x) { + return x === null ? NaN : +x; + } + + const ascendingBisect = bisector(ascending); + const bisectRight = ascendingBisect.right; + bisector(number$1).center; + var bisect = bisectRight; + + class InternMap extends Map { + constructor(entries, key = keyof) { + super(); + Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}}); + if (entries != null) for (const [key, value] of entries) this.set(key, value); + } + get(key) { + return super.get(intern_get(this, key)); + } + has(key) { + return super.has(intern_get(this, key)); + } + set(key, value) { + return super.set(intern_set(this, key), value); + } + delete(key) { + return super.delete(intern_delete(this, key)); + } + } + + function intern_get({_intern, _key}, value) { + const key = _key(value); + return _intern.has(key) ? _intern.get(key) : value; + } + + function intern_set({_intern, _key}, value) { + const key = _key(value); + if (_intern.has(key)) return _intern.get(key); + _intern.set(key, value); + return value; + } + + function intern_delete({_intern, _key}, value) { + const key = _key(value); + if (_intern.has(key)) { + value = _intern.get(key); + _intern.delete(key); + } + return value; + } + + function keyof(value) { + return value !== null && typeof value === "object" ? value.valueOf() : value; + } + + function identity$2(x) { + return x; + } + + function group(values, ...keys) { + return nest(values, identity$2, identity$2, keys); + } + + function nest(values, map, reduce, keys) { + return (function regroup(values, i) { + if (i >= keys.length) return reduce(values); + const groups = new InternMap(); + const keyof = keys[i++]; + let index = -1; + for (const value of values) { + const key = keyof(value, ++index, values); + const group = groups.get(key); + if (group) group.push(value); + else groups.set(key, [value]); + } + for (const [key, values] of groups) { + groups.set(key, regroup(values, i)); + } + return map(groups); + })(values, 0); + } + + const e10 = Math.sqrt(50), + e5 = Math.sqrt(10), + e2 = Math.sqrt(2); + + function tickSpec(start, stop, count) { + const step = (stop - start) / Math.max(0, count), + power = Math.floor(Math.log10(step)), + error = step / Math.pow(10, power), + factor = error >= e10 ? 10 : error >= e5 ? 5 : error >= e2 ? 2 : 1; + let i1, i2, inc; + if (power < 0) { + inc = Math.pow(10, -power) / factor; + i1 = Math.round(start * inc); + i2 = Math.round(stop * inc); + if (i1 / inc < start) ++i1; + if (i2 / inc > stop) --i2; + inc = -inc; + } else { + inc = Math.pow(10, power) * factor; + i1 = Math.round(start / inc); + i2 = Math.round(stop / inc); + if (i1 * inc < start) ++i1; + if (i2 * inc > stop) --i2; + } + if (i2 < i1 && 0.5 <= count && count < 2) return tickSpec(start, stop, count * 2); + return [i1, i2, inc]; + } + + function ticks(start, stop, count) { + stop = +stop, start = +start, count = +count; + if (!(count > 0)) return []; + if (start === stop) return [start]; + const reverse = stop < start, [i1, i2, inc] = reverse ? tickSpec(stop, start, count) : tickSpec(start, stop, count); + if (!(i2 >= i1)) return []; + const n = i2 - i1 + 1, ticks = new Array(n); + if (reverse) { + if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) / -inc; + else for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) * inc; + } else { + if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) / -inc; + else for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) * inc; + } + return ticks; + } + + function tickIncrement(start, stop, count) { + stop = +stop, start = +start, count = +count; + return tickSpec(start, stop, count)[2]; + } + + function tickStep(start, stop, count) { + stop = +stop, start = +start, count = +count; + const reverse = stop < start, inc = reverse ? tickIncrement(stop, start, count) : tickIncrement(start, stop, count); + return (reverse ? -1 : 1) * (inc < 0 ? 1 / -inc : inc); + } + + const TOP_PADDING = 20; + const PADDING = 2; + + const Node = ({ node, onMouseOver, onClick, selected }) => { + const { getModuleColor } = q(StaticContext); + const { backgroundColor, fontColor } = getModuleColor(node); + const { x0, x1, y1, y0, data, children = null } = node; + const textRef = _(null); + const textRectRef = _(); + const width = x1 - x0; + const height = y1 - y0; + const textProps = { + "font-size": "0.7em", + "dominant-baseline": "middle", + "text-anchor": "middle", + x: width / 2, + }; + if (children != null) { + textProps.y = (TOP_PADDING + PADDING) / 2; + } + else { + textProps.y = height / 2; + } + y(() => { + if (width == 0 || height == 0 || !textRef.current) { + return; + } + if (textRectRef.current == null) { + textRectRef.current = textRef.current.getBoundingClientRect(); + } + let scale = 1; + if (children != null) { + scale = Math.min((width * 0.9) / textRectRef.current.width, Math.min(height, TOP_PADDING + PADDING) / textRectRef.current.height); + scale = Math.min(1, scale); + textRef.current.setAttribute("y", String(Math.min(TOP_PADDING + PADDING, height) / 2 / scale)); + textRef.current.setAttribute("x", String(width / 2 / scale)); + } + else { + scale = Math.min((width * 0.9) / textRectRef.current.width, (height * 0.9) / textRectRef.current.height); + scale = Math.min(1, scale); + textRef.current.setAttribute("y", String(height / 2 / scale)); + textRef.current.setAttribute("x", String(width / 2 / scale)); + } + textRef.current.setAttribute("transform", `scale(${scale.toFixed(2)})`); + }, [children, height, width]); + if (width == 0 || height == 0) { + return null; + } + return (u$1("g", { className: "node", transform: `translate(${x0},${y0})`, onClick: (event) => { + event.stopPropagation(); + onClick(node); + }, onMouseOver: (event) => { + event.stopPropagation(); + onMouseOver(node); + }, children: [u$1("rect", { fill: backgroundColor, rx: 2, ry: 2, width: x1 - x0, height: y1 - y0, stroke: selected ? "#fff" : undefined, "stroke-width": selected ? 2 : undefined }), u$1("text", Object.assign({ ref: textRef, fill: fontColor, onClick: (event) => { + var _a; + if (((_a = window.getSelection()) === null || _a === void 0 ? void 0 : _a.toString()) !== "") { + event.stopPropagation(); + } + } }, textProps, { children: data.name }))] })); + }; + + const TreeMap = ({ root, onNodeHover, selectedNode, onNodeClick, }) => { + const { width, height, getModuleIds } = q(StaticContext); + console.time("layering"); + // this will make groups by height + const nestedData = F(() => { + const nestedDataMap = group(root.descendants(), (d) => d.height); + const nestedData = Array.from(nestedDataMap, ([key, values]) => ({ + key, + values, + })); + nestedData.sort((a, b) => b.key - a.key); + return nestedData; + }, [root]); + console.timeEnd("layering"); + return (u$1("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: `0 0 ${width} ${height}`, children: nestedData.map(({ key, values }) => { + return (u$1("g", { className: "layer", children: values.map((node) => { + return (u$1(Node, { node: node, onMouseOver: onNodeHover, selected: selectedNode === node, onClick: onNodeClick }, getModuleIds(node.data).nodeUid.id)); + }) }, key)); + }) })); + }; + + var bytes$1 = {exports: {}}; + + /*! + * bytes + * Copyright(c) 2012-2014 TJ Holowaychuk + * Copyright(c) 2015 Jed Watson + * MIT Licensed + */ + + /** + * Module exports. + * @public + */ + + bytes$1.exports = bytes; + var format_1 = bytes$1.exports.format = format$1; + bytes$1.exports.parse = parse; + + /** + * Module variables. + * @private + */ + + var formatThousandsRegExp = /\B(?=(\d{3})+(?!\d))/g; + + var formatDecimalsRegExp = /(?:\.0*|(\.[^0]+)0+)$/; + + var map$1 = { + b: 1, + kb: 1 << 10, + mb: 1 << 20, + gb: 1 << 30, + tb: Math.pow(1024, 4), + pb: Math.pow(1024, 5), + }; + + var parseRegExp = /^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb|pb)$/i; + + /** + * Convert the given value in bytes into a string or parse to string to an integer in bytes. + * + * @param {string|number} value + * @param {{ + * case: [string], + * decimalPlaces: [number] + * fixedDecimals: [boolean] + * thousandsSeparator: [string] + * unitSeparator: [string] + * }} [options] bytes options. + * + * @returns {string|number|null} + */ + + function bytes(value, options) { + if (typeof value === 'string') { + return parse(value); + } + + if (typeof value === 'number') { + return format$1(value, options); + } + + return null; + } + + /** + * Format the given value in bytes into a string. + * + * If the value is negative, it is kept as such. If it is a float, + * it is rounded. + * + * @param {number} value + * @param {object} [options] + * @param {number} [options.decimalPlaces=2] + * @param {number} [options.fixedDecimals=false] + * @param {string} [options.thousandsSeparator=] + * @param {string} [options.unit=] + * @param {string} [options.unitSeparator=] + * + * @returns {string|null} + * @public + */ + + function format$1(value, options) { + if (!Number.isFinite(value)) { + return null; + } + + var mag = Math.abs(value); + var thousandsSeparator = (options && options.thousandsSeparator) || ''; + var unitSeparator = (options && options.unitSeparator) || ''; + var decimalPlaces = (options && options.decimalPlaces !== undefined) ? options.decimalPlaces : 2; + var fixedDecimals = Boolean(options && options.fixedDecimals); + var unit = (options && options.unit) || ''; + + if (!unit || !map$1[unit.toLowerCase()]) { + if (mag >= map$1.pb) { + unit = 'PB'; + } else if (mag >= map$1.tb) { + unit = 'TB'; + } else if (mag >= map$1.gb) { + unit = 'GB'; + } else if (mag >= map$1.mb) { + unit = 'MB'; + } else if (mag >= map$1.kb) { + unit = 'KB'; + } else { + unit = 'B'; + } + } + + var val = value / map$1[unit.toLowerCase()]; + var str = val.toFixed(decimalPlaces); + + if (!fixedDecimals) { + str = str.replace(formatDecimalsRegExp, '$1'); + } + + if (thousandsSeparator) { + str = str.split('.').map(function (s, i) { + return i === 0 + ? s.replace(formatThousandsRegExp, thousandsSeparator) + : s + }).join('.'); + } + + return str + unitSeparator + unit; + } + + /** + * Parse the string value into an integer in bytes. + * + * If no unit is given, it is assumed the value is in bytes. + * + * @param {number|string} val + * + * @returns {number|null} + * @public + */ + + function parse(val) { + if (typeof val === 'number' && !isNaN(val)) { + return val; + } + + if (typeof val !== 'string') { + return null; + } + + // Test if the string passed is valid + var results = parseRegExp.exec(val); + var floatValue; + var unit = 'b'; + + if (!results) { + // Nothing could be extracted from the given string + floatValue = parseInt(val, 10); + unit = 'b'; + } else { + // Retrieve the value and the unit + floatValue = parseFloat(results[1]); + unit = results[4].toLowerCase(); + } + + if (isNaN(floatValue)) { + return null; + } + + return Math.floor(map$1[unit] * floatValue); + } + + const Tooltip_marginX = 10; + const Tooltip_marginY = 30; + const SOURCEMAP_RENDERED = (u$1("span", { children: [" ", u$1("b", { children: LABELS.renderedLength }), " is a number of characters in the file after individual and ", u$1("br", {}), " ", "whole bundle transformations according to sourcemap."] })); + const RENDRED = (u$1("span", { children: [u$1("b", { children: LABELS.renderedLength }), " is a byte size of individual file after transformations and treeshake."] })); + const COMPRESSED = (u$1("span", { children: [u$1("b", { children: LABELS.gzipLength }), " and ", u$1("b", { children: LABELS.brotliLength }), " is a byte size of individual file after individual transformations,", u$1("br", {}), " treeshake and compression."] })); + const Tooltip = ({ node, visible, root, sizeProperty, }) => { + const { availableSizeProperties, getModuleSize, data } = q(StaticContext); + const ref = _(null); + const [style, setStyle] = h({}); + const content = F(() => { + if (!node) + return null; + const mainSize = getModuleSize(node.data, sizeProperty); + const percentageNum = (100 * mainSize) / getModuleSize(root.data, sizeProperty); + const percentage = percentageNum.toFixed(2); + const percentageString = percentage + "%"; + const path = node + .ancestors() + .reverse() + .map((d) => d.data.name) + .join("/"); + let dataNode = null; + if (!isModuleTree(node.data)) { + const mainUid = data.nodeParts[node.data.uid].metaUid; + dataNode = data.nodeMetas[mainUid]; + } + return (u$1(g$1, { children: [u$1("div", { children: path }), availableSizeProperties.map((sizeProp) => { + if (sizeProp === sizeProperty) { + return (u$1("div", { children: [u$1("b", { children: [LABELS[sizeProp], ": ", format_1(mainSize)] }), " ", "(", percentageString, ")"] }, sizeProp)); + } + else { + return (u$1("div", { children: [LABELS[sizeProp], ": ", format_1(getModuleSize(node.data, sizeProp))] }, sizeProp)); + } + }), u$1("br", {}), dataNode && dataNode.importedBy.length > 0 && (u$1("div", { children: [u$1("div", { children: [u$1("b", { children: "Imported By" }), ":"] }), dataNode.importedBy.map(({ uid }) => { + const id = data.nodeMetas[uid].id; + return u$1("div", { children: id }, id); + })] })), u$1("br", {}), u$1("small", { children: data.options.sourcemap ? SOURCEMAP_RENDERED : RENDRED }), (data.options.gzip || data.options.brotli) && (u$1(g$1, { children: [u$1("br", {}), u$1("small", { children: COMPRESSED })] }))] })); + }, [availableSizeProperties, data, getModuleSize, node, root.data, sizeProperty]); + const updatePosition = (mouseCoords) => { + if (!ref.current) + return; + const pos = { + left: mouseCoords.x + Tooltip_marginX, + top: mouseCoords.y + Tooltip_marginY, + }; + const boundingRect = ref.current.getBoundingClientRect(); + if (pos.left + boundingRect.width > window.innerWidth) { + // Shifting horizontally + pos.left = window.innerWidth - boundingRect.width; + } + if (pos.top + boundingRect.height > window.innerHeight) { + // Flipping vertically + pos.top = mouseCoords.y - Tooltip_marginY - boundingRect.height; + } + setStyle(pos); + }; + p(() => { + const handleMouseMove = (event) => { + updatePosition({ + x: event.pageX, + y: event.pageY, + }); + }; + document.addEventListener("mousemove", handleMouseMove, true); + return () => { + document.removeEventListener("mousemove", handleMouseMove, true); + }; + }, []); + return (u$1("div", { className: `tooltip ${visible ? "" : "tooltip-hidden"}`, ref: ref, style: style, children: content })); + }; + + const Chart = ({ root, sizeProperty, selectedNode, setSelectedNode, }) => { + const [showTooltip, setShowTooltip] = h(false); + const [tooltipNode, setTooltipNode] = h(undefined); + p(() => { + const handleMouseOut = () => { + setShowTooltip(false); + }; + document.addEventListener("mouseover", handleMouseOut); + return () => { + document.removeEventListener("mouseover", handleMouseOut); + }; + }, []); + return (u$1(g$1, { children: [u$1(TreeMap, { root: root, onNodeHover: (node) => { + setTooltipNode(node); + setShowTooltip(true); + }, selectedNode: selectedNode, onNodeClick: (node) => { + setSelectedNode(selectedNode === node ? undefined : node); + } }), u$1(Tooltip, { visible: showTooltip, node: tooltipNode, root: root, sizeProperty: sizeProperty })] })); + }; + + const Main = () => { + const { availableSizeProperties, rawHierarchy, getModuleSize, layout, data } = q(StaticContext); + const [sizeProperty, setSizeProperty] = h(availableSizeProperties[0]); + const [selectedNode, setSelectedNode] = h(undefined); + const { getModuleFilterMultiplier, setExcludeFilter, setIncludeFilter } = useFilter(); + console.time("getNodeSizeMultiplier"); + const getNodeSizeMultiplier = F(() => { + const selectedMultiplier = 1; // selectedSize < rootSize * increaseFactor ? (rootSize * increaseFactor) / selectedSize : rootSize / selectedSize; + const nonSelectedMultiplier = 0; // 1 / selectedMultiplier + if (selectedNode === undefined) { + return () => 1; + } + else if (isModuleTree(selectedNode.data)) { + const leaves = new Set(selectedNode.leaves().map((d) => d.data)); + return (node) => { + if (leaves.has(node)) { + return selectedMultiplier; + } + return nonSelectedMultiplier; + }; + } + else { + return (node) => { + if (node === selectedNode.data) { + return selectedMultiplier; + } + return nonSelectedMultiplier; + }; + } + }, [getModuleSize, rawHierarchy.data, selectedNode, sizeProperty]); + console.timeEnd("getNodeSizeMultiplier"); + console.time("root hierarchy compute"); + // root here always be the same as rawHierarchy even after layouting + const root = F(() => { + const rootWithSizesAndSorted = rawHierarchy + .sum((node) => { + var _a; + if (isModuleTree(node)) + return 0; + const meta = data.nodeMetas[data.nodeParts[node.uid].metaUid]; + const bundleId = (_a = Object.entries(meta.moduleParts).find(([bundleId, uid]) => uid == node.uid)) === null || _a === void 0 ? void 0 : _a[0]; + const ownSize = getModuleSize(node, sizeProperty); + const zoomMultiplier = getNodeSizeMultiplier(node); + const filterMultiplier = getModuleFilterMultiplier(bundleId, meta); + return ownSize * zoomMultiplier * filterMultiplier; + }) + .sort((a, b) => getModuleSize(a.data, sizeProperty) - getModuleSize(b.data, sizeProperty)); + return layout(rootWithSizesAndSorted); + }, [ + data, + getModuleFilterMultiplier, + getModuleSize, + getNodeSizeMultiplier, + layout, + rawHierarchy, + sizeProperty, + ]); + console.timeEnd("root hierarchy compute"); + return (u$1(g$1, { children: [u$1(SideBar, { sizeProperty: sizeProperty, availableSizeProperties: availableSizeProperties, setSizeProperty: setSizeProperty, onExcludeChange: setExcludeFilter, onIncludeChange: setIncludeFilter }), u$1(Chart, { root: root, sizeProperty: sizeProperty, selectedNode: selectedNode, setSelectedNode: setSelectedNode })] })); + }; + + function initRange(domain, range) { + switch (arguments.length) { + case 0: break; + case 1: this.range(domain); break; + default: this.range(range).domain(domain); break; + } + return this; + } + + function initInterpolator(domain, interpolator) { + switch (arguments.length) { + case 0: break; + case 1: { + if (typeof domain === "function") this.interpolator(domain); + else this.range(domain); + break; + } + default: { + this.domain(domain); + if (typeof interpolator === "function") this.interpolator(interpolator); + else this.range(interpolator); + break; + } + } + return this; + } + + function define(constructor, factory, prototype) { + constructor.prototype = factory.prototype = prototype; + prototype.constructor = constructor; + } + + function extend(parent, definition) { + var prototype = Object.create(parent.prototype); + for (var key in definition) prototype[key] = definition[key]; + return prototype; + } + + function Color() {} + + var darker = 0.7; + var brighter = 1 / darker; + + var reI = "\\s*([+-]?\\d+)\\s*", + reN = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*", + reP = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*", + reHex = /^#([0-9a-f]{3,8})$/, + reRgbInteger = new RegExp(`^rgb\\(${reI},${reI},${reI}\\)$`), + reRgbPercent = new RegExp(`^rgb\\(${reP},${reP},${reP}\\)$`), + reRgbaInteger = new RegExp(`^rgba\\(${reI},${reI},${reI},${reN}\\)$`), + reRgbaPercent = new RegExp(`^rgba\\(${reP},${reP},${reP},${reN}\\)$`), + reHslPercent = new RegExp(`^hsl\\(${reN},${reP},${reP}\\)$`), + reHslaPercent = new RegExp(`^hsla\\(${reN},${reP},${reP},${reN}\\)$`); + + var named = { + aliceblue: 0xf0f8ff, + antiquewhite: 0xfaebd7, + aqua: 0x00ffff, + aquamarine: 0x7fffd4, + azure: 0xf0ffff, + beige: 0xf5f5dc, + bisque: 0xffe4c4, + black: 0x000000, + blanchedalmond: 0xffebcd, + blue: 0x0000ff, + blueviolet: 0x8a2be2, + brown: 0xa52a2a, + burlywood: 0xdeb887, + cadetblue: 0x5f9ea0, + chartreuse: 0x7fff00, + chocolate: 0xd2691e, + coral: 0xff7f50, + cornflowerblue: 0x6495ed, + cornsilk: 0xfff8dc, + crimson: 0xdc143c, + cyan: 0x00ffff, + darkblue: 0x00008b, + darkcyan: 0x008b8b, + darkgoldenrod: 0xb8860b, + darkgray: 0xa9a9a9, + darkgreen: 0x006400, + darkgrey: 0xa9a9a9, + darkkhaki: 0xbdb76b, + darkmagenta: 0x8b008b, + darkolivegreen: 0x556b2f, + darkorange: 0xff8c00, + darkorchid: 0x9932cc, + darkred: 0x8b0000, + darksalmon: 0xe9967a, + darkseagreen: 0x8fbc8f, + darkslateblue: 0x483d8b, + darkslategray: 0x2f4f4f, + darkslategrey: 0x2f4f4f, + darkturquoise: 0x00ced1, + darkviolet: 0x9400d3, + deeppink: 0xff1493, + deepskyblue: 0x00bfff, + dimgray: 0x696969, + dimgrey: 0x696969, + dodgerblue: 0x1e90ff, + firebrick: 0xb22222, + floralwhite: 0xfffaf0, + forestgreen: 0x228b22, + fuchsia: 0xff00ff, + gainsboro: 0xdcdcdc, + ghostwhite: 0xf8f8ff, + gold: 0xffd700, + goldenrod: 0xdaa520, + gray: 0x808080, + green: 0x008000, + greenyellow: 0xadff2f, + grey: 0x808080, + honeydew: 0xf0fff0, + hotpink: 0xff69b4, + indianred: 0xcd5c5c, + indigo: 0x4b0082, + ivory: 0xfffff0, + khaki: 0xf0e68c, + lavender: 0xe6e6fa, + lavenderblush: 0xfff0f5, + lawngreen: 0x7cfc00, + lemonchiffon: 0xfffacd, + lightblue: 0xadd8e6, + lightcoral: 0xf08080, + lightcyan: 0xe0ffff, + lightgoldenrodyellow: 0xfafad2, + lightgray: 0xd3d3d3, + lightgreen: 0x90ee90, + lightgrey: 0xd3d3d3, + lightpink: 0xffb6c1, + lightsalmon: 0xffa07a, + lightseagreen: 0x20b2aa, + lightskyblue: 0x87cefa, + lightslategray: 0x778899, + lightslategrey: 0x778899, + lightsteelblue: 0xb0c4de, + lightyellow: 0xffffe0, + lime: 0x00ff00, + limegreen: 0x32cd32, + linen: 0xfaf0e6, + magenta: 0xff00ff, + maroon: 0x800000, + mediumaquamarine: 0x66cdaa, + mediumblue: 0x0000cd, + mediumorchid: 0xba55d3, + mediumpurple: 0x9370db, + mediumseagreen: 0x3cb371, + mediumslateblue: 0x7b68ee, + mediumspringgreen: 0x00fa9a, + mediumturquoise: 0x48d1cc, + mediumvioletred: 0xc71585, + midnightblue: 0x191970, + mintcream: 0xf5fffa, + mistyrose: 0xffe4e1, + moccasin: 0xffe4b5, + navajowhite: 0xffdead, + navy: 0x000080, + oldlace: 0xfdf5e6, + olive: 0x808000, + olivedrab: 0x6b8e23, + orange: 0xffa500, + orangered: 0xff4500, + orchid: 0xda70d6, + palegoldenrod: 0xeee8aa, + palegreen: 0x98fb98, + paleturquoise: 0xafeeee, + palevioletred: 0xdb7093, + papayawhip: 0xffefd5, + peachpuff: 0xffdab9, + peru: 0xcd853f, + pink: 0xffc0cb, + plum: 0xdda0dd, + powderblue: 0xb0e0e6, + purple: 0x800080, + rebeccapurple: 0x663399, + red: 0xff0000, + rosybrown: 0xbc8f8f, + royalblue: 0x4169e1, + saddlebrown: 0x8b4513, + salmon: 0xfa8072, + sandybrown: 0xf4a460, + seagreen: 0x2e8b57, + seashell: 0xfff5ee, + sienna: 0xa0522d, + silver: 0xc0c0c0, + skyblue: 0x87ceeb, + slateblue: 0x6a5acd, + slategray: 0x708090, + slategrey: 0x708090, + snow: 0xfffafa, + springgreen: 0x00ff7f, + steelblue: 0x4682b4, + tan: 0xd2b48c, + teal: 0x008080, + thistle: 0xd8bfd8, + tomato: 0xff6347, + turquoise: 0x40e0d0, + violet: 0xee82ee, + wheat: 0xf5deb3, + white: 0xffffff, + whitesmoke: 0xf5f5f5, + yellow: 0xffff00, + yellowgreen: 0x9acd32 + }; + + define(Color, color, { + copy(channels) { + return Object.assign(new this.constructor, this, channels); + }, + displayable() { + return this.rgb().displayable(); + }, + hex: color_formatHex, // Deprecated! Use color.formatHex. + formatHex: color_formatHex, + formatHex8: color_formatHex8, + formatHsl: color_formatHsl, + formatRgb: color_formatRgb, + toString: color_formatRgb + }); + + function color_formatHex() { + return this.rgb().formatHex(); + } + + function color_formatHex8() { + return this.rgb().formatHex8(); + } + + function color_formatHsl() { + return hslConvert(this).formatHsl(); + } + + function color_formatRgb() { + return this.rgb().formatRgb(); + } + + function color(format) { + var m, l; + format = (format + "").trim().toLowerCase(); + return (m = reHex.exec(format)) ? (l = m[1].length, m = parseInt(m[1], 16), l === 6 ? rgbn(m) // #ff0000 + : l === 3 ? new Rgb((m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), ((m & 0xf) << 4) | (m & 0xf), 1) // #f00 + : l === 8 ? rgba(m >> 24 & 0xff, m >> 16 & 0xff, m >> 8 & 0xff, (m & 0xff) / 0xff) // #ff000000 + : l === 4 ? rgba((m >> 12 & 0xf) | (m >> 8 & 0xf0), (m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), (((m & 0xf) << 4) | (m & 0xf)) / 0xff) // #f000 + : null) // invalid hex + : (m = reRgbInteger.exec(format)) ? new Rgb(m[1], m[2], m[3], 1) // rgb(255, 0, 0) + : (m = reRgbPercent.exec(format)) ? new Rgb(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, 1) // rgb(100%, 0%, 0%) + : (m = reRgbaInteger.exec(format)) ? rgba(m[1], m[2], m[3], m[4]) // rgba(255, 0, 0, 1) + : (m = reRgbaPercent.exec(format)) ? rgba(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, m[4]) // rgb(100%, 0%, 0%, 1) + : (m = reHslPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, 1) // hsl(120, 50%, 50%) + : (m = reHslaPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, m[4]) // hsla(120, 50%, 50%, 1) + : named.hasOwnProperty(format) ? rgbn(named[format]) // eslint-disable-line no-prototype-builtins + : format === "transparent" ? new Rgb(NaN, NaN, NaN, 0) + : null; + } + + function rgbn(n) { + return new Rgb(n >> 16 & 0xff, n >> 8 & 0xff, n & 0xff, 1); + } + + function rgba(r, g, b, a) { + if (a <= 0) r = g = b = NaN; + return new Rgb(r, g, b, a); + } + + function rgbConvert(o) { + if (!(o instanceof Color)) o = color(o); + if (!o) return new Rgb; + o = o.rgb(); + return new Rgb(o.r, o.g, o.b, o.opacity); + } + + function rgb$1(r, g, b, opacity) { + return arguments.length === 1 ? rgbConvert(r) : new Rgb(r, g, b, opacity == null ? 1 : opacity); + } + + function Rgb(r, g, b, opacity) { + this.r = +r; + this.g = +g; + this.b = +b; + this.opacity = +opacity; + } + + define(Rgb, rgb$1, extend(Color, { + brighter(k) { + k = k == null ? brighter : Math.pow(brighter, k); + return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity); + }, + darker(k) { + k = k == null ? darker : Math.pow(darker, k); + return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity); + }, + rgb() { + return this; + }, + clamp() { + return new Rgb(clampi(this.r), clampi(this.g), clampi(this.b), clampa(this.opacity)); + }, + displayable() { + return (-0.5 <= this.r && this.r < 255.5) + && (-0.5 <= this.g && this.g < 255.5) + && (-0.5 <= this.b && this.b < 255.5) + && (0 <= this.opacity && this.opacity <= 1); + }, + hex: rgb_formatHex, // Deprecated! Use color.formatHex. + formatHex: rgb_formatHex, + formatHex8: rgb_formatHex8, + formatRgb: rgb_formatRgb, + toString: rgb_formatRgb + })); + + function rgb_formatHex() { + return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}`; + } + + function rgb_formatHex8() { + return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}${hex((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`; + } + + function rgb_formatRgb() { + const a = clampa(this.opacity); + return `${a === 1 ? "rgb(" : "rgba("}${clampi(this.r)}, ${clampi(this.g)}, ${clampi(this.b)}${a === 1 ? ")" : `, ${a})`}`; + } + + function clampa(opacity) { + return isNaN(opacity) ? 1 : Math.max(0, Math.min(1, opacity)); + } + + function clampi(value) { + return Math.max(0, Math.min(255, Math.round(value) || 0)); + } + + function hex(value) { + value = clampi(value); + return (value < 16 ? "0" : "") + value.toString(16); + } + + function hsla(h, s, l, a) { + if (a <= 0) h = s = l = NaN; + else if (l <= 0 || l >= 1) h = s = NaN; + else if (s <= 0) h = NaN; + return new Hsl(h, s, l, a); + } + + function hslConvert(o) { + if (o instanceof Hsl) return new Hsl(o.h, o.s, o.l, o.opacity); + if (!(o instanceof Color)) o = color(o); + if (!o) return new Hsl; + if (o instanceof Hsl) return o; + o = o.rgb(); + var r = o.r / 255, + g = o.g / 255, + b = o.b / 255, + min = Math.min(r, g, b), + max = Math.max(r, g, b), + h = NaN, + s = max - min, + l = (max + min) / 2; + if (s) { + if (r === max) h = (g - b) / s + (g < b) * 6; + else if (g === max) h = (b - r) / s + 2; + else h = (r - g) / s + 4; + s /= l < 0.5 ? max + min : 2 - max - min; + h *= 60; + } else { + s = l > 0 && l < 1 ? 0 : h; + } + return new Hsl(h, s, l, o.opacity); + } + + function hsl(h, s, l, opacity) { + return arguments.length === 1 ? hslConvert(h) : new Hsl(h, s, l, opacity == null ? 1 : opacity); + } + + function Hsl(h, s, l, opacity) { + this.h = +h; + this.s = +s; + this.l = +l; + this.opacity = +opacity; + } + + define(Hsl, hsl, extend(Color, { + brighter(k) { + k = k == null ? brighter : Math.pow(brighter, k); + return new Hsl(this.h, this.s, this.l * k, this.opacity); + }, + darker(k) { + k = k == null ? darker : Math.pow(darker, k); + return new Hsl(this.h, this.s, this.l * k, this.opacity); + }, + rgb() { + var h = this.h % 360 + (this.h < 0) * 360, + s = isNaN(h) || isNaN(this.s) ? 0 : this.s, + l = this.l, + m2 = l + (l < 0.5 ? l : 1 - l) * s, + m1 = 2 * l - m2; + return new Rgb( + hsl2rgb(h >= 240 ? h - 240 : h + 120, m1, m2), + hsl2rgb(h, m1, m2), + hsl2rgb(h < 120 ? h + 240 : h - 120, m1, m2), + this.opacity + ); + }, + clamp() { + return new Hsl(clamph(this.h), clampt(this.s), clampt(this.l), clampa(this.opacity)); + }, + displayable() { + return (0 <= this.s && this.s <= 1 || isNaN(this.s)) + && (0 <= this.l && this.l <= 1) + && (0 <= this.opacity && this.opacity <= 1); + }, + formatHsl() { + const a = clampa(this.opacity); + return `${a === 1 ? "hsl(" : "hsla("}${clamph(this.h)}, ${clampt(this.s) * 100}%, ${clampt(this.l) * 100}%${a === 1 ? ")" : `, ${a})`}`; + } + })); + + function clamph(value) { + value = (value || 0) % 360; + return value < 0 ? value + 360 : value; + } + + function clampt(value) { + return Math.max(0, Math.min(1, value || 0)); + } + + /* From FvD 13.37, CSS Color Module Level 3 */ + function hsl2rgb(h, m1, m2) { + return (h < 60 ? m1 + (m2 - m1) * h / 60 + : h < 180 ? m2 + : h < 240 ? m1 + (m2 - m1) * (240 - h) / 60 + : m1) * 255; + } + + var constant = x => () => x; + + function linear$1(a, d) { + return function(t) { + return a + t * d; + }; + } + + function exponential(a, b, y) { + return a = Math.pow(a, y), b = Math.pow(b, y) - a, y = 1 / y, function(t) { + return Math.pow(a + t * b, y); + }; + } + + function gamma(y) { + return (y = +y) === 1 ? nogamma : function(a, b) { + return b - a ? exponential(a, b, y) : constant(isNaN(a) ? b : a); + }; + } + + function nogamma(a, b) { + var d = b - a; + return d ? linear$1(a, d) : constant(isNaN(a) ? b : a); + } + + var rgb = (function rgbGamma(y) { + var color = gamma(y); + + function rgb(start, end) { + var r = color((start = rgb$1(start)).r, (end = rgb$1(end)).r), + g = color(start.g, end.g), + b = color(start.b, end.b), + opacity = nogamma(start.opacity, end.opacity); + return function(t) { + start.r = r(t); + start.g = g(t); + start.b = b(t); + start.opacity = opacity(t); + return start + ""; + }; + } + + rgb.gamma = rgbGamma; + + return rgb; + })(1); + + function numberArray(a, b) { + if (!b) b = []; + var n = a ? Math.min(b.length, a.length) : 0, + c = b.slice(), + i; + return function(t) { + for (i = 0; i < n; ++i) c[i] = a[i] * (1 - t) + b[i] * t; + return c; + }; + } + + function isNumberArray(x) { + return ArrayBuffer.isView(x) && !(x instanceof DataView); + } + + function genericArray(a, b) { + var nb = b ? b.length : 0, + na = a ? Math.min(nb, a.length) : 0, + x = new Array(na), + c = new Array(nb), + i; + + for (i = 0; i < na; ++i) x[i] = interpolate(a[i], b[i]); + for (; i < nb; ++i) c[i] = b[i]; + + return function(t) { + for (i = 0; i < na; ++i) c[i] = x[i](t); + return c; + }; + } + + function date(a, b) { + var d = new Date; + return a = +a, b = +b, function(t) { + return d.setTime(a * (1 - t) + b * t), d; + }; + } + + function interpolateNumber(a, b) { + return a = +a, b = +b, function(t) { + return a * (1 - t) + b * t; + }; + } + + function object(a, b) { + var i = {}, + c = {}, + k; + + if (a === null || typeof a !== "object") a = {}; + if (b === null || typeof b !== "object") b = {}; + + for (k in b) { + if (k in a) { + i[k] = interpolate(a[k], b[k]); + } else { + c[k] = b[k]; + } + } + + return function(t) { + for (k in i) c[k] = i[k](t); + return c; + }; + } + + var reA = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, + reB = new RegExp(reA.source, "g"); + + function zero(b) { + return function() { + return b; + }; + } + + function one(b) { + return function(t) { + return b(t) + ""; + }; + } + + function string(a, b) { + var bi = reA.lastIndex = reB.lastIndex = 0, // scan index for next number in b + am, // current match in a + bm, // current match in b + bs, // string preceding current number in b, if any + i = -1, // index in s + s = [], // string constants and placeholders + q = []; // number interpolators + + // Coerce inputs to strings. + a = a + "", b = b + ""; + + // Interpolate pairs of numbers in a & b. + while ((am = reA.exec(a)) + && (bm = reB.exec(b))) { + if ((bs = bm.index) > bi) { // a string precedes the next number in b + bs = b.slice(bi, bs); + if (s[i]) s[i] += bs; // coalesce with previous string + else s[++i] = bs; + } + if ((am = am[0]) === (bm = bm[0])) { // numbers in a & b match + if (s[i]) s[i] += bm; // coalesce with previous string + else s[++i] = bm; + } else { // interpolate non-matching numbers + s[++i] = null; + q.push({i: i, x: interpolateNumber(am, bm)}); + } + bi = reB.lastIndex; + } + + // Add remains of b. + if (bi < b.length) { + bs = b.slice(bi); + if (s[i]) s[i] += bs; // coalesce with previous string + else s[++i] = bs; + } + + // Special optimization for only a single match. + // Otherwise, interpolate each of the numbers and rejoin the string. + return s.length < 2 ? (q[0] + ? one(q[0].x) + : zero(b)) + : (b = q.length, function(t) { + for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t); + return s.join(""); + }); + } + + function interpolate(a, b) { + var t = typeof b, c; + return b == null || t === "boolean" ? constant(b) + : (t === "number" ? interpolateNumber + : t === "string" ? ((c = color(b)) ? (b = c, rgb) : string) + : b instanceof color ? rgb + : b instanceof Date ? date + : isNumberArray(b) ? numberArray + : Array.isArray(b) ? genericArray + : typeof b.valueOf !== "function" && typeof b.toString !== "function" || isNaN(b) ? object + : interpolateNumber)(a, b); + } + + function interpolateRound(a, b) { + return a = +a, b = +b, function(t) { + return Math.round(a * (1 - t) + b * t); + }; + } + + function constants(x) { + return function() { + return x; + }; + } + + function number(x) { + return +x; + } + + var unit = [0, 1]; + + function identity$1(x) { + return x; + } + + function normalize(a, b) { + return (b -= (a = +a)) + ? function(x) { return (x - a) / b; } + : constants(isNaN(b) ? NaN : 0.5); + } + + function clamper(a, b) { + var t; + if (a > b) t = a, a = b, b = t; + return function(x) { return Math.max(a, Math.min(b, x)); }; + } + + // normalize(a, b)(x) takes a domain value x in [a,b] and returns the corresponding parameter t in [0,1]. + // interpolate(a, b)(t) takes a parameter t in [0,1] and returns the corresponding range value x in [a,b]. + function bimap(domain, range, interpolate) { + var d0 = domain[0], d1 = domain[1], r0 = range[0], r1 = range[1]; + if (d1 < d0) d0 = normalize(d1, d0), r0 = interpolate(r1, r0); + else d0 = normalize(d0, d1), r0 = interpolate(r0, r1); + return function(x) { return r0(d0(x)); }; + } + + function polymap(domain, range, interpolate) { + var j = Math.min(domain.length, range.length) - 1, + d = new Array(j), + r = new Array(j), + i = -1; + + // Reverse descending domains. + if (domain[j] < domain[0]) { + domain = domain.slice().reverse(); + range = range.slice().reverse(); + } + + while (++i < j) { + d[i] = normalize(domain[i], domain[i + 1]); + r[i] = interpolate(range[i], range[i + 1]); + } + + return function(x) { + var i = bisect(domain, x, 1, j) - 1; + return r[i](d[i](x)); + }; + } + + function copy$1(source, target) { + return target + .domain(source.domain()) + .range(source.range()) + .interpolate(source.interpolate()) + .clamp(source.clamp()) + .unknown(source.unknown()); + } + + function transformer$1() { + var domain = unit, + range = unit, + interpolate$1 = interpolate, + transform, + untransform, + unknown, + clamp = identity$1, + piecewise, + output, + input; + + function rescale() { + var n = Math.min(domain.length, range.length); + if (clamp !== identity$1) clamp = clamper(domain[0], domain[n - 1]); + piecewise = n > 2 ? polymap : bimap; + output = input = null; + return scale; + } + + function scale(x) { + return x == null || isNaN(x = +x) ? unknown : (output || (output = piecewise(domain.map(transform), range, interpolate$1)))(transform(clamp(x))); + } + + scale.invert = function(y) { + return clamp(untransform((input || (input = piecewise(range, domain.map(transform), interpolateNumber)))(y))); + }; + + scale.domain = function(_) { + return arguments.length ? (domain = Array.from(_, number), rescale()) : domain.slice(); + }; + + scale.range = function(_) { + return arguments.length ? (range = Array.from(_), rescale()) : range.slice(); + }; + + scale.rangeRound = function(_) { + return range = Array.from(_), interpolate$1 = interpolateRound, rescale(); + }; + + scale.clamp = function(_) { + return arguments.length ? (clamp = _ ? true : identity$1, rescale()) : clamp !== identity$1; + }; + + scale.interpolate = function(_) { + return arguments.length ? (interpolate$1 = _, rescale()) : interpolate$1; + }; + + scale.unknown = function(_) { + return arguments.length ? (unknown = _, scale) : unknown; + }; + + return function(t, u) { + transform = t, untransform = u; + return rescale(); + }; + } + + function continuous() { + return transformer$1()(identity$1, identity$1); + } + + function formatDecimal(x) { + return Math.abs(x = Math.round(x)) >= 1e21 + ? x.toLocaleString("en").replace(/,/g, "") + : x.toString(10); + } + + // Computes the decimal coefficient and exponent of the specified number x with + // significant digits p, where x is positive and p is in [1, 21] or undefined. + // For example, formatDecimalParts(1.23) returns ["123", 0]. + function formatDecimalParts(x, p) { + if ((i = (x = p ? x.toExponential(p - 1) : x.toExponential()).indexOf("e")) < 0) return null; // NaN, ±Infinity + var i, coefficient = x.slice(0, i); + + // The string returned by toExponential either has the form \d\.\d+e[-+]\d+ + // (e.g., 1.2e+3) or the form \de[-+]\d+ (e.g., 1e+3). + return [ + coefficient.length > 1 ? coefficient[0] + coefficient.slice(2) : coefficient, + +x.slice(i + 1) + ]; + } + + function exponent(x) { + return x = formatDecimalParts(Math.abs(x)), x ? x[1] : NaN; + } + + function formatGroup(grouping, thousands) { + return function(value, width) { + var i = value.length, + t = [], + j = 0, + g = grouping[0], + length = 0; + + while (i > 0 && g > 0) { + if (length + g + 1 > width) g = Math.max(1, width - length); + t.push(value.substring(i -= g, i + g)); + if ((length += g + 1) > width) break; + g = grouping[j = (j + 1) % grouping.length]; + } + + return t.reverse().join(thousands); + }; + } + + function formatNumerals(numerals) { + return function(value) { + return value.replace(/[0-9]/g, function(i) { + return numerals[+i]; + }); + }; + } + + // [[fill]align][sign][symbol][0][width][,][.precision][~][type] + var re = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i; + + function formatSpecifier(specifier) { + if (!(match = re.exec(specifier))) throw new Error("invalid format: " + specifier); + var match; + return new FormatSpecifier({ + fill: match[1], + align: match[2], + sign: match[3], + symbol: match[4], + zero: match[5], + width: match[6], + comma: match[7], + precision: match[8] && match[8].slice(1), + trim: match[9], + type: match[10] + }); + } + + formatSpecifier.prototype = FormatSpecifier.prototype; // instanceof + + function FormatSpecifier(specifier) { + this.fill = specifier.fill === undefined ? " " : specifier.fill + ""; + this.align = specifier.align === undefined ? ">" : specifier.align + ""; + this.sign = specifier.sign === undefined ? "-" : specifier.sign + ""; + this.symbol = specifier.symbol === undefined ? "" : specifier.symbol + ""; + this.zero = !!specifier.zero; + this.width = specifier.width === undefined ? undefined : +specifier.width; + this.comma = !!specifier.comma; + this.precision = specifier.precision === undefined ? undefined : +specifier.precision; + this.trim = !!specifier.trim; + this.type = specifier.type === undefined ? "" : specifier.type + ""; + } + + FormatSpecifier.prototype.toString = function() { + return this.fill + + this.align + + this.sign + + this.symbol + + (this.zero ? "0" : "") + + (this.width === undefined ? "" : Math.max(1, this.width | 0)) + + (this.comma ? "," : "") + + (this.precision === undefined ? "" : "." + Math.max(0, this.precision | 0)) + + (this.trim ? "~" : "") + + this.type; + }; + + // Trims insignificant zeros, e.g., replaces 1.2000k with 1.2k. + function formatTrim(s) { + out: for (var n = s.length, i = 1, i0 = -1, i1; i < n; ++i) { + switch (s[i]) { + case ".": i0 = i1 = i; break; + case "0": if (i0 === 0) i0 = i; i1 = i; break; + default: if (!+s[i]) break out; if (i0 > 0) i0 = 0; break; + } + } + return i0 > 0 ? s.slice(0, i0) + s.slice(i1 + 1) : s; + } + + var prefixExponent; + + function formatPrefixAuto(x, p) { + var d = formatDecimalParts(x, p); + if (!d) return x + ""; + var coefficient = d[0], + exponent = d[1], + i = exponent - (prefixExponent = Math.max(-8, Math.min(8, Math.floor(exponent / 3))) * 3) + 1, + n = coefficient.length; + return i === n ? coefficient + : i > n ? coefficient + new Array(i - n + 1).join("0") + : i > 0 ? coefficient.slice(0, i) + "." + coefficient.slice(i) + : "0." + new Array(1 - i).join("0") + formatDecimalParts(x, Math.max(0, p + i - 1))[0]; // less than 1y! + } + + function formatRounded(x, p) { + var d = formatDecimalParts(x, p); + if (!d) return x + ""; + var coefficient = d[0], + exponent = d[1]; + return exponent < 0 ? "0." + new Array(-exponent).join("0") + coefficient + : coefficient.length > exponent + 1 ? coefficient.slice(0, exponent + 1) + "." + coefficient.slice(exponent + 1) + : coefficient + new Array(exponent - coefficient.length + 2).join("0"); + } + + var formatTypes = { + "%": (x, p) => (x * 100).toFixed(p), + "b": (x) => Math.round(x).toString(2), + "c": (x) => x + "", + "d": formatDecimal, + "e": (x, p) => x.toExponential(p), + "f": (x, p) => x.toFixed(p), + "g": (x, p) => x.toPrecision(p), + "o": (x) => Math.round(x).toString(8), + "p": (x, p) => formatRounded(x * 100, p), + "r": formatRounded, + "s": formatPrefixAuto, + "X": (x) => Math.round(x).toString(16).toUpperCase(), + "x": (x) => Math.round(x).toString(16) + }; + + function identity(x) { + return x; + } + + var map = Array.prototype.map, + prefixes = ["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"]; + + function formatLocale(locale) { + var group = locale.grouping === undefined || locale.thousands === undefined ? identity : formatGroup(map.call(locale.grouping, Number), locale.thousands + ""), + currencyPrefix = locale.currency === undefined ? "" : locale.currency[0] + "", + currencySuffix = locale.currency === undefined ? "" : locale.currency[1] + "", + decimal = locale.decimal === undefined ? "." : locale.decimal + "", + numerals = locale.numerals === undefined ? identity : formatNumerals(map.call(locale.numerals, String)), + percent = locale.percent === undefined ? "%" : locale.percent + "", + minus = locale.minus === undefined ? "−" : locale.minus + "", + nan = locale.nan === undefined ? "NaN" : locale.nan + ""; + + function newFormat(specifier) { + specifier = formatSpecifier(specifier); + + var fill = specifier.fill, + align = specifier.align, + sign = specifier.sign, + symbol = specifier.symbol, + zero = specifier.zero, + width = specifier.width, + comma = specifier.comma, + precision = specifier.precision, + trim = specifier.trim, + type = specifier.type; + + // The "n" type is an alias for ",g". + if (type === "n") comma = true, type = "g"; + + // The "" type, and any invalid type, is an alias for ".12~g". + else if (!formatTypes[type]) precision === undefined && (precision = 12), trim = true, type = "g"; + + // If zero fill is specified, padding goes after sign and before digits. + if (zero || (fill === "0" && align === "=")) zero = true, fill = "0", align = "="; + + // Compute the prefix and suffix. + // For SI-prefix, the suffix is lazily computed. + var prefix = symbol === "$" ? currencyPrefix : symbol === "#" && /[boxX]/.test(type) ? "0" + type.toLowerCase() : "", + suffix = symbol === "$" ? currencySuffix : /[%p]/.test(type) ? percent : ""; + + // What format function should we use? + // Is this an integer type? + // Can this type generate exponential notation? + var formatType = formatTypes[type], + maybeSuffix = /[defgprs%]/.test(type); + + // Set the default precision if not specified, + // or clamp the specified precision to the supported range. + // For significant precision, it must be in [1, 21]. + // For fixed precision, it must be in [0, 20]. + precision = precision === undefined ? 6 + : /[gprs]/.test(type) ? Math.max(1, Math.min(21, precision)) + : Math.max(0, Math.min(20, precision)); + + function format(value) { + var valuePrefix = prefix, + valueSuffix = suffix, + i, n, c; + + if (type === "c") { + valueSuffix = formatType(value) + valueSuffix; + value = ""; + } else { + value = +value; + + // Determine the sign. -0 is not less than 0, but 1 / -0 is! + var valueNegative = value < 0 || 1 / value < 0; + + // Perform the initial formatting. + value = isNaN(value) ? nan : formatType(Math.abs(value), precision); + + // Trim insignificant zeros. + if (trim) value = formatTrim(value); + + // If a negative value rounds to zero after formatting, and no explicit positive sign is requested, hide the sign. + if (valueNegative && +value === 0 && sign !== "+") valueNegative = false; + + // Compute the prefix and suffix. + valuePrefix = (valueNegative ? (sign === "(" ? sign : minus) : sign === "-" || sign === "(" ? "" : sign) + valuePrefix; + valueSuffix = (type === "s" ? prefixes[8 + prefixExponent / 3] : "") + valueSuffix + (valueNegative && sign === "(" ? ")" : ""); + + // Break the formatted value into the integer “value” part that can be + // grouped, and fractional or exponential “suffix” part that is not. + if (maybeSuffix) { + i = -1, n = value.length; + while (++i < n) { + if (c = value.charCodeAt(i), 48 > c || c > 57) { + valueSuffix = (c === 46 ? decimal + value.slice(i + 1) : value.slice(i)) + valueSuffix; + value = value.slice(0, i); + break; + } + } + } + } + + // If the fill character is not "0", grouping is applied before padding. + if (comma && !zero) value = group(value, Infinity); + + // Compute the padding. + var length = valuePrefix.length + value.length + valueSuffix.length, + padding = length < width ? new Array(width - length + 1).join(fill) : ""; + + // If the fill character is "0", grouping is applied after padding. + if (comma && zero) value = group(padding + value, padding.length ? width - valueSuffix.length : Infinity), padding = ""; + + // Reconstruct the final output based on the desired alignment. + switch (align) { + case "<": value = valuePrefix + value + valueSuffix + padding; break; + case "=": value = valuePrefix + padding + value + valueSuffix; break; + case "^": value = padding.slice(0, length = padding.length >> 1) + valuePrefix + value + valueSuffix + padding.slice(length); break; + default: value = padding + valuePrefix + value + valueSuffix; break; + } + + return numerals(value); + } + + format.toString = function() { + return specifier + ""; + }; + + return format; + } + + function formatPrefix(specifier, value) { + var f = newFormat((specifier = formatSpecifier(specifier), specifier.type = "f", specifier)), + e = Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3, + k = Math.pow(10, -e), + prefix = prefixes[8 + e / 3]; + return function(value) { + return f(k * value) + prefix; + }; + } + + return { + format: newFormat, + formatPrefix: formatPrefix + }; + } + + var locale; + var format; + var formatPrefix; + + defaultLocale({ + thousands: ",", + grouping: [3], + currency: ["$", ""] + }); + + function defaultLocale(definition) { + locale = formatLocale(definition); + format = locale.format; + formatPrefix = locale.formatPrefix; + return locale; + } + + function precisionFixed(step) { + return Math.max(0, -exponent(Math.abs(step))); + } + + function precisionPrefix(step, value) { + return Math.max(0, Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3 - exponent(Math.abs(step))); + } + + function precisionRound(step, max) { + step = Math.abs(step), max = Math.abs(max) - step; + return Math.max(0, exponent(max) - exponent(step)) + 1; + } + + function tickFormat(start, stop, count, specifier) { + var step = tickStep(start, stop, count), + precision; + specifier = formatSpecifier(specifier == null ? ",f" : specifier); + switch (specifier.type) { + case "s": { + var value = Math.max(Math.abs(start), Math.abs(stop)); + if (specifier.precision == null && !isNaN(precision = precisionPrefix(step, value))) specifier.precision = precision; + return formatPrefix(specifier, value); + } + case "": + case "e": + case "g": + case "p": + case "r": { + if (specifier.precision == null && !isNaN(precision = precisionRound(step, Math.max(Math.abs(start), Math.abs(stop))))) specifier.precision = precision - (specifier.type === "e"); + break; + } + case "f": + case "%": { + if (specifier.precision == null && !isNaN(precision = precisionFixed(step))) specifier.precision = precision - (specifier.type === "%") * 2; + break; + } + } + return format(specifier); + } + + function linearish(scale) { + var domain = scale.domain; + + scale.ticks = function(count) { + var d = domain(); + return ticks(d[0], d[d.length - 1], count == null ? 10 : count); + }; + + scale.tickFormat = function(count, specifier) { + var d = domain(); + return tickFormat(d[0], d[d.length - 1], count == null ? 10 : count, specifier); + }; + + scale.nice = function(count) { + if (count == null) count = 10; + + var d = domain(); + var i0 = 0; + var i1 = d.length - 1; + var start = d[i0]; + var stop = d[i1]; + var prestep; + var step; + var maxIter = 10; + + if (stop < start) { + step = start, start = stop, stop = step; + step = i0, i0 = i1, i1 = step; + } + + while (maxIter-- > 0) { + step = tickIncrement(start, stop, count); + if (step === prestep) { + d[i0] = start; + d[i1] = stop; + return domain(d); + } else if (step > 0) { + start = Math.floor(start / step) * step; + stop = Math.ceil(stop / step) * step; + } else if (step < 0) { + start = Math.ceil(start * step) / step; + stop = Math.floor(stop * step) / step; + } else { + break; + } + prestep = step; + } + + return scale; + }; + + return scale; + } + + function linear() { + var scale = continuous(); + + scale.copy = function() { + return copy$1(scale, linear()); + }; + + initRange.apply(scale, arguments); + + return linearish(scale); + } + + function transformer() { + var x0 = 0, + x1 = 1, + t0, + t1, + k10, + transform, + interpolator = identity$1, + clamp = false, + unknown; + + function scale(x) { + return x == null || isNaN(x = +x) ? unknown : interpolator(k10 === 0 ? 0.5 : (x = (transform(x) - t0) * k10, clamp ? Math.max(0, Math.min(1, x)) : x)); + } + + scale.domain = function(_) { + return arguments.length ? ([x0, x1] = _, t0 = transform(x0 = +x0), t1 = transform(x1 = +x1), k10 = t0 === t1 ? 0 : 1 / (t1 - t0), scale) : [x0, x1]; + }; + + scale.clamp = function(_) { + return arguments.length ? (clamp = !!_, scale) : clamp; + }; + + scale.interpolator = function(_) { + return arguments.length ? (interpolator = _, scale) : interpolator; + }; + + function range(interpolate) { + return function(_) { + var r0, r1; + return arguments.length ? ([r0, r1] = _, interpolator = interpolate(r0, r1), scale) : [interpolator(0), interpolator(1)]; + }; + } + + scale.range = range(interpolate); + + scale.rangeRound = range(interpolateRound); + + scale.unknown = function(_) { + return arguments.length ? (unknown = _, scale) : unknown; + }; + + return function(t) { + transform = t, t0 = t(x0), t1 = t(x1), k10 = t0 === t1 ? 0 : 1 / (t1 - t0); + return scale; + }; + } + + function copy(source, target) { + return target + .domain(source.domain()) + .interpolator(source.interpolator()) + .clamp(source.clamp()) + .unknown(source.unknown()); + } + + function sequential() { + var scale = linearish(transformer()(identity$1)); + + scale.copy = function() { + return copy(scale, sequential()); + }; + + return initInterpolator.apply(scale, arguments); + } + + const COLOR_BASE = "#cecece"; + + // https://www.w3.org/TR/WCAG20/#relativeluminancedef + const rc = 0.2126; + const gc = 0.7152; + const bc = 0.0722; + // low-gamma adjust coefficient + const lowc = 1 / 12.92; + function adjustGamma(p) { + return Math.pow((p + 0.055) / 1.055, 2.4); + } + function relativeLuminance(o) { + const rsrgb = o.r / 255; + const gsrgb = o.g / 255; + const bsrgb = o.b / 255; + const r = rsrgb <= 0.03928 ? rsrgb * lowc : adjustGamma(rsrgb); + const g = gsrgb <= 0.03928 ? gsrgb * lowc : adjustGamma(gsrgb); + const b = bsrgb <= 0.03928 ? bsrgb * lowc : adjustGamma(bsrgb); + return r * rc + g * gc + b * bc; + } + const createRainbowColor = (root) => { + const colorParentMap = new Map(); + colorParentMap.set(root, COLOR_BASE); + if (root.children != null) { + const colorScale = sequential([0, root.children.length], (n) => hsl(360 * n, 0.3, 0.85)); + root.children.forEach((c, id) => { + colorParentMap.set(c, colorScale(id).toString()); + }); + } + const colorMap = new Map(); + const lightScale = linear().domain([0, root.height]).range([0.9, 0.3]); + const getBackgroundColor = (node) => { + const parents = node.ancestors(); + const colorStr = parents.length === 1 + ? colorParentMap.get(parents[0]) + : colorParentMap.get(parents[parents.length - 2]); + const hslColor = hsl(colorStr); + hslColor.l = lightScale(node.depth); + return hslColor; + }; + return (node) => { + if (!colorMap.has(node)) { + const backgroundColor = getBackgroundColor(node); + const l = relativeLuminance(backgroundColor.rgb()); + const fontColor = l > 0.19 ? "#000" : "#fff"; + colorMap.set(node, { + backgroundColor: backgroundColor.toString(), + fontColor, + }); + } + return colorMap.get(node); + }; + }; + + const StaticContext = F$1({}); + const drawChart = (parentNode, data, width, height) => { + const availableSizeProperties = getAvailableSizeOptions(data.options); + console.time("layout create"); + const layout = treemap() + .size([width, height]) + .paddingOuter(PADDING) + .paddingTop(TOP_PADDING) + .paddingInner(PADDING) + .round(true) + .tile(treemapResquarify); + console.timeEnd("layout create"); + console.time("rawHierarchy create"); + const rawHierarchy = hierarchy(data.tree); + console.timeEnd("rawHierarchy create"); + const nodeSizesCache = new Map(); + const nodeIdsCache = new Map(); + const getModuleSize = (node, sizeKey) => { var _a, _b; return (_b = (_a = nodeSizesCache.get(node)) === null || _a === void 0 ? void 0 : _a[sizeKey]) !== null && _b !== void 0 ? _b : 0; }; + console.time("rawHierarchy eachAfter cache"); + rawHierarchy.eachAfter((node) => { + var _a; + const nodeData = node.data; + nodeIdsCache.set(nodeData, { + nodeUid: generateUniqueId("node"), + clipUid: generateUniqueId("clip"), + }); + const sizes = { renderedLength: 0, gzipLength: 0, brotliLength: 0 }; + if (isModuleTree(nodeData)) { + for (const sizeKey of availableSizeProperties) { + sizes[sizeKey] = nodeData.children.reduce((acc, child) => getModuleSize(child, sizeKey) + acc, 0); + } + } + else { + for (const sizeKey of availableSizeProperties) { + sizes[sizeKey] = (_a = data.nodeParts[nodeData.uid][sizeKey]) !== null && _a !== void 0 ? _a : 0; + } + } + nodeSizesCache.set(nodeData, sizes); + }); + console.timeEnd("rawHierarchy eachAfter cache"); + const getModuleIds = (node) => nodeIdsCache.get(node); + console.time("color"); + const getModuleColor = createRainbowColor(rawHierarchy); + console.timeEnd("color"); + q$1(u$1(StaticContext.Provider, { value: { + data, + availableSizeProperties, + width, + height, + getModuleSize, + getModuleIds, + getModuleColor, + rawHierarchy, + layout, + }, children: u$1(Main, {}) }), parentNode); + }; + + exports.StaticContext = StaticContext; + exports.default = drawChart; + + Object.defineProperty(exports, '__esModule', { value: true }); + + return exports; + +})({}); + + /*-->*/ + </script> + <script> + /*<!--*/ + const data = {"version":2,"tree":{"name":"root","children":[{"name":"browser.js","children":[{"name":"node_modules/@stdlib","children":[{"name":"error-tools-fmtprodmsg/lib/main.js","uid":"6a88f141-1"},{"name":"assert-has-symbol-support/lib/main.js","uid":"6a88f141-3"},{"name":"assert-has-tostringtag-support/lib/main.js","uid":"6a88f141-5"},{"name":"utils-native-class/lib","children":[{"uid":"6a88f141-7","name":"tostring.js"},{"uid":"6a88f141-9","name":"main.js"},{"uid":"6a88f141-15","name":"tostringtag.js"},{"uid":"6a88f141-17","name":"polyfill.js"},{"uid":"6a88f141-19","name":"index.js"}]},{"name":"assert-has-own-property/lib/main.js","uid":"6a88f141-11"},{"name":"symbol-ctor/lib/main.js","uid":"6a88f141-13"},{"name":"assert-is-array/lib/main.js","uid":"6a88f141-21"},{"name":"array-base-assert-is-accessor-array/lib/main.js","uid":"6a88f141-23"},{"name":"array-base-accessor-getter/lib/main.js","uid":"6a88f141-25"},{"name":"array-base-getter/lib/main.js","uid":"6a88f141-27"},{"name":"utils-define-property/lib","children":[{"uid":"6a88f141-29","name":"define_property.js"},{"uid":"6a88f141-31","name":"has_define_property_support.js"},{"uid":"6a88f141-33","name":"builtin.js"},{"uid":"6a88f141-55","name":"polyfill.js"},{"uid":"6a88f141-57","name":"index.js"}]},{"name":"string-base-format-interpolate/lib","children":[{"uid":"6a88f141-35","name":"is_number.js"},{"uid":"6a88f141-37","name":"zero_pad.js"},{"uid":"6a88f141-39","name":"format_integer.js"},{"uid":"6a88f141-41","name":"is_string.js"},{"uid":"6a88f141-43","name":"format_double.js"},{"uid":"6a88f141-45","name":"space_pad.js"},{"uid":"6a88f141-47","name":"main.js"}]},{"name":"string-base-format-tokenize/lib/main.js","uid":"6a88f141-49"},{"name":"string-format/lib","children":[{"uid":"6a88f141-51","name":"is_string.js"},{"uid":"6a88f141-53","name":"main.js"}]},{"name":"utils-define-nonenumerable-read-only-property/lib/main.js","uid":"6a88f141-59"},{"name":"assert-tools-array-function/lib/main.js","uid":"6a88f141-61"},{"name":"assert-is-object-like/lib","children":[{"uid":"6a88f141-63","name":"main.js"},{"uid":"6a88f141-65","name":"index.js"}]},{"name":"assert-is-buffer/lib/main.js","uid":"6a88f141-67"},{"name":"regexp-function-name/lib","children":[{"uid":"6a88f141-69","name":"main.js"},{"uid":"6a88f141-71","name":"regexp.js"},{"uid":"6a88f141-73","name":"index.js"}]},{"name":"utils-constructor-name/lib/main.js","uid":"6a88f141-75"},{"name":"array-dtype/lib","children":[{"uid":"6a88f141-77","name":"ctor2dtype.js"},{"uid":"6a88f141-381","name":"ctors.js"},{"uid":"6a88f141-383","name":"dtypes.js"},{"uid":"6a88f141-385","name":"main.js"}]},{"name":"assert-is-float64array/lib/main.js","uid":"6a88f141-79"},{"name":"assert-has-float64array-support/lib","children":[{"uid":"6a88f141-81","name":"float64array.js"},{"uid":"6a88f141-83","name":"main.js"}]},{"name":"array-float64/lib","children":[{"uid":"6a88f141-85","name":"main.js"},{"uid":"6a88f141-87","name":"polyfill.js"},{"uid":"6a88f141-89","name":"index.js"}]},{"name":"assert-is-float32array/lib/main.js","uid":"6a88f141-91"},{"name":"constants-float64-pinf/lib/index.js","uid":"6a88f141-93"},{"name":"assert-has-float32array-support/lib","children":[{"uid":"6a88f141-95","name":"float32array.js"},{"uid":"6a88f141-97","name":"main.js"}]},{"name":"array-float32/lib","children":[{"uid":"6a88f141-99","name":"main.js"},{"uid":"6a88f141-101","name":"polyfill.js"},{"uid":"6a88f141-103","name":"index.js"}]},{"name":"assert-is-uint32array/lib/main.js","uid":"6a88f141-105"},{"name":"constants-uint32-max/lib/index.js","uid":"6a88f141-107"},{"name":"assert-has-uint32array-support/lib","children":[{"uid":"6a88f141-109","name":"uint32array.js"},{"uid":"6a88f141-111","name":"main.js"}]},{"name":"array-uint32/lib","children":[{"uid":"6a88f141-113","name":"main.js"},{"uid":"6a88f141-115","name":"polyfill.js"},{"uid":"6a88f141-117","name":"index.js"}]},{"name":"assert-is-int32array/lib/main.js","uid":"6a88f141-119"},{"name":"constants-int32-max/lib/index.js","uid":"6a88f141-121"},{"name":"constants-int32-min/lib/index.js","uid":"6a88f141-123"},{"name":"assert-has-int32array-support/lib","children":[{"uid":"6a88f141-125","name":"int32array.js"},{"uid":"6a88f141-127","name":"main.js"}]},{"name":"array-int32/lib","children":[{"uid":"6a88f141-129","name":"main.js"},{"uid":"6a88f141-131","name":"polyfill.js"},{"uid":"6a88f141-133","name":"index.js"}]},{"name":"assert-is-uint16array/lib/main.js","uid":"6a88f141-135"},{"name":"constants-uint16-max/lib/index.js","uid":"6a88f141-137"},{"name":"assert-has-uint16array-support/lib","children":[{"uid":"6a88f141-139","name":"uint16array.js"},{"uid":"6a88f141-141","name":"main.js"}]},{"name":"array-uint16/lib","children":[{"uid":"6a88f141-143","name":"main.js"},{"uid":"6a88f141-145","name":"polyfill.js"},{"uid":"6a88f141-147","name":"index.js"}]},{"name":"assert-is-int16array/lib/main.js","uid":"6a88f141-149"},{"name":"constants-int16-max/lib/index.js","uid":"6a88f141-151"},{"name":"constants-int16-min/lib/index.js","uid":"6a88f141-153"},{"name":"assert-has-int16array-support/lib","children":[{"uid":"6a88f141-155","name":"int16array.js"},{"uid":"6a88f141-157","name":"main.js"}]},{"name":"array-int16/lib","children":[{"uid":"6a88f141-159","name":"main.js"},{"uid":"6a88f141-161","name":"polyfill.js"},{"uid":"6a88f141-163","name":"index.js"}]},{"name":"assert-is-uint8array/lib/main.js","uid":"6a88f141-165"},{"name":"constants-uint8-max/lib/index.js","uid":"6a88f141-167"},{"name":"assert-has-uint8array-support/lib","children":[{"uid":"6a88f141-169","name":"uint8array.js"},{"uid":"6a88f141-171","name":"main.js"}]},{"name":"array-uint8/lib","children":[{"uid":"6a88f141-173","name":"main.js"},{"uid":"6a88f141-175","name":"polyfill.js"},{"uid":"6a88f141-177","name":"index.js"}]},{"name":"assert-is-uint8clampedarray/lib/main.js","uid":"6a88f141-179"},{"name":"assert-has-uint8clampedarray-support/lib","children":[{"uid":"6a88f141-181","name":"uint8clampedarray.js"},{"uid":"6a88f141-183","name":"main.js"}]},{"name":"array-uint8c/lib","children":[{"uid":"6a88f141-185","name":"main.js"},{"uid":"6a88f141-187","name":"polyfill.js"},{"uid":"6a88f141-189","name":"index.js"}]},{"name":"assert-is-int8array/lib/main.js","uid":"6a88f141-191"},{"name":"constants-int8-max/lib/index.js","uid":"6a88f141-193"},{"name":"constants-int8-min/lib/index.js","uid":"6a88f141-195"},{"name":"assert-has-int8array-support/lib","children":[{"uid":"6a88f141-197","name":"int8array.js"},{"uid":"6a88f141-199","name":"main.js"}]},{"name":"array-int8/lib","children":[{"uid":"6a88f141-201","name":"main.js"},{"uid":"6a88f141-203","name":"polyfill.js"},{"uid":"6a88f141-205","name":"index.js"}]},{"name":"assert-is-number/lib","children":[{"uid":"6a88f141-207","name":"primitive.js"},{"uid":"6a88f141-211","name":"tostring.js"},{"uid":"6a88f141-213","name":"try2serialize.js"},{"uid":"6a88f141-215","name":"object.js"},{"uid":"6a88f141-217","name":"main.js"},{"uid":"6a88f141-219","name":"index.js"}]},{"name":"number-ctor/lib/main.js","uid":"6a88f141-209"},{"name":"constants-float64-ninf/lib/index.js","uid":"6a88f141-221"},{"name":"math-base-special-floor/lib/main.js","uid":"6a88f141-223"},{"name":"math-base-assert-is-integer/lib/main.js","uid":"6a88f141-225"},{"name":"assert-is-integer/lib","children":[{"uid":"6a88f141-227","name":"integer.js"},{"uid":"6a88f141-229","name":"primitive.js"},{"uid":"6a88f141-231","name":"object.js"},{"uid":"6a88f141-233","name":"main.js"},{"uid":"6a88f141-235","name":"index.js"}]},{"name":"assert-is-nonnegative-integer/lib","children":[{"uid":"6a88f141-237","name":"primitive.js"},{"uid":"6a88f141-239","name":"object.js"},{"uid":"6a88f141-241","name":"main.js"},{"uid":"6a88f141-243","name":"index.js"}]},{"name":"constants-array-max-array-length/lib/index.js","uid":"6a88f141-245"},{"name":"assert-is-array-like-object/lib/main.js","uid":"6a88f141-247"},{"name":"constants-array-max-typed-array-length/lib/index.js","uid":"6a88f141-249"},{"name":"assert-is-collection/lib/main.js","uid":"6a88f141-251"},{"name":"assert-is-arraybuffer/lib/main.js","uid":"6a88f141-253"},{"name":"assert-is-object/lib/main.js","uid":"6a88f141-255"},{"name":"assert-is-string/lib","children":[{"uid":"6a88f141-257","name":"primitive.js"},{"uid":"6a88f141-259","name":"valueof.js"},{"uid":"6a88f141-261","name":"try2valueof.js"},{"uid":"6a88f141-263","name":"object.js"},{"uid":"6a88f141-265","name":"main.js"},{"uid":"6a88f141-267","name":"index.js"}]},{"name":"utils-type-of/lib","children":[{"name":"fixtures","children":[{"uid":"6a88f141-269","name":"re.js"},{"uid":"6a88f141-295","name":"nodelist.js"},{"uid":"6a88f141-297","name":"typedarray.js"}]},{"uid":"6a88f141-299","name":"check.js"},{"uid":"6a88f141-301","name":"main.js"},{"uid":"6a88f141-303","name":"polyfill.js"},{"uid":"6a88f141-305","name":"index.js"}]},{"name":"assert-is-boolean/lib","children":[{"uid":"6a88f141-271","name":"primitive.js"},{"uid":"6a88f141-275","name":"tostring.js"},{"uid":"6a88f141-277","name":"try2serialize.js"},{"uid":"6a88f141-279","name":"object.js"},{"uid":"6a88f141-281","name":"main.js"},{"uid":"6a88f141-283","name":"index.js"}]},{"name":"boolean-ctor/lib/main.js","uid":"6a88f141-273"},{"name":"utils-global/lib","children":[{"uid":"6a88f141-285","name":"codegen.js"},{"uid":"6a88f141-287","name":"self.js"},{"uid":"6a88f141-289","name":"window.js"},{"uid":"6a88f141-291","name":"global_this.js"},{"uid":"6a88f141-293","name":"browser.js"}]},{"name":"assert-is-function/lib/main.js","uid":"6a88f141-307"},{"name":"complex-float64-ctor/lib","children":[{"uid":"6a88f141-309","name":"tostring.js"},{"uid":"6a88f141-311","name":"tojson.js"},{"uid":"6a88f141-313","name":"main.js"}]},{"name":"number-float64-base-to-float32/lib","children":[{"uid":"6a88f141-315","name":"main.js"},{"uid":"6a88f141-317","name":"polyfill.js"},{"uid":"6a88f141-319","name":"index.js"}]},{"name":"complex-float32-ctor/lib","children":[{"uid":"6a88f141-321","name":"tostring.js"},{"uid":"6a88f141-323","name":"tojson.js"},{"uid":"6a88f141-325","name":"main.js"}]},{"name":"assert-is-complex-like/lib/main.js","uid":"6a88f141-327"},{"name":"math-base-assert-is-even/lib/main.js","uid":"6a88f141-329"},{"name":"array-base-assert-is-complex64array/lib/main.js","uid":"6a88f141-331"},{"name":"array-base-assert-is-complex128array/lib/main.js","uid":"6a88f141-333"},{"name":"assert-has-iterator-symbol-support/lib/main.js","uid":"6a88f141-335"},{"name":"symbol-iterator/lib/main.js","uid":"6a88f141-337"},{"name":"utils-define-nonenumerable-read-only-accessor/lib/main.js","uid":"6a88f141-339"},{"name":"complex-float32/lib","children":[{"uid":"6a88f141-341","name":"tostring.js"},{"uid":"6a88f141-343","name":"tojson.js"},{"uid":"6a88f141-345","name":"main.js"}]},{"name":"complex-realf/lib/main.js","uid":"6a88f141-347"},{"name":"complex-imagf/lib/main.js","uid":"6a88f141-349"},{"name":"strided-base-reinterpret-complex64/lib/main.js","uid":"6a88f141-351"},{"name":"strided-base-reinterpret-complex128/lib/main.js","uid":"6a88f141-353"},{"name":"array-complex64/lib","children":[{"uid":"6a88f141-355","name":"from_iterator.js"},{"uid":"6a88f141-357","name":"from_iterator_map.js"},{"uid":"6a88f141-359","name":"from_array.js"},{"uid":"6a88f141-361","name":"main.js"}]},{"name":"complex-float64/lib","children":[{"uid":"6a88f141-363","name":"tostring.js"},{"uid":"6a88f141-365","name":"tojson.js"},{"uid":"6a88f141-367","name":"main.js"}]},{"name":"complex-real/lib/main.js","uid":"6a88f141-369"},{"name":"complex-imag/lib/main.js","uid":"6a88f141-371"},{"name":"array-complex128/lib","children":[{"uid":"6a88f141-373","name":"from_iterator.js"},{"uid":"6a88f141-375","name":"from_iterator_map.js"},{"uid":"6a88f141-377","name":"from_array.js"},{"uid":"6a88f141-379","name":"main.js"}]},{"name":"array-base-resolve-getter/lib/main.js","uid":"6a88f141-387"}]},{"name":"lib","children":[{"uid":"6a88f141-389","name":"main.js"},{"uid":"6a88f141-391","name":"index.js"}]}]}],"isRoot":true},"nodeParts":{"6a88f141-1":{"renderedLength":1170,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-0"},"6a88f141-3":{"renderedLength":975,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-2"},"6a88f141-5":{"renderedLength":1021,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-4"},"6a88f141-7":{"renderedLength":690,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-6"},"6a88f141-9":{"renderedLength":1277,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-8"},"6a88f141-11":{"renderedLength":1329,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-10"},"6a88f141-13":{"renderedLength":757,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-12"},"6a88f141-15":{"renderedLength":719,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-14"},"6a88f141-17":{"renderedLength":1902,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-16"},"6a88f141-19":{"renderedLength":806,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-18"},"6a88f141-21":{"renderedLength":1172,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-20"},"6a88f141-23":{"renderedLength":1271,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-22"},"6a88f141-25":{"renderedLength":3475,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-24"},"6a88f141-27":{"renderedLength":6375,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-26"},"6a88f141-29":{"renderedLength":742,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-28"},"6a88f141-31":{"renderedLength":1093,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-30"},"6a88f141-33":{"renderedLength":2991,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-32"},"6a88f141-35":{"renderedLength":1216,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-34"},"6a88f141-37":{"renderedLength":1808,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-36"},"6a88f141-39":{"renderedLength":2661,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-38"},"6a88f141-41":{"renderedLength":1154,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-40"},"6a88f141-43":{"renderedLength":3125,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-42"},"6a88f141-45":{"renderedLength":1387,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-44"},"6a88f141-47":{"renderedLength":6312,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-46"},"6a88f141-49":{"renderedLength":1997,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-48"},"6a88f141-51":{"renderedLength":1154,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-50"},"6a88f141-53":{"renderedLength":1470,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-52"},"6a88f141-55":{"renderedLength":4787,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-54"},"6a88f141-57":{"renderedLength":852,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-56"},"6a88f141-59":{"renderedLength":1231,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-58"},"6a88f141-61":{"renderedLength":1905,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-60"},"6a88f141-63":{"renderedLength":1101,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-62"},"6a88f141-65":{"renderedLength":803,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-64"},"6a88f141-67":{"renderedLength":1592,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-66"},"6a88f141-69":{"renderedLength":1312,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-68"},"6a88f141-71":{"renderedLength":1319,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-70"},"6a88f141-73":{"renderedLength":722,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-72"},"6a88f141-75":{"renderedLength":1623,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-74"},"6a88f141-77":{"renderedLength":1058,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-76"},"6a88f141-79":{"renderedLength":1311,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-78"},"6a88f141-81":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-80"},"6a88f141-83":{"renderedLength":1322,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-82"},"6a88f141-85":{"renderedLength":772,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-84"},"6a88f141-87":{"renderedLength":901,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-86"},"6a88f141-89":{"renderedLength":800,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-88"},"6a88f141-91":{"renderedLength":1311,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-90"},"6a88f141-93":{"renderedLength":1364,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-92"},"6a88f141-95":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-94"},"6a88f141-97":{"renderedLength":1355,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-96"},"6a88f141-99":{"renderedLength":772,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-98"},"6a88f141-101":{"renderedLength":901,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-100"},"6a88f141-103":{"renderedLength":800,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-102"},"6a88f141-105":{"renderedLength":1300,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-104"},"6a88f141-107":{"renderedLength":1183,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-106"},"6a88f141-109":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-108"},"6a88f141-111":{"renderedLength":1479,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-110"},"6a88f141-113":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-112"},"6a88f141-115":{"renderedLength":886,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-114"},"6a88f141-117":{"renderedLength":798,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-116"},"6a88f141-119":{"renderedLength":1291,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-118"},"6a88f141-121":{"renderedLength":1198,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-120"},"6a88f141-123":{"renderedLength":1217,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-122"},"6a88f141-125":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-124"},"6a88f141-127":{"renderedLength":1363,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-126"},"6a88f141-129":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-128"},"6a88f141-131":{"renderedLength":900,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-130"},"6a88f141-133":{"renderedLength":796,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-132"},"6a88f141-135":{"renderedLength":1300,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-134"},"6a88f141-137":{"renderedLength":1175,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-136"},"6a88f141-139":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-138"},"6a88f141-141":{"renderedLength":1479,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-140"},"6a88f141-143":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-142"},"6a88f141-145":{"renderedLength":886,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-144"},"6a88f141-147":{"renderedLength":798,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-146"},"6a88f141-149":{"renderedLength":1291,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-148"},"6a88f141-151":{"renderedLength":1167,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-150"},"6a88f141-153":{"renderedLength":1186,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-152"},"6a88f141-155":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-154"},"6a88f141-157":{"renderedLength":1363,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-156"},"6a88f141-159":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-158"},"6a88f141-161":{"renderedLength":900,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-160"},"6a88f141-163":{"renderedLength":796,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-162"},"6a88f141-165":{"renderedLength":1289,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-164"},"6a88f141-167":{"renderedLength":1154,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-166"},"6a88f141-169":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-168"},"6a88f141-171":{"renderedLength":1468,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-170"},"6a88f141-173":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-172"},"6a88f141-175":{"renderedLength":885,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-174"},"6a88f141-177":{"renderedLength":796,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-176"},"6a88f141-179":{"renderedLength":1366,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-178"},"6a88f141-181":{"renderedLength":780,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-180"},"6a88f141-183":{"renderedLength":1514,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-182"},"6a88f141-185":{"renderedLength":782,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-184"},"6a88f141-187":{"renderedLength":902,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-186"},"6a88f141-189":{"renderedLength":810,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-188"},"6a88f141-191":{"renderedLength":1280,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-190"},"6a88f141-193":{"renderedLength":1144,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-192"},"6a88f141-195":{"renderedLength":1163,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-194"},"6a88f141-197":{"renderedLength":764,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-196"},"6a88f141-199":{"renderedLength":1354,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-198"},"6a88f141-201":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-200"},"6a88f141-203":{"renderedLength":897,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-202"},"6a88f141-205":{"renderedLength":784,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-204"},"6a88f141-207":{"renderedLength":1087,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-206"},"6a88f141-209":{"renderedLength":719,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-208"},"6a88f141-211":{"renderedLength":758,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-210"},"6a88f141-213":{"renderedLength":988,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-212"},"6a88f141-215":{"renderedLength":1272,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-214"},"6a88f141-217":{"renderedLength":1165,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-216"},"6a88f141-219":{"renderedLength":778,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-218"},"6a88f141-221":{"renderedLength":1091,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-220"},"6a88f141-223":{"renderedLength":1133,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-222"},"6a88f141-225":{"renderedLength":1039,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-224"},"6a88f141-227":{"renderedLength":974,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-226"},"6a88f141-229":{"renderedLength":1113,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-228"},"6a88f141-231":{"renderedLength":1115,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-230"},"6a88f141-233":{"renderedLength":1177,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-232"},"6a88f141-235":{"renderedLength":782,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-234"},"6a88f141-237":{"renderedLength":1157,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-236"},"6a88f141-239":{"renderedLength":1161,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-238"},"6a88f141-241":{"renderedLength":1354,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-240"},"6a88f141-243":{"renderedLength":826,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-242"},"6a88f141-245":{"renderedLength":1072,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-244"},"6a88f141-247":{"renderedLength":1299,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-246"},"6a88f141-249":{"renderedLength":1079,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-248"},"6a88f141-251":{"renderedLength":1189,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-250"},"6a88f141-253":{"renderedLength":1356,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-252"},"6a88f141-255":{"renderedLength":1064,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-254"},"6a88f141-257":{"renderedLength":1026,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-256"},"6a88f141-259":{"renderedLength":740,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-258"},"6a88f141-261":{"renderedLength":978,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-260"},"6a88f141-263":{"renderedLength":1276,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-262"},"6a88f141-265":{"renderedLength":1037,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-264"},"6a88f141-267":{"renderedLength":778,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-266"},"6a88f141-269":{"renderedLength":650,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-268"},"6a88f141-271":{"renderedLength":1147,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-270"},"6a88f141-273":{"renderedLength":1099,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-272"},"6a88f141-275":{"renderedLength":745,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-274"},"6a88f141-277":{"renderedLength":986,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-276"},"6a88f141-279":{"renderedLength":1322,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-278"},"6a88f141-281":{"renderedLength":1292,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-280"},"6a88f141-283":{"renderedLength":782,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-282"},"6a88f141-285":{"renderedLength":890,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-284"},"6a88f141-287":{"renderedLength":705,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-286"},"6a88f141-289":{"renderedLength":709,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-288"},"6a88f141-291":{"renderedLength":747,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-290"},"6a88f141-293":{"renderedLength":1820,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-292"},"6a88f141-295":{"renderedLength":733,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-294"},"6a88f141-297":{"renderedLength":710,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-296"},"6a88f141-299":{"renderedLength":1330,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-298"},"6a88f141-301":{"renderedLength":1694,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-300"},"6a88f141-303":{"renderedLength":849,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-302"},"6a88f141-305":{"renderedLength":694,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-304"},"6a88f141-307":{"renderedLength":1181,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-306"},"6a88f141-309":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-308"},"6a88f141-311":{"renderedLength":911,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-310"},"6a88f141-313":{"renderedLength":3742,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-312"},"6a88f141-315":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-314"},"6a88f141-317":{"renderedLength":1142,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-316"},"6a88f141-319":{"renderedLength":856,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-318"},"6a88f141-321":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-320"},"6a88f141-323":{"renderedLength":910,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-322"},"6a88f141-325":{"renderedLength":3760,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-324"},"6a88f141-327":{"renderedLength":1413,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-326"},"6a88f141-329":{"renderedLength":1142,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-328"},"6a88f141-331":{"renderedLength":1753,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-330"},"6a88f141-333":{"renderedLength":1765,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-332"},"6a88f141-335":{"renderedLength":1079,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-334"},"6a88f141-337":{"renderedLength":1527,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-336"},"6a88f141-339":{"renderedLength":1315,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-338"},"6a88f141-341":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-340"},"6a88f141-343":{"renderedLength":910,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-342"},"6a88f141-345":{"renderedLength":3746,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-344"},"6a88f141-347":{"renderedLength":999,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-346"},"6a88f141-349":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-348"},"6a88f141-351":{"renderedLength":1283,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-350"},"6a88f141-353":{"renderedLength":1286,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-352"},"6a88f141-355":{"renderedLength":1347,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-354"},"6a88f141-357":{"renderedLength":1531,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-356"},"6a88f141-359":{"renderedLength":1193,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-358"},"6a88f141-361":{"renderedLength":70229,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-360"},"6a88f141-363":{"renderedLength":1007,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-362"},"6a88f141-365":{"renderedLength":909,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-364"},"6a88f141-367":{"renderedLength":3724,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-366"},"6a88f141-369":{"renderedLength":999,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-368"},"6a88f141-371":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-370"},"6a88f141-373":{"renderedLength":1343,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-372"},"6a88f141-375":{"renderedLength":1527,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-374"},"6a88f141-377":{"renderedLength":1189,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-376"},"6a88f141-379":{"renderedLength":69884,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-378"},"6a88f141-381":{"renderedLength":904,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-380"},"6a88f141-383":{"renderedLength":846,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-382"},"6a88f141-385":{"renderedLength":1373,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-384"},"6a88f141-387":{"renderedLength":1083,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-386"},"6a88f141-389":{"renderedLength":1880,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-388"},"6a88f141-391":{"renderedLength":633,"gzipLength":0,"brotliLength":0,"metaUid":"6a88f141-390"}},"nodeMetas":{"6a88f141-0":{"id":"/node_modules/@stdlib/error-tools-fmtprodmsg/lib/main.js","moduleParts":{"browser.js":"6a88f141-1"},"imported":[],"importedBy":[{"uid":"6a88f141-392"}]},"6a88f141-2":{"id":"/node_modules/@stdlib/assert-has-symbol-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-3"},"imported":[],"importedBy":[{"uid":"6a88f141-403"}]},"6a88f141-4":{"id":"/node_modules/@stdlib/assert-has-tostringtag-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-5"},"imported":[{"uid":"6a88f141-403"}],"importedBy":[{"uid":"6a88f141-399"}]},"6a88f141-6":{"id":"/node_modules/@stdlib/utils-native-class/lib/tostring.js","moduleParts":{"browser.js":"6a88f141-7"},"imported":[],"importedBy":[{"uid":"6a88f141-8"},{"uid":"6a88f141-16"}]},"6a88f141-8":{"id":"/node_modules/@stdlib/utils-native-class/lib/main.js","moduleParts":{"browser.js":"6a88f141-9"},"imported":[{"uid":"6a88f141-6"}],"importedBy":[{"uid":"6a88f141-18"}]},"6a88f141-10":{"id":"/node_modules/@stdlib/assert-has-own-property/lib/main.js","moduleParts":{"browser.js":"6a88f141-11"},"imported":[],"importedBy":[{"uid":"6a88f141-400"}]},"6a88f141-12":{"id":"/node_modules/@stdlib/symbol-ctor/lib/main.js","moduleParts":{"browser.js":"6a88f141-13"},"imported":[],"importedBy":[{"uid":"6a88f141-404"}]},"6a88f141-14":{"id":"/node_modules/@stdlib/utils-native-class/lib/tostringtag.js","moduleParts":{"browser.js":"6a88f141-15"},"imported":[{"uid":"6a88f141-404"}],"importedBy":[{"uid":"6a88f141-16"}]},"6a88f141-16":{"id":"/node_modules/@stdlib/utils-native-class/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-17"},"imported":[{"uid":"6a88f141-400"},{"uid":"6a88f141-14"},{"uid":"6a88f141-6"}],"importedBy":[{"uid":"6a88f141-18"}]},"6a88f141-18":{"id":"/node_modules/@stdlib/utils-native-class/lib/index.js","moduleParts":{"browser.js":"6a88f141-19"},"imported":[{"uid":"6a88f141-399"},{"uid":"6a88f141-8"},{"uid":"6a88f141-16"}],"importedBy":[{"uid":"6a88f141-20"},{"uid":"6a88f141-74"},{"uid":"6a88f141-252"},{"uid":"6a88f141-262"},{"uid":"6a88f141-78"},{"uid":"6a88f141-90"},{"uid":"6a88f141-104"},{"uid":"6a88f141-118"},{"uid":"6a88f141-134"},{"uid":"6a88f141-148"},{"uid":"6a88f141-164"},{"uid":"6a88f141-178"},{"uid":"6a88f141-190"},{"uid":"6a88f141-214"},{"uid":"6a88f141-278"}]},"6a88f141-20":{"id":"/node_modules/@stdlib/assert-is-array/lib/main.js","moduleParts":{"browser.js":"6a88f141-21"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-393"}]},"6a88f141-22":{"id":"/node_modules/@stdlib/array-base-assert-is-accessor-array/lib/main.js","moduleParts":{"browser.js":"6a88f141-23"},"imported":[],"importedBy":[{"uid":"6a88f141-395"}]},"6a88f141-24":{"id":"/node_modules/@stdlib/array-base-accessor-getter/lib/main.js","moduleParts":{"browser.js":"6a88f141-25"},"imported":[],"importedBy":[{"uid":"6a88f141-396"}]},"6a88f141-26":{"id":"/node_modules/@stdlib/array-base-getter/lib/main.js","moduleParts":{"browser.js":"6a88f141-27"},"imported":[],"importedBy":[{"uid":"6a88f141-397"}]},"6a88f141-28":{"id":"/node_modules/@stdlib/utils-define-property/lib/define_property.js","moduleParts":{"browser.js":"6a88f141-29"},"imported":[],"importedBy":[{"uid":"6a88f141-30"}]},"6a88f141-30":{"id":"/node_modules/@stdlib/utils-define-property/lib/has_define_property_support.js","moduleParts":{"browser.js":"6a88f141-31"},"imported":[{"uid":"6a88f141-28"}],"importedBy":[{"uid":"6a88f141-56"}]},"6a88f141-32":{"id":"/node_modules/@stdlib/utils-define-property/lib/builtin.js","moduleParts":{"browser.js":"6a88f141-33"},"imported":[],"importedBy":[{"uid":"6a88f141-56"}]},"6a88f141-34":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/is_number.js","moduleParts":{"browser.js":"6a88f141-35"},"imported":[],"importedBy":[{"uid":"6a88f141-38"},{"uid":"6a88f141-42"}]},"6a88f141-36":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/zero_pad.js","moduleParts":{"browser.js":"6a88f141-37"},"imported":[],"importedBy":[{"uid":"6a88f141-46"},{"uid":"6a88f141-38"}]},"6a88f141-38":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/format_integer.js","moduleParts":{"browser.js":"6a88f141-39"},"imported":[{"uid":"6a88f141-34"},{"uid":"6a88f141-36"}],"importedBy":[{"uid":"6a88f141-46"}]},"6a88f141-40":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/is_string.js","moduleParts":{"browser.js":"6a88f141-41"},"imported":[],"importedBy":[{"uid":"6a88f141-46"}]},"6a88f141-42":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/format_double.js","moduleParts":{"browser.js":"6a88f141-43"},"imported":[{"uid":"6a88f141-34"}],"importedBy":[{"uid":"6a88f141-46"}]},"6a88f141-44":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/space_pad.js","moduleParts":{"browser.js":"6a88f141-45"},"imported":[],"importedBy":[{"uid":"6a88f141-46"}]},"6a88f141-46":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/main.js","moduleParts":{"browser.js":"6a88f141-47"},"imported":[{"uid":"6a88f141-38"},{"uid":"6a88f141-40"},{"uid":"6a88f141-42"},{"uid":"6a88f141-44"},{"uid":"6a88f141-36"}],"importedBy":[{"uid":"6a88f141-452"}]},"6a88f141-48":{"id":"/node_modules/@stdlib/string-base-format-tokenize/lib/main.js","moduleParts":{"browser.js":"6a88f141-49"},"imported":[],"importedBy":[{"uid":"6a88f141-453"}]},"6a88f141-50":{"id":"/node_modules/@stdlib/string-format/lib/is_string.js","moduleParts":{"browser.js":"6a88f141-51"},"imported":[],"importedBy":[{"uid":"6a88f141-52"}]},"6a88f141-52":{"id":"/node_modules/@stdlib/string-format/lib/main.js","moduleParts":{"browser.js":"6a88f141-53"},"imported":[{"uid":"6a88f141-452"},{"uid":"6a88f141-453"},{"uid":"6a88f141-50"}],"importedBy":[{"uid":"6a88f141-432"}]},"6a88f141-54":{"id":"/node_modules/@stdlib/utils-define-property/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-55"},"imported":[{"uid":"6a88f141-432"}],"importedBy":[{"uid":"6a88f141-56"}]},"6a88f141-56":{"id":"/node_modules/@stdlib/utils-define-property/lib/index.js","moduleParts":{"browser.js":"6a88f141-57"},"imported":[{"uid":"6a88f141-30"},{"uid":"6a88f141-32"},{"uid":"6a88f141-54"}],"importedBy":[{"uid":"6a88f141-58"},{"uid":"6a88f141-338"},{"uid":"6a88f141-344"},{"uid":"6a88f141-366"},{"uid":"6a88f141-312"},{"uid":"6a88f141-324"}]},"6a88f141-58":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-property/lib/main.js","moduleParts":{"browser.js":"6a88f141-59"},"imported":[{"uid":"6a88f141-56"}],"importedBy":[{"uid":"6a88f141-416"}]},"6a88f141-60":{"id":"/node_modules/@stdlib/assert-tools-array-function/lib/main.js","moduleParts":{"browser.js":"6a88f141-61"},"imported":[{"uid":"6a88f141-393"},{"uid":"6a88f141-432"}],"importedBy":[{"uid":"6a88f141-417"}]},"6a88f141-62":{"id":"/node_modules/@stdlib/assert-is-object-like/lib/main.js","moduleParts":{"browser.js":"6a88f141-63"},"imported":[],"importedBy":[{"uid":"6a88f141-64"}]},"6a88f141-64":{"id":"/node_modules/@stdlib/assert-is-object-like/lib/index.js","moduleParts":{"browser.js":"6a88f141-65"},"imported":[{"uid":"6a88f141-416"},{"uid":"6a88f141-417"},{"uid":"6a88f141-62"}],"importedBy":[{"uid":"6a88f141-66"}]},"6a88f141-66":{"id":"/node_modules/@stdlib/assert-is-buffer/lib/main.js","moduleParts":{"browser.js":"6a88f141-67"},"imported":[{"uid":"6a88f141-64"}],"importedBy":[{"uid":"6a88f141-401"}]},"6a88f141-68":{"id":"/node_modules/@stdlib/regexp-function-name/lib/main.js","moduleParts":{"browser.js":"6a88f141-69"},"imported":[],"importedBy":[{"uid":"6a88f141-72"},{"uid":"6a88f141-70"}]},"6a88f141-70":{"id":"/node_modules/@stdlib/regexp-function-name/lib/regexp.js","moduleParts":{"browser.js":"6a88f141-71"},"imported":[{"uid":"6a88f141-68"}],"importedBy":[{"uid":"6a88f141-72"}]},"6a88f141-72":{"id":"/node_modules/@stdlib/regexp-function-name/lib/index.js","moduleParts":{"browser.js":"6a88f141-73"},"imported":[{"uid":"6a88f141-416"},{"uid":"6a88f141-68"},{"uid":"6a88f141-70"}],"importedBy":[{"uid":"6a88f141-74"}]},"6a88f141-74":{"id":"/node_modules/@stdlib/utils-constructor-name/lib/main.js","moduleParts":{"browser.js":"6a88f141-75"},"imported":[{"uid":"6a88f141-18"},{"uid":"6a88f141-72"},{"uid":"6a88f141-401"}],"importedBy":[{"uid":"6a88f141-402"}]},"6a88f141-76":{"id":"/node_modules/@stdlib/array-dtype/lib/ctor2dtype.js","moduleParts":{"browser.js":"6a88f141-77"},"imported":[],"importedBy":[{"uid":"6a88f141-384"}]},"6a88f141-78":{"id":"/node_modules/@stdlib/assert-is-float64array/lib/main.js","moduleParts":{"browser.js":"6a88f141-79"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-441"}]},"6a88f141-80":{"id":"/node_modules/@stdlib/assert-has-float64array-support/lib/float64array.js","moduleParts":{"browser.js":"6a88f141-81"},"imported":[],"importedBy":[{"uid":"6a88f141-82"}]},"6a88f141-82":{"id":"/node_modules/@stdlib/assert-has-float64array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-83"},"imported":[{"uid":"6a88f141-441"},{"uid":"6a88f141-80"}],"importedBy":[{"uid":"6a88f141-407"}]},"6a88f141-84":{"id":"/node_modules/@stdlib/array-float64/lib/main.js","moduleParts":{"browser.js":"6a88f141-85"},"imported":[],"importedBy":[{"uid":"6a88f141-88"}]},"6a88f141-86":{"id":"/node_modules/@stdlib/array-float64/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-87"},"imported":[],"importedBy":[{"uid":"6a88f141-88"}]},"6a88f141-88":{"id":"/node_modules/@stdlib/array-float64/lib/index.js","moduleParts":{"browser.js":"6a88f141-89"},"imported":[{"uid":"6a88f141-407"},{"uid":"6a88f141-84"},{"uid":"6a88f141-86"}],"importedBy":[{"uid":"6a88f141-380"},{"uid":"6a88f141-378"},{"uid":"6a88f141-352"}]},"6a88f141-90":{"id":"/node_modules/@stdlib/assert-is-float32array/lib/main.js","moduleParts":{"browser.js":"6a88f141-91"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-442"}]},"6a88f141-92":{"id":"/node_modules/@stdlib/constants-float64-pinf/lib/index.js","moduleParts":{"browser.js":"6a88f141-93"},"imported":[],"importedBy":[{"uid":"6a88f141-96"},{"uid":"6a88f141-226"}]},"6a88f141-94":{"id":"/node_modules/@stdlib/assert-has-float32array-support/lib/float32array.js","moduleParts":{"browser.js":"6a88f141-95"},"imported":[],"importedBy":[{"uid":"6a88f141-96"}]},"6a88f141-96":{"id":"/node_modules/@stdlib/assert-has-float32array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-97"},"imported":[{"uid":"6a88f141-442"},{"uid":"6a88f141-92"},{"uid":"6a88f141-94"}],"importedBy":[{"uid":"6a88f141-408"}]},"6a88f141-98":{"id":"/node_modules/@stdlib/array-float32/lib/main.js","moduleParts":{"browser.js":"6a88f141-99"},"imported":[],"importedBy":[{"uid":"6a88f141-102"}]},"6a88f141-100":{"id":"/node_modules/@stdlib/array-float32/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-101"},"imported":[],"importedBy":[{"uid":"6a88f141-102"}]},"6a88f141-102":{"id":"/node_modules/@stdlib/array-float32/lib/index.js","moduleParts":{"browser.js":"6a88f141-103"},"imported":[{"uid":"6a88f141-408"},{"uid":"6a88f141-98"},{"uid":"6a88f141-100"}],"importedBy":[{"uid":"6a88f141-380"},{"uid":"6a88f141-360"},{"uid":"6a88f141-350"},{"uid":"6a88f141-316"}]},"6a88f141-104":{"id":"/node_modules/@stdlib/assert-is-uint32array/lib/main.js","moduleParts":{"browser.js":"6a88f141-105"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-443"}]},"6a88f141-106":{"id":"/node_modules/@stdlib/constants-uint32-max/lib/index.js","moduleParts":{"browser.js":"6a88f141-107"},"imported":[],"importedBy":[{"uid":"6a88f141-110"}]},"6a88f141-108":{"id":"/node_modules/@stdlib/assert-has-uint32array-support/lib/uint32array.js","moduleParts":{"browser.js":"6a88f141-109"},"imported":[],"importedBy":[{"uid":"6a88f141-110"}]},"6a88f141-110":{"id":"/node_modules/@stdlib/assert-has-uint32array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-111"},"imported":[{"uid":"6a88f141-443"},{"uid":"6a88f141-106"},{"uid":"6a88f141-108"}],"importedBy":[{"uid":"6a88f141-409"}]},"6a88f141-112":{"id":"/node_modules/@stdlib/array-uint32/lib/main.js","moduleParts":{"browser.js":"6a88f141-113"},"imported":[],"importedBy":[{"uid":"6a88f141-116"}]},"6a88f141-114":{"id":"/node_modules/@stdlib/array-uint32/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-115"},"imported":[],"importedBy":[{"uid":"6a88f141-116"}]},"6a88f141-116":{"id":"/node_modules/@stdlib/array-uint32/lib/index.js","moduleParts":{"browser.js":"6a88f141-117"},"imported":[{"uid":"6a88f141-409"},{"uid":"6a88f141-112"},{"uid":"6a88f141-114"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-118":{"id":"/node_modules/@stdlib/assert-is-int32array/lib/main.js","moduleParts":{"browser.js":"6a88f141-119"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-444"}]},"6a88f141-120":{"id":"/node_modules/@stdlib/constants-int32-max/lib/index.js","moduleParts":{"browser.js":"6a88f141-121"},"imported":[],"importedBy":[{"uid":"6a88f141-126"}]},"6a88f141-122":{"id":"/node_modules/@stdlib/constants-int32-min/lib/index.js","moduleParts":{"browser.js":"6a88f141-123"},"imported":[],"importedBy":[{"uid":"6a88f141-126"}]},"6a88f141-124":{"id":"/node_modules/@stdlib/assert-has-int32array-support/lib/int32array.js","moduleParts":{"browser.js":"6a88f141-125"},"imported":[],"importedBy":[{"uid":"6a88f141-126"}]},"6a88f141-126":{"id":"/node_modules/@stdlib/assert-has-int32array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-127"},"imported":[{"uid":"6a88f141-444"},{"uid":"6a88f141-120"},{"uid":"6a88f141-122"},{"uid":"6a88f141-124"}],"importedBy":[{"uid":"6a88f141-410"}]},"6a88f141-128":{"id":"/node_modules/@stdlib/array-int32/lib/main.js","moduleParts":{"browser.js":"6a88f141-129"},"imported":[],"importedBy":[{"uid":"6a88f141-132"}]},"6a88f141-130":{"id":"/node_modules/@stdlib/array-int32/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-131"},"imported":[],"importedBy":[{"uid":"6a88f141-132"}]},"6a88f141-132":{"id":"/node_modules/@stdlib/array-int32/lib/index.js","moduleParts":{"browser.js":"6a88f141-133"},"imported":[{"uid":"6a88f141-410"},{"uid":"6a88f141-128"},{"uid":"6a88f141-130"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-134":{"id":"/node_modules/@stdlib/assert-is-uint16array/lib/main.js","moduleParts":{"browser.js":"6a88f141-135"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-445"}]},"6a88f141-136":{"id":"/node_modules/@stdlib/constants-uint16-max/lib/index.js","moduleParts":{"browser.js":"6a88f141-137"},"imported":[],"importedBy":[{"uid":"6a88f141-140"}]},"6a88f141-138":{"id":"/node_modules/@stdlib/assert-has-uint16array-support/lib/uint16array.js","moduleParts":{"browser.js":"6a88f141-139"},"imported":[],"importedBy":[{"uid":"6a88f141-140"}]},"6a88f141-140":{"id":"/node_modules/@stdlib/assert-has-uint16array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-141"},"imported":[{"uid":"6a88f141-445"},{"uid":"6a88f141-136"},{"uid":"6a88f141-138"}],"importedBy":[{"uid":"6a88f141-411"}]},"6a88f141-142":{"id":"/node_modules/@stdlib/array-uint16/lib/main.js","moduleParts":{"browser.js":"6a88f141-143"},"imported":[],"importedBy":[{"uid":"6a88f141-146"}]},"6a88f141-144":{"id":"/node_modules/@stdlib/array-uint16/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-145"},"imported":[],"importedBy":[{"uid":"6a88f141-146"}]},"6a88f141-146":{"id":"/node_modules/@stdlib/array-uint16/lib/index.js","moduleParts":{"browser.js":"6a88f141-147"},"imported":[{"uid":"6a88f141-411"},{"uid":"6a88f141-142"},{"uid":"6a88f141-144"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-148":{"id":"/node_modules/@stdlib/assert-is-int16array/lib/main.js","moduleParts":{"browser.js":"6a88f141-149"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-446"}]},"6a88f141-150":{"id":"/node_modules/@stdlib/constants-int16-max/lib/index.js","moduleParts":{"browser.js":"6a88f141-151"},"imported":[],"importedBy":[{"uid":"6a88f141-156"}]},"6a88f141-152":{"id":"/node_modules/@stdlib/constants-int16-min/lib/index.js","moduleParts":{"browser.js":"6a88f141-153"},"imported":[],"importedBy":[{"uid":"6a88f141-156"}]},"6a88f141-154":{"id":"/node_modules/@stdlib/assert-has-int16array-support/lib/int16array.js","moduleParts":{"browser.js":"6a88f141-155"},"imported":[],"importedBy":[{"uid":"6a88f141-156"}]},"6a88f141-156":{"id":"/node_modules/@stdlib/assert-has-int16array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-157"},"imported":[{"uid":"6a88f141-446"},{"uid":"6a88f141-150"},{"uid":"6a88f141-152"},{"uid":"6a88f141-154"}],"importedBy":[{"uid":"6a88f141-412"}]},"6a88f141-158":{"id":"/node_modules/@stdlib/array-int16/lib/main.js","moduleParts":{"browser.js":"6a88f141-159"},"imported":[],"importedBy":[{"uid":"6a88f141-162"}]},"6a88f141-160":{"id":"/node_modules/@stdlib/array-int16/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-161"},"imported":[],"importedBy":[{"uid":"6a88f141-162"}]},"6a88f141-162":{"id":"/node_modules/@stdlib/array-int16/lib/index.js","moduleParts":{"browser.js":"6a88f141-163"},"imported":[{"uid":"6a88f141-412"},{"uid":"6a88f141-158"},{"uid":"6a88f141-160"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-164":{"id":"/node_modules/@stdlib/assert-is-uint8array/lib/main.js","moduleParts":{"browser.js":"6a88f141-165"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-447"}]},"6a88f141-166":{"id":"/node_modules/@stdlib/constants-uint8-max/lib/index.js","moduleParts":{"browser.js":"6a88f141-167"},"imported":[],"importedBy":[{"uid":"6a88f141-170"}]},"6a88f141-168":{"id":"/node_modules/@stdlib/assert-has-uint8array-support/lib/uint8array.js","moduleParts":{"browser.js":"6a88f141-169"},"imported":[],"importedBy":[{"uid":"6a88f141-170"}]},"6a88f141-170":{"id":"/node_modules/@stdlib/assert-has-uint8array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-171"},"imported":[{"uid":"6a88f141-447"},{"uid":"6a88f141-166"},{"uid":"6a88f141-168"}],"importedBy":[{"uid":"6a88f141-413"}]},"6a88f141-172":{"id":"/node_modules/@stdlib/array-uint8/lib/main.js","moduleParts":{"browser.js":"6a88f141-173"},"imported":[],"importedBy":[{"uid":"6a88f141-176"}]},"6a88f141-174":{"id":"/node_modules/@stdlib/array-uint8/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-175"},"imported":[],"importedBy":[{"uid":"6a88f141-176"}]},"6a88f141-176":{"id":"/node_modules/@stdlib/array-uint8/lib/index.js","moduleParts":{"browser.js":"6a88f141-177"},"imported":[{"uid":"6a88f141-413"},{"uid":"6a88f141-172"},{"uid":"6a88f141-174"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-178":{"id":"/node_modules/@stdlib/assert-is-uint8clampedarray/lib/main.js","moduleParts":{"browser.js":"6a88f141-179"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-448"}]},"6a88f141-180":{"id":"/node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/uint8clampedarray.js","moduleParts":{"browser.js":"6a88f141-181"},"imported":[],"importedBy":[{"uid":"6a88f141-182"}]},"6a88f141-182":{"id":"/node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-183"},"imported":[{"uid":"6a88f141-448"},{"uid":"6a88f141-180"}],"importedBy":[{"uid":"6a88f141-414"}]},"6a88f141-184":{"id":"/node_modules/@stdlib/array-uint8c/lib/main.js","moduleParts":{"browser.js":"6a88f141-185"},"imported":[],"importedBy":[{"uid":"6a88f141-188"}]},"6a88f141-186":{"id":"/node_modules/@stdlib/array-uint8c/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-187"},"imported":[],"importedBy":[{"uid":"6a88f141-188"}]},"6a88f141-188":{"id":"/node_modules/@stdlib/array-uint8c/lib/index.js","moduleParts":{"browser.js":"6a88f141-189"},"imported":[{"uid":"6a88f141-414"},{"uid":"6a88f141-184"},{"uid":"6a88f141-186"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-190":{"id":"/node_modules/@stdlib/assert-is-int8array/lib/main.js","moduleParts":{"browser.js":"6a88f141-191"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-449"}]},"6a88f141-192":{"id":"/node_modules/@stdlib/constants-int8-max/lib/index.js","moduleParts":{"browser.js":"6a88f141-193"},"imported":[],"importedBy":[{"uid":"6a88f141-198"}]},"6a88f141-194":{"id":"/node_modules/@stdlib/constants-int8-min/lib/index.js","moduleParts":{"browser.js":"6a88f141-195"},"imported":[],"importedBy":[{"uid":"6a88f141-198"}]},"6a88f141-196":{"id":"/node_modules/@stdlib/assert-has-int8array-support/lib/int8array.js","moduleParts":{"browser.js":"6a88f141-197"},"imported":[],"importedBy":[{"uid":"6a88f141-198"}]},"6a88f141-198":{"id":"/node_modules/@stdlib/assert-has-int8array-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-199"},"imported":[{"uid":"6a88f141-449"},{"uid":"6a88f141-192"},{"uid":"6a88f141-194"},{"uid":"6a88f141-196"}],"importedBy":[{"uid":"6a88f141-415"}]},"6a88f141-200":{"id":"/node_modules/@stdlib/array-int8/lib/main.js","moduleParts":{"browser.js":"6a88f141-201"},"imported":[],"importedBy":[{"uid":"6a88f141-204"}]},"6a88f141-202":{"id":"/node_modules/@stdlib/array-int8/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-203"},"imported":[],"importedBy":[{"uid":"6a88f141-204"}]},"6a88f141-204":{"id":"/node_modules/@stdlib/array-int8/lib/index.js","moduleParts":{"browser.js":"6a88f141-205"},"imported":[{"uid":"6a88f141-415"},{"uid":"6a88f141-200"},{"uid":"6a88f141-202"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-206":{"id":"/node_modules/@stdlib/assert-is-number/lib/primitive.js","moduleParts":{"browser.js":"6a88f141-207"},"imported":[],"importedBy":[{"uid":"6a88f141-218"},{"uid":"6a88f141-216"}]},"6a88f141-208":{"id":"/node_modules/@stdlib/number-ctor/lib/main.js","moduleParts":{"browser.js":"6a88f141-209"},"imported":[],"importedBy":[{"uid":"6a88f141-454"}]},"6a88f141-210":{"id":"/node_modules/@stdlib/assert-is-number/lib/tostring.js","moduleParts":{"browser.js":"6a88f141-211"},"imported":[{"uid":"6a88f141-454"}],"importedBy":[{"uid":"6a88f141-212"}]},"6a88f141-212":{"id":"/node_modules/@stdlib/assert-is-number/lib/try2serialize.js","moduleParts":{"browser.js":"6a88f141-213"},"imported":[{"uid":"6a88f141-210"}],"importedBy":[{"uid":"6a88f141-214"}]},"6a88f141-214":{"id":"/node_modules/@stdlib/assert-is-number/lib/object.js","moduleParts":{"browser.js":"6a88f141-215"},"imported":[{"uid":"6a88f141-399"},{"uid":"6a88f141-18"},{"uid":"6a88f141-454"},{"uid":"6a88f141-212"}],"importedBy":[{"uid":"6a88f141-218"},{"uid":"6a88f141-216"}]},"6a88f141-216":{"id":"/node_modules/@stdlib/assert-is-number/lib/main.js","moduleParts":{"browser.js":"6a88f141-217"},"imported":[{"uid":"6a88f141-206"},{"uid":"6a88f141-214"}],"importedBy":[{"uid":"6a88f141-218"}]},"6a88f141-218":{"id":"/node_modules/@stdlib/assert-is-number/lib/index.js","moduleParts":{"browser.js":"6a88f141-219"},"imported":[{"uid":"6a88f141-416"},{"uid":"6a88f141-216"},{"uid":"6a88f141-206"},{"uid":"6a88f141-214"}],"importedBy":[{"uid":"6a88f141-344"},{"uid":"6a88f141-366"},{"uid":"6a88f141-228"},{"uid":"6a88f141-230"},{"uid":"6a88f141-312"},{"uid":"6a88f141-324"}]},"6a88f141-220":{"id":"/node_modules/@stdlib/constants-float64-ninf/lib/index.js","moduleParts":{"browser.js":"6a88f141-221"},"imported":[{"uid":"6a88f141-454"}],"importedBy":[{"uid":"6a88f141-226"}]},"6a88f141-222":{"id":"/node_modules/@stdlib/math-base-special-floor/lib/main.js","moduleParts":{"browser.js":"6a88f141-223"},"imported":[],"importedBy":[{"uid":"6a88f141-435"}]},"6a88f141-224":{"id":"/node_modules/@stdlib/math-base-assert-is-integer/lib/main.js","moduleParts":{"browser.js":"6a88f141-225"},"imported":[{"uid":"6a88f141-435"}],"importedBy":[{"uid":"6a88f141-425"}]},"6a88f141-226":{"id":"/node_modules/@stdlib/assert-is-integer/lib/integer.js","moduleParts":{"browser.js":"6a88f141-227"},"imported":[{"uid":"6a88f141-92"},{"uid":"6a88f141-220"},{"uid":"6a88f141-425"}],"importedBy":[{"uid":"6a88f141-228"},{"uid":"6a88f141-230"}]},"6a88f141-228":{"id":"/node_modules/@stdlib/assert-is-integer/lib/primitive.js","moduleParts":{"browser.js":"6a88f141-229"},"imported":[{"uid":"6a88f141-218"},{"uid":"6a88f141-226"}],"importedBy":[{"uid":"6a88f141-234"},{"uid":"6a88f141-232"}]},"6a88f141-230":{"id":"/node_modules/@stdlib/assert-is-integer/lib/object.js","moduleParts":{"browser.js":"6a88f141-231"},"imported":[{"uid":"6a88f141-218"},{"uid":"6a88f141-226"}],"importedBy":[{"uid":"6a88f141-234"},{"uid":"6a88f141-232"}]},"6a88f141-232":{"id":"/node_modules/@stdlib/assert-is-integer/lib/main.js","moduleParts":{"browser.js":"6a88f141-233"},"imported":[{"uid":"6a88f141-228"},{"uid":"6a88f141-230"}],"importedBy":[{"uid":"6a88f141-234"}]},"6a88f141-234":{"id":"/node_modules/@stdlib/assert-is-integer/lib/index.js","moduleParts":{"browser.js":"6a88f141-235"},"imported":[{"uid":"6a88f141-416"},{"uid":"6a88f141-232"},{"uid":"6a88f141-228"},{"uid":"6a88f141-230"}],"importedBy":[{"uid":"6a88f141-236"},{"uid":"6a88f141-238"}]},"6a88f141-236":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/primitive.js","moduleParts":{"browser.js":"6a88f141-237"},"imported":[{"uid":"6a88f141-234"}],"importedBy":[{"uid":"6a88f141-242"},{"uid":"6a88f141-240"}]},"6a88f141-238":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/object.js","moduleParts":{"browser.js":"6a88f141-239"},"imported":[{"uid":"6a88f141-234"}],"importedBy":[{"uid":"6a88f141-242"},{"uid":"6a88f141-240"}]},"6a88f141-240":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/main.js","moduleParts":{"browser.js":"6a88f141-241"},"imported":[{"uid":"6a88f141-236"},{"uid":"6a88f141-238"}],"importedBy":[{"uid":"6a88f141-242"}]},"6a88f141-242":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/index.js","moduleParts":{"browser.js":"6a88f141-243"},"imported":[{"uid":"6a88f141-416"},{"uid":"6a88f141-240"},{"uid":"6a88f141-236"},{"uid":"6a88f141-238"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-244":{"id":"/node_modules/@stdlib/constants-array-max-array-length/lib/index.js","moduleParts":{"browser.js":"6a88f141-245"},"imported":[],"importedBy":[{"uid":"6a88f141-246"}]},"6a88f141-246":{"id":"/node_modules/@stdlib/assert-is-array-like-object/lib/main.js","moduleParts":{"browser.js":"6a88f141-247"},"imported":[{"uid":"6a88f141-425"},{"uid":"6a88f141-244"}],"importedBy":[{"uid":"6a88f141-418"}]},"6a88f141-248":{"id":"/node_modules/@stdlib/constants-array-max-typed-array-length/lib/index.js","moduleParts":{"browser.js":"6a88f141-249"},"imported":[],"importedBy":[{"uid":"6a88f141-250"}]},"6a88f141-250":{"id":"/node_modules/@stdlib/assert-is-collection/lib/main.js","moduleParts":{"browser.js":"6a88f141-251"},"imported":[{"uid":"6a88f141-425"},{"uid":"6a88f141-248"}],"importedBy":[{"uid":"6a88f141-419"}]},"6a88f141-252":{"id":"/node_modules/@stdlib/assert-is-arraybuffer/lib/main.js","moduleParts":{"browser.js":"6a88f141-253"},"imported":[{"uid":"6a88f141-18"}],"importedBy":[{"uid":"6a88f141-420"}]},"6a88f141-254":{"id":"/node_modules/@stdlib/assert-is-object/lib/main.js","moduleParts":{"browser.js":"6a88f141-255"},"imported":[{"uid":"6a88f141-393"}],"importedBy":[{"uid":"6a88f141-421"}]},"6a88f141-256":{"id":"/node_modules/@stdlib/assert-is-string/lib/primitive.js","moduleParts":{"browser.js":"6a88f141-257"},"imported":[],"importedBy":[{"uid":"6a88f141-266"},{"uid":"6a88f141-264"}]},"6a88f141-258":{"id":"/node_modules/@stdlib/assert-is-string/lib/valueof.js","moduleParts":{"browser.js":"6a88f141-259"},"imported":[],"importedBy":[{"uid":"6a88f141-260"}]},"6a88f141-260":{"id":"/node_modules/@stdlib/assert-is-string/lib/try2valueof.js","moduleParts":{"browser.js":"6a88f141-261"},"imported":[{"uid":"6a88f141-258"}],"importedBy":[{"uid":"6a88f141-262"}]},"6a88f141-262":{"id":"/node_modules/@stdlib/assert-is-string/lib/object.js","moduleParts":{"browser.js":"6a88f141-263"},"imported":[{"uid":"6a88f141-399"},{"uid":"6a88f141-18"},{"uid":"6a88f141-260"}],"importedBy":[{"uid":"6a88f141-266"},{"uid":"6a88f141-264"}]},"6a88f141-264":{"id":"/node_modules/@stdlib/assert-is-string/lib/main.js","moduleParts":{"browser.js":"6a88f141-265"},"imported":[{"uid":"6a88f141-256"},{"uid":"6a88f141-262"}],"importedBy":[{"uid":"6a88f141-266"}]},"6a88f141-266":{"id":"/node_modules/@stdlib/assert-is-string/lib/index.js","moduleParts":{"browser.js":"6a88f141-267"},"imported":[{"uid":"6a88f141-416"},{"uid":"6a88f141-264"},{"uid":"6a88f141-256"},{"uid":"6a88f141-262"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-268":{"id":"/node_modules/@stdlib/utils-type-of/lib/fixtures/re.js","moduleParts":{"browser.js":"6a88f141-269"},"imported":[],"importedBy":[{"uid":"6a88f141-298"}]},"6a88f141-270":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/primitive.js","moduleParts":{"browser.js":"6a88f141-271"},"imported":[],"importedBy":[{"uid":"6a88f141-282"},{"uid":"6a88f141-280"}]},"6a88f141-272":{"id":"/node_modules/@stdlib/boolean-ctor/lib/main.js","moduleParts":{"browser.js":"6a88f141-273"},"imported":[],"importedBy":[{"uid":"6a88f141-455"}]},"6a88f141-274":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/tostring.js","moduleParts":{"browser.js":"6a88f141-275"},"imported":[],"importedBy":[{"uid":"6a88f141-276"}]},"6a88f141-276":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/try2serialize.js","moduleParts":{"browser.js":"6a88f141-277"},"imported":[{"uid":"6a88f141-274"}],"importedBy":[{"uid":"6a88f141-278"}]},"6a88f141-278":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/object.js","moduleParts":{"browser.js":"6a88f141-279"},"imported":[{"uid":"6a88f141-399"},{"uid":"6a88f141-18"},{"uid":"6a88f141-455"},{"uid":"6a88f141-276"}],"importedBy":[{"uid":"6a88f141-282"},{"uid":"6a88f141-280"}]},"6a88f141-280":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/main.js","moduleParts":{"browser.js":"6a88f141-281"},"imported":[{"uid":"6a88f141-270"},{"uid":"6a88f141-278"}],"importedBy":[{"uid":"6a88f141-282"}]},"6a88f141-282":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/index.js","moduleParts":{"browser.js":"6a88f141-283"},"imported":[{"uid":"6a88f141-416"},{"uid":"6a88f141-280"},{"uid":"6a88f141-270"},{"uid":"6a88f141-278"}],"importedBy":[{"uid":"6a88f141-292"}]},"6a88f141-284":{"id":"/node_modules/@stdlib/utils-global/lib/codegen.js","moduleParts":{"browser.js":"6a88f141-285"},"imported":[],"importedBy":[{"uid":"6a88f141-292"}]},"6a88f141-286":{"id":"/node_modules/@stdlib/utils-global/lib/self.js","moduleParts":{"browser.js":"6a88f141-287"},"imported":[],"importedBy":[{"uid":"6a88f141-292"}]},"6a88f141-288":{"id":"/node_modules/@stdlib/utils-global/lib/window.js","moduleParts":{"browser.js":"6a88f141-289"},"imported":[],"importedBy":[{"uid":"6a88f141-292"}]},"6a88f141-290":{"id":"/node_modules/@stdlib/utils-global/lib/global_this.js","moduleParts":{"browser.js":"6a88f141-291"},"imported":[],"importedBy":[{"uid":"6a88f141-292"}]},"6a88f141-292":{"id":"/node_modules/@stdlib/utils-global/lib/browser.js","moduleParts":{"browser.js":"6a88f141-293"},"imported":[{"uid":"6a88f141-282"},{"uid":"6a88f141-432"},{"uid":"6a88f141-284"},{"uid":"6a88f141-286"},{"uid":"6a88f141-288"},{"uid":"6a88f141-290"}],"importedBy":[{"uid":"6a88f141-294"}]},"6a88f141-294":{"id":"/node_modules/@stdlib/utils-type-of/lib/fixtures/nodelist.js","moduleParts":{"browser.js":"6a88f141-295"},"imported":[{"uid":"6a88f141-292"}],"importedBy":[{"uid":"6a88f141-298"}]},"6a88f141-296":{"id":"/node_modules/@stdlib/utils-type-of/lib/fixtures/typedarray.js","moduleParts":{"browser.js":"6a88f141-297"},"imported":[],"importedBy":[{"uid":"6a88f141-298"}]},"6a88f141-298":{"id":"/node_modules/@stdlib/utils-type-of/lib/check.js","moduleParts":{"browser.js":"6a88f141-299"},"imported":[{"uid":"6a88f141-268"},{"uid":"6a88f141-294"},{"uid":"6a88f141-296"}],"importedBy":[{"uid":"6a88f141-304"}]},"6a88f141-300":{"id":"/node_modules/@stdlib/utils-type-of/lib/main.js","moduleParts":{"browser.js":"6a88f141-301"},"imported":[{"uid":"6a88f141-402"}],"importedBy":[{"uid":"6a88f141-304"}]},"6a88f141-302":{"id":"/node_modules/@stdlib/utils-type-of/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-303"},"imported":[{"uid":"6a88f141-402"}],"importedBy":[{"uid":"6a88f141-304"}]},"6a88f141-304":{"id":"/node_modules/@stdlib/utils-type-of/lib/index.js","moduleParts":{"browser.js":"6a88f141-305"},"imported":[{"uid":"6a88f141-298"},{"uid":"6a88f141-300"},{"uid":"6a88f141-302"}],"importedBy":[{"uid":"6a88f141-306"}]},"6a88f141-306":{"id":"/node_modules/@stdlib/assert-is-function/lib/main.js","moduleParts":{"browser.js":"6a88f141-307"},"imported":[{"uid":"6a88f141-304"}],"importedBy":[{"uid":"6a88f141-422"}]},"6a88f141-308":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/tostring.js","moduleParts":{"browser.js":"6a88f141-309"},"imported":[],"importedBy":[{"uid":"6a88f141-312"}]},"6a88f141-310":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/tojson.js","moduleParts":{"browser.js":"6a88f141-311"},"imported":[],"importedBy":[{"uid":"6a88f141-312"}]},"6a88f141-312":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/main.js","moduleParts":{"browser.js":"6a88f141-313"},"imported":[{"uid":"6a88f141-218"},{"uid":"6a88f141-56"},{"uid":"6a88f141-416"},{"uid":"6a88f141-432"},{"uid":"6a88f141-308"},{"uid":"6a88f141-310"}],"importedBy":[{"uid":"6a88f141-450"}]},"6a88f141-314":{"id":"/node_modules/@stdlib/number-float64-base-to-float32/lib/main.js","moduleParts":{"browser.js":"6a88f141-315"},"imported":[],"importedBy":[{"uid":"6a88f141-318"}]},"6a88f141-316":{"id":"/node_modules/@stdlib/number-float64-base-to-float32/lib/polyfill.js","moduleParts":{"browser.js":"6a88f141-317"},"imported":[{"uid":"6a88f141-102"}],"importedBy":[{"uid":"6a88f141-318"}]},"6a88f141-318":{"id":"/node_modules/@stdlib/number-float64-base-to-float32/lib/index.js","moduleParts":{"browser.js":"6a88f141-319"},"imported":[{"uid":"6a88f141-314"},{"uid":"6a88f141-316"}],"importedBy":[{"uid":"6a88f141-344"},{"uid":"6a88f141-324"}]},"6a88f141-320":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/tostring.js","moduleParts":{"browser.js":"6a88f141-321"},"imported":[],"importedBy":[{"uid":"6a88f141-324"}]},"6a88f141-322":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/tojson.js","moduleParts":{"browser.js":"6a88f141-323"},"imported":[],"importedBy":[{"uid":"6a88f141-324"}]},"6a88f141-324":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/main.js","moduleParts":{"browser.js":"6a88f141-325"},"imported":[{"uid":"6a88f141-218"},{"uid":"6a88f141-56"},{"uid":"6a88f141-416"},{"uid":"6a88f141-318"},{"uid":"6a88f141-432"},{"uid":"6a88f141-320"},{"uid":"6a88f141-322"}],"importedBy":[{"uid":"6a88f141-451"}]},"6a88f141-326":{"id":"/node_modules/@stdlib/assert-is-complex-like/lib/main.js","moduleParts":{"browser.js":"6a88f141-327"},"imported":[{"uid":"6a88f141-450"},{"uid":"6a88f141-451"}],"importedBy":[{"uid":"6a88f141-423"}]},"6a88f141-328":{"id":"/node_modules/@stdlib/math-base-assert-is-even/lib/main.js","moduleParts":{"browser.js":"6a88f141-329"},"imported":[{"uid":"6a88f141-425"}],"importedBy":[{"uid":"6a88f141-424"}]},"6a88f141-330":{"id":"/node_modules/@stdlib/array-base-assert-is-complex64array/lib/main.js","moduleParts":{"browser.js":"6a88f141-331"},"imported":[],"importedBy":[{"uid":"6a88f141-426"}]},"6a88f141-332":{"id":"/node_modules/@stdlib/array-base-assert-is-complex128array/lib/main.js","moduleParts":{"browser.js":"6a88f141-333"},"imported":[],"importedBy":[{"uid":"6a88f141-427"}]},"6a88f141-334":{"id":"/node_modules/@stdlib/assert-has-iterator-symbol-support/lib/main.js","moduleParts":{"browser.js":"6a88f141-335"},"imported":[{"uid":"6a88f141-400"},{"uid":"6a88f141-404"}],"importedBy":[{"uid":"6a88f141-428"}]},"6a88f141-336":{"id":"/node_modules/@stdlib/symbol-iterator/lib/main.js","moduleParts":{"browser.js":"6a88f141-337"},"imported":[{"uid":"6a88f141-428"}],"importedBy":[{"uid":"6a88f141-429"}]},"6a88f141-338":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-accessor/lib/main.js","moduleParts":{"browser.js":"6a88f141-339"},"imported":[{"uid":"6a88f141-56"}],"importedBy":[{"uid":"6a88f141-430"}]},"6a88f141-340":{"id":"/node_modules/@stdlib/complex-float32/lib/tostring.js","moduleParts":{"browser.js":"6a88f141-341"},"imported":[],"importedBy":[{"uid":"6a88f141-344"}]},"6a88f141-342":{"id":"/node_modules/@stdlib/complex-float32/lib/tojson.js","moduleParts":{"browser.js":"6a88f141-343"},"imported":[],"importedBy":[{"uid":"6a88f141-344"}]},"6a88f141-344":{"id":"/node_modules/@stdlib/complex-float32/lib/main.js","moduleParts":{"browser.js":"6a88f141-345"},"imported":[{"uid":"6a88f141-218"},{"uid":"6a88f141-56"},{"uid":"6a88f141-416"},{"uid":"6a88f141-318"},{"uid":"6a88f141-432"},{"uid":"6a88f141-340"},{"uid":"6a88f141-342"}],"importedBy":[{"uid":"6a88f141-431"}]},"6a88f141-346":{"id":"/node_modules/@stdlib/complex-realf/lib/main.js","moduleParts":{"browser.js":"6a88f141-347"},"imported":[],"importedBy":[{"uid":"6a88f141-433"}]},"6a88f141-348":{"id":"/node_modules/@stdlib/complex-imagf/lib/main.js","moduleParts":{"browser.js":"6a88f141-349"},"imported":[],"importedBy":[{"uid":"6a88f141-434"}]},"6a88f141-350":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex64/lib/main.js","moduleParts":{"browser.js":"6a88f141-351"},"imported":[{"uid":"6a88f141-102"}],"importedBy":[{"uid":"6a88f141-436"}]},"6a88f141-352":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex128/lib/main.js","moduleParts":{"browser.js":"6a88f141-353"},"imported":[{"uid":"6a88f141-88"}],"importedBy":[{"uid":"6a88f141-437"}]},"6a88f141-354":{"id":"/node_modules/@stdlib/array-complex64/lib/from_iterator.js","moduleParts":{"browser.js":"6a88f141-355"},"imported":[{"uid":"6a88f141-418"},{"uid":"6a88f141-423"},{"uid":"6a88f141-433"},{"uid":"6a88f141-434"},{"uid":"6a88f141-432"}],"importedBy":[{"uid":"6a88f141-360"}]},"6a88f141-356":{"id":"/node_modules/@stdlib/array-complex64/lib/from_iterator_map.js","moduleParts":{"browser.js":"6a88f141-357"},"imported":[{"uid":"6a88f141-418"},{"uid":"6a88f141-423"},{"uid":"6a88f141-433"},{"uid":"6a88f141-434"},{"uid":"6a88f141-432"}],"importedBy":[{"uid":"6a88f141-360"}]},"6a88f141-358":{"id":"/node_modules/@stdlib/array-complex64/lib/from_array.js","moduleParts":{"browser.js":"6a88f141-359"},"imported":[{"uid":"6a88f141-423"},{"uid":"6a88f141-433"},{"uid":"6a88f141-434"}],"importedBy":[{"uid":"6a88f141-360"}]},"6a88f141-360":{"id":"/node_modules/@stdlib/array-complex64/lib/main.js","moduleParts":{"browser.js":"6a88f141-361"},"imported":[{"uid":"6a88f141-242"},{"uid":"6a88f141-418"},{"uid":"6a88f141-419"},{"uid":"6a88f141-420"},{"uid":"6a88f141-421"},{"uid":"6a88f141-393"},{"uid":"6a88f141-266"},{"uid":"6a88f141-422"},{"uid":"6a88f141-423"},{"uid":"6a88f141-424"},{"uid":"6a88f141-425"},{"uid":"6a88f141-426"},{"uid":"6a88f141-427"},{"uid":"6a88f141-428"},{"uid":"6a88f141-429"},{"uid":"6a88f141-416"},{"uid":"6a88f141-430"},{"uid":"6a88f141-102"},{"uid":"6a88f141-431"},{"uid":"6a88f141-432"},{"uid":"6a88f141-433"},{"uid":"6a88f141-434"},{"uid":"6a88f141-435"},{"uid":"6a88f141-436"},{"uid":"6a88f141-437"},{"uid":"6a88f141-397"},{"uid":"6a88f141-396"},{"uid":"6a88f141-354"},{"uid":"6a88f141-356"},{"uid":"6a88f141-358"}],"importedBy":[{"uid":"6a88f141-405"}]},"6a88f141-362":{"id":"/node_modules/@stdlib/complex-float64/lib/tostring.js","moduleParts":{"browser.js":"6a88f141-363"},"imported":[],"importedBy":[{"uid":"6a88f141-366"}]},"6a88f141-364":{"id":"/node_modules/@stdlib/complex-float64/lib/tojson.js","moduleParts":{"browser.js":"6a88f141-365"},"imported":[],"importedBy":[{"uid":"6a88f141-366"}]},"6a88f141-366":{"id":"/node_modules/@stdlib/complex-float64/lib/main.js","moduleParts":{"browser.js":"6a88f141-367"},"imported":[{"uid":"6a88f141-218"},{"uid":"6a88f141-56"},{"uid":"6a88f141-416"},{"uid":"6a88f141-432"},{"uid":"6a88f141-362"},{"uid":"6a88f141-364"}],"importedBy":[{"uid":"6a88f141-438"}]},"6a88f141-368":{"id":"/node_modules/@stdlib/complex-real/lib/main.js","moduleParts":{"browser.js":"6a88f141-369"},"imported":[],"importedBy":[{"uid":"6a88f141-439"}]},"6a88f141-370":{"id":"/node_modules/@stdlib/complex-imag/lib/main.js","moduleParts":{"browser.js":"6a88f141-371"},"imported":[],"importedBy":[{"uid":"6a88f141-440"}]},"6a88f141-372":{"id":"/node_modules/@stdlib/array-complex128/lib/from_iterator.js","moduleParts":{"browser.js":"6a88f141-373"},"imported":[{"uid":"6a88f141-418"},{"uid":"6a88f141-423"},{"uid":"6a88f141-432"},{"uid":"6a88f141-439"},{"uid":"6a88f141-440"}],"importedBy":[{"uid":"6a88f141-378"}]},"6a88f141-374":{"id":"/node_modules/@stdlib/array-complex128/lib/from_iterator_map.js","moduleParts":{"browser.js":"6a88f141-375"},"imported":[{"uid":"6a88f141-418"},{"uid":"6a88f141-423"},{"uid":"6a88f141-432"},{"uid":"6a88f141-439"},{"uid":"6a88f141-440"}],"importedBy":[{"uid":"6a88f141-378"}]},"6a88f141-376":{"id":"/node_modules/@stdlib/array-complex128/lib/from_array.js","moduleParts":{"browser.js":"6a88f141-377"},"imported":[{"uid":"6a88f141-423"},{"uid":"6a88f141-439"},{"uid":"6a88f141-440"}],"importedBy":[{"uid":"6a88f141-378"}]},"6a88f141-378":{"id":"/node_modules/@stdlib/array-complex128/lib/main.js","moduleParts":{"browser.js":"6a88f141-379"},"imported":[{"uid":"6a88f141-242"},{"uid":"6a88f141-418"},{"uid":"6a88f141-419"},{"uid":"6a88f141-420"},{"uid":"6a88f141-421"},{"uid":"6a88f141-393"},{"uid":"6a88f141-266"},{"uid":"6a88f141-422"},{"uid":"6a88f141-423"},{"uid":"6a88f141-424"},{"uid":"6a88f141-425"},{"uid":"6a88f141-426"},{"uid":"6a88f141-427"},{"uid":"6a88f141-428"},{"uid":"6a88f141-429"},{"uid":"6a88f141-416"},{"uid":"6a88f141-430"},{"uid":"6a88f141-88"},{"uid":"6a88f141-438"},{"uid":"6a88f141-439"},{"uid":"6a88f141-440"},{"uid":"6a88f141-435"},{"uid":"6a88f141-436"},{"uid":"6a88f141-437"},{"uid":"6a88f141-397"},{"uid":"6a88f141-396"},{"uid":"6a88f141-432"},{"uid":"6a88f141-372"},{"uid":"6a88f141-374"},{"uid":"6a88f141-376"}],"importedBy":[{"uid":"6a88f141-406"}]},"6a88f141-380":{"id":"/node_modules/@stdlib/array-dtype/lib/ctors.js","moduleParts":{"browser.js":"6a88f141-381"},"imported":[{"uid":"6a88f141-88"},{"uid":"6a88f141-102"},{"uid":"6a88f141-116"},{"uid":"6a88f141-132"},{"uid":"6a88f141-146"},{"uid":"6a88f141-162"},{"uid":"6a88f141-176"},{"uid":"6a88f141-188"},{"uid":"6a88f141-204"},{"uid":"6a88f141-405"},{"uid":"6a88f141-406"}],"importedBy":[{"uid":"6a88f141-384"}]},"6a88f141-382":{"id":"/node_modules/@stdlib/array-dtype/lib/dtypes.js","moduleParts":{"browser.js":"6a88f141-383"},"imported":[],"importedBy":[{"uid":"6a88f141-384"}]},"6a88f141-384":{"id":"/node_modules/@stdlib/array-dtype/lib/main.js","moduleParts":{"browser.js":"6a88f141-385"},"imported":[{"uid":"6a88f141-401"},{"uid":"6a88f141-393"},{"uid":"6a88f141-402"},{"uid":"6a88f141-76"},{"uid":"6a88f141-380"},{"uid":"6a88f141-382"}],"importedBy":[{"uid":"6a88f141-398"}]},"6a88f141-386":{"id":"/node_modules/@stdlib/array-base-resolve-getter/lib/main.js","moduleParts":{"browser.js":"6a88f141-387"},"imported":[{"uid":"6a88f141-395"},{"uid":"6a88f141-396"},{"uid":"6a88f141-397"},{"uid":"6a88f141-398"}],"importedBy":[{"uid":"6a88f141-394"}]},"6a88f141-388":{"id":"/lib/main.js","moduleParts":{"browser.js":"6a88f141-389"},"imported":[{"uid":"6a88f141-392"},{"uid":"6a88f141-393"},{"uid":"6a88f141-394"}],"importedBy":[{"uid":"6a88f141-390"}]},"6a88f141-390":{"id":"/lib/index.js","moduleParts":{"browser.js":"6a88f141-391"},"imported":[{"uid":"6a88f141-388"}],"importedBy":[],"isEntry":true},"6a88f141-392":{"id":"/node_modules/@stdlib/error-tools-fmtprodmsg/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-0"}],"importedBy":[{"uid":"6a88f141-388"}]},"6a88f141-393":{"id":"/node_modules/@stdlib/assert-is-array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-20"}],"importedBy":[{"uid":"6a88f141-388"},{"uid":"6a88f141-384"},{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-60"},{"uid":"6a88f141-254"}]},"6a88f141-394":{"id":"/node_modules/@stdlib/array-base-resolve-getter/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-386"}],"importedBy":[{"uid":"6a88f141-388"}]},"6a88f141-395":{"id":"/node_modules/@stdlib/array-base-assert-is-accessor-array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-22"}],"importedBy":[{"uid":"6a88f141-386"}]},"6a88f141-396":{"id":"/node_modules/@stdlib/array-base-accessor-getter/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-24"}],"importedBy":[{"uid":"6a88f141-386"},{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-397":{"id":"/node_modules/@stdlib/array-base-getter/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-26"}],"importedBy":[{"uid":"6a88f141-386"},{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-398":{"id":"/node_modules/@stdlib/array-dtype/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-384"}],"importedBy":[{"uid":"6a88f141-386"}]},"6a88f141-399":{"id":"/node_modules/@stdlib/assert-has-tostringtag-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-4"}],"importedBy":[{"uid":"6a88f141-18"},{"uid":"6a88f141-262"},{"uid":"6a88f141-214"},{"uid":"6a88f141-278"}]},"6a88f141-400":{"id":"/node_modules/@stdlib/assert-has-own-property/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-10"}],"importedBy":[{"uid":"6a88f141-16"},{"uid":"6a88f141-334"}]},"6a88f141-401":{"id":"/node_modules/@stdlib/assert-is-buffer/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-66"}],"importedBy":[{"uid":"6a88f141-384"},{"uid":"6a88f141-74"}]},"6a88f141-402":{"id":"/node_modules/@stdlib/utils-constructor-name/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-74"}],"importedBy":[{"uid":"6a88f141-384"},{"uid":"6a88f141-300"},{"uid":"6a88f141-302"}]},"6a88f141-403":{"id":"/node_modules/@stdlib/assert-has-symbol-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-2"}],"importedBy":[{"uid":"6a88f141-4"}]},"6a88f141-404":{"id":"/node_modules/@stdlib/symbol-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-12"}],"importedBy":[{"uid":"6a88f141-14"},{"uid":"6a88f141-334"}]},"6a88f141-405":{"id":"/node_modules/@stdlib/array-complex64/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-360"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-406":{"id":"/node_modules/@stdlib/array-complex128/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-378"}],"importedBy":[{"uid":"6a88f141-380"}]},"6a88f141-407":{"id":"/node_modules/@stdlib/assert-has-float64array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-82"}],"importedBy":[{"uid":"6a88f141-88"}]},"6a88f141-408":{"id":"/node_modules/@stdlib/assert-has-float32array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-96"}],"importedBy":[{"uid":"6a88f141-102"}]},"6a88f141-409":{"id":"/node_modules/@stdlib/assert-has-uint32array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-110"}],"importedBy":[{"uid":"6a88f141-116"}]},"6a88f141-410":{"id":"/node_modules/@stdlib/assert-has-int32array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-126"}],"importedBy":[{"uid":"6a88f141-132"}]},"6a88f141-411":{"id":"/node_modules/@stdlib/assert-has-uint16array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-140"}],"importedBy":[{"uid":"6a88f141-146"}]},"6a88f141-412":{"id":"/node_modules/@stdlib/assert-has-int16array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-156"}],"importedBy":[{"uid":"6a88f141-162"}]},"6a88f141-413":{"id":"/node_modules/@stdlib/assert-has-uint8array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-170"}],"importedBy":[{"uid":"6a88f141-176"}]},"6a88f141-414":{"id":"/node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-182"}],"importedBy":[{"uid":"6a88f141-188"}]},"6a88f141-415":{"id":"/node_modules/@stdlib/assert-has-int8array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-198"}],"importedBy":[{"uid":"6a88f141-204"}]},"6a88f141-416":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-property/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-58"}],"importedBy":[{"uid":"6a88f141-64"},{"uid":"6a88f141-72"},{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-242"},{"uid":"6a88f141-266"},{"uid":"6a88f141-344"},{"uid":"6a88f141-366"},{"uid":"6a88f141-234"},{"uid":"6a88f141-218"},{"uid":"6a88f141-312"},{"uid":"6a88f141-324"},{"uid":"6a88f141-282"}]},"6a88f141-417":{"id":"/node_modules/@stdlib/assert-tools-array-function/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-60"}],"importedBy":[{"uid":"6a88f141-64"}]},"6a88f141-418":{"id":"/node_modules/@stdlib/assert-is-array-like-object/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-246"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-354"},{"uid":"6a88f141-356"},{"uid":"6a88f141-372"},{"uid":"6a88f141-374"}]},"6a88f141-419":{"id":"/node_modules/@stdlib/assert-is-collection/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-250"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-420":{"id":"/node_modules/@stdlib/assert-is-arraybuffer/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-252"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-421":{"id":"/node_modules/@stdlib/assert-is-object/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-254"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-422":{"id":"/node_modules/@stdlib/assert-is-function/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-306"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-423":{"id":"/node_modules/@stdlib/assert-is-complex-like/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-326"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-354"},{"uid":"6a88f141-356"},{"uid":"6a88f141-358"},{"uid":"6a88f141-372"},{"uid":"6a88f141-374"},{"uid":"6a88f141-376"}]},"6a88f141-424":{"id":"/node_modules/@stdlib/math-base-assert-is-even/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-328"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-425":{"id":"/node_modules/@stdlib/math-base-assert-is-integer/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-224"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-246"},{"uid":"6a88f141-250"},{"uid":"6a88f141-328"},{"uid":"6a88f141-226"}]},"6a88f141-426":{"id":"/node_modules/@stdlib/array-base-assert-is-complex64array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-330"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-427":{"id":"/node_modules/@stdlib/array-base-assert-is-complex128array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-332"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-428":{"id":"/node_modules/@stdlib/assert-has-iterator-symbol-support/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-334"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-336"}]},"6a88f141-429":{"id":"/node_modules/@stdlib/symbol-iterator/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-336"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-430":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-accessor/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-338"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-431":{"id":"/node_modules/@stdlib/complex-float32/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-344"}],"importedBy":[{"uid":"6a88f141-360"}]},"6a88f141-432":{"id":"/node_modules/@stdlib/string-format/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-52"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-354"},{"uid":"6a88f141-356"},{"uid":"6a88f141-372"},{"uid":"6a88f141-374"},{"uid":"6a88f141-60"},{"uid":"6a88f141-344"},{"uid":"6a88f141-366"},{"uid":"6a88f141-54"},{"uid":"6a88f141-312"},{"uid":"6a88f141-324"},{"uid":"6a88f141-292"}]},"6a88f141-433":{"id":"/node_modules/@stdlib/complex-realf/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-346"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-354"},{"uid":"6a88f141-356"},{"uid":"6a88f141-358"}]},"6a88f141-434":{"id":"/node_modules/@stdlib/complex-imagf/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-348"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-354"},{"uid":"6a88f141-356"},{"uid":"6a88f141-358"}]},"6a88f141-435":{"id":"/node_modules/@stdlib/math-base-special-floor/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-222"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"},{"uid":"6a88f141-224"}]},"6a88f141-436":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex64/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-350"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-437":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex128/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-352"}],"importedBy":[{"uid":"6a88f141-360"},{"uid":"6a88f141-378"}]},"6a88f141-438":{"id":"/node_modules/@stdlib/complex-float64/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-366"}],"importedBy":[{"uid":"6a88f141-378"}]},"6a88f141-439":{"id":"/node_modules/@stdlib/complex-real/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-368"}],"importedBy":[{"uid":"6a88f141-378"},{"uid":"6a88f141-372"},{"uid":"6a88f141-374"},{"uid":"6a88f141-376"}]},"6a88f141-440":{"id":"/node_modules/@stdlib/complex-imag/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-370"}],"importedBy":[{"uid":"6a88f141-378"},{"uid":"6a88f141-372"},{"uid":"6a88f141-374"},{"uid":"6a88f141-376"}]},"6a88f141-441":{"id":"/node_modules/@stdlib/assert-is-float64array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-78"}],"importedBy":[{"uid":"6a88f141-82"}]},"6a88f141-442":{"id":"/node_modules/@stdlib/assert-is-float32array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-90"}],"importedBy":[{"uid":"6a88f141-96"}]},"6a88f141-443":{"id":"/node_modules/@stdlib/assert-is-uint32array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-104"}],"importedBy":[{"uid":"6a88f141-110"}]},"6a88f141-444":{"id":"/node_modules/@stdlib/assert-is-int32array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-118"}],"importedBy":[{"uid":"6a88f141-126"}]},"6a88f141-445":{"id":"/node_modules/@stdlib/assert-is-uint16array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-134"}],"importedBy":[{"uid":"6a88f141-140"}]},"6a88f141-446":{"id":"/node_modules/@stdlib/assert-is-int16array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-148"}],"importedBy":[{"uid":"6a88f141-156"}]},"6a88f141-447":{"id":"/node_modules/@stdlib/assert-is-uint8array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-164"}],"importedBy":[{"uid":"6a88f141-170"}]},"6a88f141-448":{"id":"/node_modules/@stdlib/assert-is-uint8clampedarray/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-178"}],"importedBy":[{"uid":"6a88f141-182"}]},"6a88f141-449":{"id":"/node_modules/@stdlib/assert-is-int8array/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-190"}],"importedBy":[{"uid":"6a88f141-198"}]},"6a88f141-450":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-312"}],"importedBy":[{"uid":"6a88f141-326"}]},"6a88f141-451":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-324"}],"importedBy":[{"uid":"6a88f141-326"}]},"6a88f141-452":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-46"}],"importedBy":[{"uid":"6a88f141-52"}]},"6a88f141-453":{"id":"/node_modules/@stdlib/string-base-format-tokenize/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-48"}],"importedBy":[{"uid":"6a88f141-52"}]},"6a88f141-454":{"id":"/node_modules/@stdlib/number-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-208"}],"importedBy":[{"uid":"6a88f141-214"},{"uid":"6a88f141-220"},{"uid":"6a88f141-210"}]},"6a88f141-455":{"id":"/node_modules/@stdlib/boolean-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"6a88f141-272"}],"importedBy":[{"uid":"6a88f141-278"}]}},"env":{"rollup":"4.11.0"},"options":{"gzip":false,"brotli":false,"sourcemap":false}}; + + const run = () => { + const width = window.innerWidth; + const height = window.innerHeight; + + const chartNode = document.querySelector("main"); + drawChart.default(chartNode, data, width, height); + }; + + window.addEventListener('resize', run); + + document.addEventListener('DOMContentLoaded', run); + /*-->*/ + </script> +</body> +</html> + diff --git a/stats_node.html b/stats_node.html new file mode 100644 index 0000000..42a4c82 --- /dev/null +++ b/stats_node.html @@ -0,0 +1,4842 @@ + +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta http-equiv="X-UA-Compatible" content="ie=edge" /> + <title>Rollup Visualizer</title> + <style> +:root { + --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, + "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; + --background-color: #2b2d42; + --text-color: #edf2f4; +} + +html { + box-sizing: border-box; +} + +*, +*:before, +*:after { + box-sizing: inherit; +} + +html { + background-color: var(--background-color); + color: var(--text-color); + font-family: var(--font-family); +} + +body { + padding: 0; + margin: 0; +} + +html, +body { + height: 100%; + width: 100%; + overflow: hidden; +} + +body { + display: flex; + flex-direction: column; +} + +svg { + vertical-align: middle; + width: 100%; + height: 100%; + max-height: 100vh; +} + +main { + flex-grow: 1; + height: 100vh; + padding: 20px; +} + +.tooltip { + position: absolute; + z-index: 1070; + border: 2px solid; + border-radius: 5px; + padding: 5px; + white-space: nowrap; + font-size: 0.875rem; + background-color: var(--background-color); + color: var(--text-color); +} + +.tooltip-hidden { + visibility: hidden; + opacity: 0; +} + +.sidebar { + position: fixed; + top: 0; + left: 0; + right: 0; + display: flex; + flex-direction: row; + font-size: 0.7rem; + align-items: center; + margin: 0 50px; + height: 20px; +} + +.size-selectors { + display: flex; + flex-direction: row; + align-items: center; +} + +.size-selector { + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + margin-right: 1rem; +} +.size-selector input { + margin: 0 0.3rem 0 0; +} + +.filters { + flex: 1; + display: flex; + flex-direction: row; + align-items: center; +} + +.module-filters { + display: flex; + flex-grow: 1; +} + +.module-filter { + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + flex: 1; +} +.module-filter input { + flex: 1; + height: 1rem; + padding: 0.01rem; + font-size: 0.7rem; + margin-left: 0.3rem; +} +.module-filter + .module-filter { + margin-left: 0.5rem; +} + +.node { + cursor: pointer; +} + </style> +</head> +<body> + <main></main> + <script> + /*<!--*/ +var drawChart = (function (exports) { + 'use strict'; + + var n,l$1,u$2,i$1,o$1,r$1,f$2,e$1,c$1={},s$1=[],a$1=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,h$1=Array.isArray;function v$1(n,l){for(var u in l)n[u]=l[u];return n}function p$1(n){var l=n.parentNode;l&&l.removeChild(n);}function y$1(l,u,t){var i,o,r,f={};for(r in u)"key"==r?i=u[r]:"ref"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),"function"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return d$1(l,f,i,o,null)}function d$1(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u$2:r,__i:-1,__u:0};return null==r&&null!=l$1.vnode&&l$1.vnode(f),f}function g$1(n){return n.children}function b$1(n,l){this.props=n,this.context=l;}function m$1(n,l){if(null==l)return n.__?m$1(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return "function"==typeof n.type?m$1(n):null}function k$1(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return k$1(n)}}function w$1(n){(!n.__d&&(n.__d=!0)&&i$1.push(n)&&!x.__r++||o$1!==l$1.debounceRendering)&&((o$1=l$1.debounceRendering)||r$1)(x);}function x(){var n,u,t,o,r,e,c,s,a;for(i$1.sort(f$2);n=i$1.shift();)n.__d&&(u=i$1.length,o=void 0,e=(r=(t=n).__v).__e,s=[],a=[],(c=t.__P)&&((o=v$1({},r)).__v=r.__v+1,l$1.vnode&&l$1.vnode(o),L(c,o,r,t.__n,void 0!==c.ownerSVGElement,32&r.__u?[e]:null,s,null==e?m$1(r):e,!!(32&r.__u),a),o.__.__k[o.__i]=o,M(s,o,a),o.__e!=e&&k$1(o)),i$1.length>u&&i$1.sort(f$2));x.__r=0;}function C(n,l,u,t,i,o,r,f,e,a,h){var v,p,y,d,_,g=t&&t.__k||s$1,b=l.length;for(u.__d=e,P(u,l,g),e=u.__d,v=0;v<b;v++)null!=(y=u.__k[v])&&"boolean"!=typeof y&&"function"!=typeof y&&(p=-1===y.__i?c$1:g[y.__i]||c$1,y.__i=v,L(n,y,p,i,o,r,f,e,a,h),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&z$1(p.ref,null,y),h.push(y.ref,y.__c||d,y)),null==_&&null!=d&&(_=d),65536&y.__u||p.__k===y.__k?e=S(y,e,n):"function"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=_;}function P(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)null!=(i=n.__k[t]=null==(i=l[t])||"boolean"==typeof i||"function"==typeof i?null:"string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?d$1(null,i,null,null,i):h$1(i)?d$1(g$1,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?d$1(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)?(i.__=n,i.__b=n.__b+1,f=H(i,u,r=t+a,s),i.__i=f,o=null,-1!==f&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,"function"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f===r+1?a++:f>r?s>e-r?a+=f-r:a--:a=f<r&&f==r-1?f-r:0,f!==t+a&&(i.__u|=65536))):(o=u[t])&&null==o.key&&o.__e&&(o.__e==n.__d&&(n.__d=m$1(o)),N(o,o,!1),u[t]=null,s--);if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=m$1(o)),N(o,o));}function S(n,l,u){var t,i;if("function"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=S(t[i],l,u));return l}return n.__e!=l&&(u.insertBefore(n.__e,l||null),l=n.__e),l&&l.nextSibling}function H(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type)return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--;}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++;}}return -1}function I(n,l,u){"-"===l[0]?n.setProperty(l,null==u?"":u):n[l]=null==u?"":"number"!=typeof u||a$1.test(l)?u:u+"px";}function T$1(n,l,u,t,i){var o;n:if("style"===l)if("string"==typeof u)n.style.cssText=u;else {if("string"==typeof t&&(n.style.cssText=t=""),t)for(l in t)u&&l in u||I(n.style,l,"");if(u)for(l in u)t&&u[l]===t[l]||I(n.style,l,u[l]);}else if("o"===l[0]&&"n"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/,"$1")),l=l.toLowerCase()in n?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=Date.now(),n.addEventListener(l,o?D:A,o)):n.removeEventListener(l,o?D:A,o);else {if(i)l=l.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!==l&&"height"!==l&&"href"!==l&&"list"!==l&&"form"!==l&&"tabIndex"!==l&&"download"!==l&&"rowSpan"!==l&&"colSpan"!==l&&"role"!==l&&l in n)try{n[l]=null==u?"":u;break n}catch(n){}"function"==typeof u||(null==u||!1===u&&"-"!==l[4]?n.removeAttribute(l):n.setAttribute(l,u));}}function A(n){var u=this.l[n.type+!1];if(n.t){if(n.t<=u.u)return}else n.t=Date.now();return u(l$1.event?l$1.event(n):n)}function D(n){return this.l[n.type+!0](l$1.event?l$1.event(n):n)}function L(n,u,t,i,o,r,f,e,c,s){var a,p,y,d,_,m,k,w,x,P,S,$,H,I,T,A=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l$1.__b)&&a(u);n:if("function"==typeof A)try{if(w=u.props,x=(a=A.contextType)&&i[a.__c],P=a?x?x.props.value:a.__:i,t.__c?k=(p=u.__c=t.__c).__=p.__E:("prototype"in A&&A.prototype.render?u.__c=p=new A(w,P):(u.__c=p=new b$1(w,P),p.constructor=A,p.render=O),x&&x.sub(p),p.props=w,p.state||(p.state={}),p.context=P,p.__n=i,y=p.__d=!0,p.__h=[],p._sb=[]),null==p.__s&&(p.__s=p.state),null!=A.getDerivedStateFromProps&&(p.__s==p.state&&(p.__s=v$1({},p.__s)),v$1(p.__s,A.getDerivedStateFromProps(w,p.__s))),d=p.props,_=p.state,p.__v=u,y)null==A.getDerivedStateFromProps&&null!=p.componentWillMount&&p.componentWillMount(),null!=p.componentDidMount&&p.__h.push(p.componentDidMount);else {if(null==A.getDerivedStateFromProps&&w!==d&&null!=p.componentWillReceiveProps&&p.componentWillReceiveProps(w,P),!p.__e&&(null!=p.shouldComponentUpdate&&!1===p.shouldComponentUpdate(w,p.__s,P)||u.__v===t.__v)){for(u.__v!==t.__v&&(p.props=w,p.state=p.__s,p.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.forEach(function(n){n&&(n.__=u);}),S=0;S<p._sb.length;S++)p.__h.push(p._sb[S]);p._sb=[],p.__h.length&&f.push(p);break n}null!=p.componentWillUpdate&&p.componentWillUpdate(w,p.__s,P),null!=p.componentDidUpdate&&p.__h.push(function(){p.componentDidUpdate(d,_,m);});}if(p.context=P,p.props=w,p.__P=n,p.__e=!1,$=l$1.__r,H=0,"prototype"in A&&A.prototype.render){for(p.state=p.__s,p.__d=!1,$&&$(u),a=p.render(p.props,p.state,p.context),I=0;I<p._sb.length;I++)p.__h.push(p._sb[I]);p._sb=[];}else do{p.__d=!1,$&&$(u),a=p.render(p.props,p.state,p.context),p.state=p.__s;}while(p.__d&&++H<25);p.state=p.__s,null!=p.getChildContext&&(i=v$1(v$1({},i),p.getChildContext())),y||null==p.getSnapshotBeforeUpdate||(m=p.getSnapshotBeforeUpdate(d,_)),C(n,h$1(T=null!=a&&a.type===g$1&&null==a.key?a.props.children:a)?T:[T],u,t,i,o,r,f,e,c,s),p.base=u.__e,u.__u&=-161,p.__h.length&&f.push(p),k&&(p.__E=p.__=null);}catch(n){u.__v=null,c||null!=r?(u.__e=e,u.__u|=c?160:32,r[r.indexOf(e)]=null):(u.__e=t.__e,u.__k=t.__k),l$1.__e(n,u,t);}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=j$1(t.__e,u,t,i,o,r,f,c,s);(a=l$1.diffed)&&a(u);}function M(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)z$1(t[i],t[++i],t[++i]);l$1.__c&&l$1.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u);});}catch(n){l$1.__e(n,u.__v);}});}function j$1(l,u,t,i,o,r,f,e,s){var a,v,y,d,_,g,b,k=t.props,w=u.props,x=u.type;if("svg"===x&&(o=!0),null!=r)for(a=0;a<r.length;a++)if((_=r[a])&&"setAttribute"in _==!!x&&(x?_.localName===x:3===_.nodeType)){l=_,r[a]=null;break}if(null==l){if(null===x)return document.createTextNode(w);l=o?document.createElementNS("http://www.w3.org/2000/svg",x):document.createElement(x,w.is&&w),r=null,e=!1;}if(null===x)k===w||e&&l.data===w||(l.data=w);else {if(r=r&&n.call(l.childNodes),k=t.props||c$1,!e&&null!=r)for(k={},a=0;a<l.attributes.length;a++)k[(_=l.attributes[a]).name]=_.value;for(a in k)_=k[a],"children"==a||("dangerouslySetInnerHTML"==a?y=_:"key"===a||a in w||T$1(l,a,null,_,o));for(a in w)_=w[a],"children"==a?d=_:"dangerouslySetInnerHTML"==a?v=_:"value"==a?g=_:"checked"==a?b=_:"key"===a||e&&"function"!=typeof _||k[a]===_||T$1(l,a,_,k[a],o);if(v)e||y&&(v.__html===y.__html||v.__html===l.innerHTML)||(l.innerHTML=v.__html),u.__k=[];else if(y&&(l.innerHTML=""),C(l,h$1(d)?d:[d],u,t,i,o&&"foreignObject"!==x,r,f,r?r[0]:t.__k&&m$1(t,0),e,s),null!=r)for(a=r.length;a--;)null!=r[a]&&p$1(r[a]);e||(a="value",void 0!==g&&(g!==l[a]||"progress"===x&&!g||"option"===x&&g!==k[a])&&T$1(l,a,g,k[a],!1),a="checked",void 0!==b&&b!==l[a]&&T$1(l,a,b,k[a],!1));}return l}function z$1(n,u,t){try{"function"==typeof n?n(u):n.current=u;}catch(n){l$1.__e(n,t);}}function N(n,u,t){var i,o;if(l$1.unmount&&l$1.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||z$1(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount();}catch(n){l$1.__e(n,u);}i.base=i.__P=null,n.__c=void 0;}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&N(i[o],u,t||"function"!=typeof n.type);t||null==n.__e||p$1(n.__e),n.__=n.__e=n.__d=void 0;}function O(n,l,u){return this.constructor(n,u)}function q$1(u,t,i){var o,r,f,e;l$1.__&&l$1.__(u,t),r=(o="function"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],L(t,u=(!o&&i||t).__k=y$1(g$1,null,[u]),r||c$1,c$1,void 0!==t.ownerSVGElement,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),M(f,u,e);}function F$1(n,l){var u={__c:l="__cC"+e$1++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,w$1(n);});},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u.splice(u.indexOf(n),1),l&&l.call(n);};}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=s$1.slice,l$1={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l;}throw n}},u$2=0,b$1.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=v$1({},this.state),"function"==typeof n&&(n=n(v$1({},u),this.props)),n&&v$1(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),w$1(this));},b$1.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),w$1(this));},b$1.prototype.render=g$1,i$1=[],r$1="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f$2=function(n,l){return n.__v.__b-l.__v.__b},x.__r=0,e$1=0; + + var f$1=0;function u$1(e,t,n,o,i,u){var a,c,p={};for(c in t)"ref"==c?a=t[c]:p[c]=t[c];var l={type:e,props:p,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f$1,__i:-1,__u:0,__source:i,__self:u};if("function"==typeof e&&(a=e.defaultProps))for(c in a)void 0===p[c]&&(p[c]=a[c]);return l$1.vnode&&l$1.vnode(l),l} + + function count$1(node) { + var sum = 0, + children = node.children, + i = children && children.length; + if (!i) sum = 1; + else while (--i >= 0) sum += children[i].value; + node.value = sum; + } + + function node_count() { + return this.eachAfter(count$1); + } + + function node_each(callback, that) { + let index = -1; + for (const node of this) { + callback.call(that, node, ++index, this); + } + return this; + } + + function node_eachBefore(callback, that) { + var node = this, nodes = [node], children, i, index = -1; + while (node = nodes.pop()) { + callback.call(that, node, ++index, this); + if (children = node.children) { + for (i = children.length - 1; i >= 0; --i) { + nodes.push(children[i]); + } + } + } + return this; + } + + function node_eachAfter(callback, that) { + var node = this, nodes = [node], next = [], children, i, n, index = -1; + while (node = nodes.pop()) { + next.push(node); + if (children = node.children) { + for (i = 0, n = children.length; i < n; ++i) { + nodes.push(children[i]); + } + } + } + while (node = next.pop()) { + callback.call(that, node, ++index, this); + } + return this; + } + + function node_find(callback, that) { + let index = -1; + for (const node of this) { + if (callback.call(that, node, ++index, this)) { + return node; + } + } + } + + function node_sum(value) { + return this.eachAfter(function(node) { + var sum = +value(node.data) || 0, + children = node.children, + i = children && children.length; + while (--i >= 0) sum += children[i].value; + node.value = sum; + }); + } + + function node_sort(compare) { + return this.eachBefore(function(node) { + if (node.children) { + node.children.sort(compare); + } + }); + } + + function node_path(end) { + var start = this, + ancestor = leastCommonAncestor(start, end), + nodes = [start]; + while (start !== ancestor) { + start = start.parent; + nodes.push(start); + } + var k = nodes.length; + while (end !== ancestor) { + nodes.splice(k, 0, end); + end = end.parent; + } + return nodes; + } + + function leastCommonAncestor(a, b) { + if (a === b) return a; + var aNodes = a.ancestors(), + bNodes = b.ancestors(), + c = null; + a = aNodes.pop(); + b = bNodes.pop(); + while (a === b) { + c = a; + a = aNodes.pop(); + b = bNodes.pop(); + } + return c; + } + + function node_ancestors() { + var node = this, nodes = [node]; + while (node = node.parent) { + nodes.push(node); + } + return nodes; + } + + function node_descendants() { + return Array.from(this); + } + + function node_leaves() { + var leaves = []; + this.eachBefore(function(node) { + if (!node.children) { + leaves.push(node); + } + }); + return leaves; + } + + function node_links() { + var root = this, links = []; + root.each(function(node) { + if (node !== root) { // Don’t include the root’s parent, if any. + links.push({source: node.parent, target: node}); + } + }); + return links; + } + + function* node_iterator() { + var node = this, current, next = [node], children, i, n; + do { + current = next.reverse(), next = []; + while (node = current.pop()) { + yield node; + if (children = node.children) { + for (i = 0, n = children.length; i < n; ++i) { + next.push(children[i]); + } + } + } + } while (next.length); + } + + function hierarchy(data, children) { + if (data instanceof Map) { + data = [undefined, data]; + if (children === undefined) children = mapChildren; + } else if (children === undefined) { + children = objectChildren; + } + + var root = new Node$1(data), + node, + nodes = [root], + child, + childs, + i, + n; + + while (node = nodes.pop()) { + if ((childs = children(node.data)) && (n = (childs = Array.from(childs)).length)) { + node.children = childs; + for (i = n - 1; i >= 0; --i) { + nodes.push(child = childs[i] = new Node$1(childs[i])); + child.parent = node; + child.depth = node.depth + 1; + } + } + } + + return root.eachBefore(computeHeight); + } + + function node_copy() { + return hierarchy(this).eachBefore(copyData); + } + + function objectChildren(d) { + return d.children; + } + + function mapChildren(d) { + return Array.isArray(d) ? d[1] : null; + } + + function copyData(node) { + if (node.data.value !== undefined) node.value = node.data.value; + node.data = node.data.data; + } + + function computeHeight(node) { + var height = 0; + do node.height = height; + while ((node = node.parent) && (node.height < ++height)); + } + + function Node$1(data) { + this.data = data; + this.depth = + this.height = 0; + this.parent = null; + } + + Node$1.prototype = hierarchy.prototype = { + constructor: Node$1, + count: node_count, + each: node_each, + eachAfter: node_eachAfter, + eachBefore: node_eachBefore, + find: node_find, + sum: node_sum, + sort: node_sort, + path: node_path, + ancestors: node_ancestors, + descendants: node_descendants, + leaves: node_leaves, + links: node_links, + copy: node_copy, + [Symbol.iterator]: node_iterator + }; + + function required(f) { + if (typeof f !== "function") throw new Error; + return f; + } + + function constantZero() { + return 0; + } + + function constant$1(x) { + return function() { + return x; + }; + } + + function roundNode(node) { + node.x0 = Math.round(node.x0); + node.y0 = Math.round(node.y0); + node.x1 = Math.round(node.x1); + node.y1 = Math.round(node.y1); + } + + function treemapDice(parent, x0, y0, x1, y1) { + var nodes = parent.children, + node, + i = -1, + n = nodes.length, + k = parent.value && (x1 - x0) / parent.value; + + while (++i < n) { + node = nodes[i], node.y0 = y0, node.y1 = y1; + node.x0 = x0, node.x1 = x0 += node.value * k; + } + } + + function treemapSlice(parent, x0, y0, x1, y1) { + var nodes = parent.children, + node, + i = -1, + n = nodes.length, + k = parent.value && (y1 - y0) / parent.value; + + while (++i < n) { + node = nodes[i], node.x0 = x0, node.x1 = x1; + node.y0 = y0, node.y1 = y0 += node.value * k; + } + } + + var phi = (1 + Math.sqrt(5)) / 2; + + function squarifyRatio(ratio, parent, x0, y0, x1, y1) { + var rows = [], + nodes = parent.children, + row, + nodeValue, + i0 = 0, + i1 = 0, + n = nodes.length, + dx, dy, + value = parent.value, + sumValue, + minValue, + maxValue, + newRatio, + minRatio, + alpha, + beta; + + while (i0 < n) { + dx = x1 - x0, dy = y1 - y0; + + // Find the next non-empty node. + do sumValue = nodes[i1++].value; while (!sumValue && i1 < n); + minValue = maxValue = sumValue; + alpha = Math.max(dy / dx, dx / dy) / (value * ratio); + beta = sumValue * sumValue * alpha; + minRatio = Math.max(maxValue / beta, beta / minValue); + + // Keep adding nodes while the aspect ratio maintains or improves. + for (; i1 < n; ++i1) { + sumValue += nodeValue = nodes[i1].value; + if (nodeValue < minValue) minValue = nodeValue; + if (nodeValue > maxValue) maxValue = nodeValue; + beta = sumValue * sumValue * alpha; + newRatio = Math.max(maxValue / beta, beta / minValue); + if (newRatio > minRatio) { sumValue -= nodeValue; break; } + minRatio = newRatio; + } + + // Position and record the row orientation. + rows.push(row = {value: sumValue, dice: dx < dy, children: nodes.slice(i0, i1)}); + if (row.dice) treemapDice(row, x0, y0, x1, value ? y0 += dy * sumValue / value : y1); + else treemapSlice(row, x0, y0, value ? x0 += dx * sumValue / value : x1, y1); + value -= sumValue, i0 = i1; + } + + return rows; + } + + var squarify = (function custom(ratio) { + + function squarify(parent, x0, y0, x1, y1) { + squarifyRatio(ratio, parent, x0, y0, x1, y1); + } + + squarify.ratio = function(x) { + return custom((x = +x) > 1 ? x : 1); + }; + + return squarify; + })(phi); + + function treemap() { + var tile = squarify, + round = false, + dx = 1, + dy = 1, + paddingStack = [0], + paddingInner = constantZero, + paddingTop = constantZero, + paddingRight = constantZero, + paddingBottom = constantZero, + paddingLeft = constantZero; + + function treemap(root) { + root.x0 = + root.y0 = 0; + root.x1 = dx; + root.y1 = dy; + root.eachBefore(positionNode); + paddingStack = [0]; + if (round) root.eachBefore(roundNode); + return root; + } + + function positionNode(node) { + var p = paddingStack[node.depth], + x0 = node.x0 + p, + y0 = node.y0 + p, + x1 = node.x1 - p, + y1 = node.y1 - p; + if (x1 < x0) x0 = x1 = (x0 + x1) / 2; + if (y1 < y0) y0 = y1 = (y0 + y1) / 2; + node.x0 = x0; + node.y0 = y0; + node.x1 = x1; + node.y1 = y1; + if (node.children) { + p = paddingStack[node.depth + 1] = paddingInner(node) / 2; + x0 += paddingLeft(node) - p; + y0 += paddingTop(node) - p; + x1 -= paddingRight(node) - p; + y1 -= paddingBottom(node) - p; + if (x1 < x0) x0 = x1 = (x0 + x1) / 2; + if (y1 < y0) y0 = y1 = (y0 + y1) / 2; + tile(node, x0, y0, x1, y1); + } + } + + treemap.round = function(x) { + return arguments.length ? (round = !!x, treemap) : round; + }; + + treemap.size = function(x) { + return arguments.length ? (dx = +x[0], dy = +x[1], treemap) : [dx, dy]; + }; + + treemap.tile = function(x) { + return arguments.length ? (tile = required(x), treemap) : tile; + }; + + treemap.padding = function(x) { + return arguments.length ? treemap.paddingInner(x).paddingOuter(x) : treemap.paddingInner(); + }; + + treemap.paddingInner = function(x) { + return arguments.length ? (paddingInner = typeof x === "function" ? x : constant$1(+x), treemap) : paddingInner; + }; + + treemap.paddingOuter = function(x) { + return arguments.length ? treemap.paddingTop(x).paddingRight(x).paddingBottom(x).paddingLeft(x) : treemap.paddingTop(); + }; + + treemap.paddingTop = function(x) { + return arguments.length ? (paddingTop = typeof x === "function" ? x : constant$1(+x), treemap) : paddingTop; + }; + + treemap.paddingRight = function(x) { + return arguments.length ? (paddingRight = typeof x === "function" ? x : constant$1(+x), treemap) : paddingRight; + }; + + treemap.paddingBottom = function(x) { + return arguments.length ? (paddingBottom = typeof x === "function" ? x : constant$1(+x), treemap) : paddingBottom; + }; + + treemap.paddingLeft = function(x) { + return arguments.length ? (paddingLeft = typeof x === "function" ? x : constant$1(+x), treemap) : paddingLeft; + }; + + return treemap; + } + + var treemapResquarify = (function custom(ratio) { + + function resquarify(parent, x0, y0, x1, y1) { + if ((rows = parent._squarify) && (rows.ratio === ratio)) { + var rows, + row, + nodes, + i, + j = -1, + n, + m = rows.length, + value = parent.value; + + while (++j < m) { + row = rows[j], nodes = row.children; + for (i = row.value = 0, n = nodes.length; i < n; ++i) row.value += nodes[i].value; + if (row.dice) treemapDice(row, x0, y0, x1, value ? y0 += (y1 - y0) * row.value / value : y1); + else treemapSlice(row, x0, y0, value ? x0 += (x1 - x0) * row.value / value : x1, y1); + value -= row.value; + } + } else { + parent._squarify = rows = squarifyRatio(ratio, parent, x0, y0, x1, y1); + rows.ratio = ratio; + } + } + + resquarify.ratio = function(x) { + return custom((x = +x) > 1 ? x : 1); + }; + + return resquarify; + })(phi); + + const isModuleTree = (mod) => "children" in mod; + + let count = 0; + class Id { + constructor(id) { + this._id = id; + const url = new URL(window.location.href); + url.hash = id; + this._href = url.toString(); + } + get id() { + return this._id; + } + get href() { + return this._href; + } + toString() { + return `url(${this.href})`; + } + } + function generateUniqueId(name) { + count += 1; + const id = ["O", name, count].filter(Boolean).join("-"); + return new Id(id); + } + + const LABELS = { + renderedLength: "Rendered", + gzipLength: "Gzip", + brotliLength: "Brotli", + }; + const getAvailableSizeOptions = (options) => { + const availableSizeProperties = ["renderedLength"]; + if (options.gzip) { + availableSizeProperties.push("gzipLength"); + } + if (options.brotli) { + availableSizeProperties.push("brotliLength"); + } + return availableSizeProperties; + }; + + var t,r,u,i,o=0,f=[],c=[],e=l$1.__b,a=l$1.__r,v=l$1.diffed,l=l$1.__c,m=l$1.unmount;function d(t,u){l$1.__h&&l$1.__h(r,t,o||u),o=0;var i=r.__H||(r.__H={__:[],__h:[]});return t>=i.__.length&&i.__.push({__V:c}),i.__[t]}function h(n){return o=1,s(B,n)}function s(n,u,i){var o=d(t++,2);if(o.t=n,!o.__c&&(o.__=[i?i(u):B(void 0,u),function(n){var t=o.__N?o.__N[0]:o.__[0],r=o.t(t,n);t!==r&&(o.__N=[r,o.__[1]],o.__c.setState({}));}],o.__c=r,!r.u)){var f=function(n,t,r){if(!o.__c.__H)return !0;var u=o.__c.__H.__.filter(function(n){return n.__c});if(u.every(function(n){return !n.__N}))return !c||c.call(this,n,t,r);var i=!1;return u.forEach(function(n){if(n.__N){var t=n.__[0];n.__=n.__N,n.__N=void 0,t!==n.__[0]&&(i=!0);}}),!(!i&&o.__c.props===n)&&(!c||c.call(this,n,t,r))};r.u=!0;var c=r.shouldComponentUpdate,e=r.componentWillUpdate;r.componentWillUpdate=function(n,t,r){if(this.__e){var u=c;c=void 0,f(n,t,r),c=u;}e&&e.call(this,n,t,r);},r.shouldComponentUpdate=f;}return o.__N||o.__}function p(u,i){var o=d(t++,3);!l$1.__s&&z(o.__H,i)&&(o.__=u,o.i=i,r.__H.__h.push(o));}function y(u,i){var o=d(t++,4);!l$1.__s&&z(o.__H,i)&&(o.__=u,o.i=i,r.__h.push(o));}function _(n){return o=5,F(function(){return {current:n}},[])}function F(n,r){var u=d(t++,7);return z(u.__H,r)?(u.__V=n(),u.i=r,u.__h=n,u.__V):u.__}function T(n,t){return o=8,F(function(){return n},t)}function q(n){var u=r.context[n.__c],i=d(t++,9);return i.c=n,u?(null==i.__&&(i.__=!0,u.sub(r)),u.props.value):n.__}function b(){for(var t;t=f.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(k),t.__H.__h.forEach(w),t.__H.__h=[];}catch(r){t.__H.__h=[],l$1.__e(r,t.__v);}}l$1.__b=function(n){r=null,e&&e(n);},l$1.__r=function(n){a&&a(n),t=0;var i=(r=n.__c).__H;i&&(u===r?(i.__h=[],r.__h=[],i.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=c,n.__N=n.i=void 0;})):(i.__h.forEach(k),i.__h.forEach(w),i.__h=[],t=0)),u=r;},l$1.diffed=function(t){v&&v(t);var o=t.__c;o&&o.__H&&(o.__H.__h.length&&(1!==f.push(o)&&i===l$1.requestAnimationFrame||((i=l$1.requestAnimationFrame)||j)(b)),o.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==c&&(n.__=n.__V),n.i=void 0,n.__V=c;})),u=r=null;},l$1.__c=function(t,r){r.some(function(t){try{t.__h.forEach(k),t.__h=t.__h.filter(function(n){return !n.__||w(n)});}catch(u){r.some(function(n){n.__h&&(n.__h=[]);}),r=[],l$1.__e(u,t.__v);}}),l&&l(t,r);},l$1.unmount=function(t){m&&m(t);var r,u=t.__c;u&&u.__H&&(u.__H.__.forEach(function(n){try{k(n);}catch(n){r=n;}}),u.__H=void 0,r&&l$1.__e(r,u.__v));};var g="function"==typeof requestAnimationFrame;function j(n){var t,r=function(){clearTimeout(u),g&&cancelAnimationFrame(t),setTimeout(n);},u=setTimeout(r,100);g&&(t=requestAnimationFrame(r));}function k(n){var t=r,u=n.__c;"function"==typeof u&&(n.__c=void 0,u()),r=t;}function w(n){var t=r;n.__c=n.__(),r=t;}function z(n,t){return !n||n.length!==t.length||t.some(function(t,r){return t!==n[r]})}function B(n,t){return "function"==typeof t?t(n):t} + + const PLACEHOLDER = "*/**/file.js"; + const SideBar = ({ availableSizeProperties, sizeProperty, setSizeProperty, onExcludeChange, onIncludeChange, }) => { + const [includeValue, setIncludeValue] = h(""); + const [excludeValue, setExcludeValue] = h(""); + const handleSizePropertyChange = (sizeProp) => () => { + if (sizeProp !== sizeProperty) { + setSizeProperty(sizeProp); + } + }; + const handleIncludeChange = (event) => { + const value = event.currentTarget.value; + setIncludeValue(value); + onIncludeChange(value); + }; + const handleExcludeChange = (event) => { + const value = event.currentTarget.value; + setExcludeValue(value); + onExcludeChange(value); + }; + return (u$1("aside", { className: "sidebar", children: [u$1("div", { className: "size-selectors", children: availableSizeProperties.length > 1 && + availableSizeProperties.map((sizeProp) => { + const id = `selector-${sizeProp}`; + return (u$1("div", { className: "size-selector", children: [u$1("input", { type: "radio", id: id, checked: sizeProp === sizeProperty, onChange: handleSizePropertyChange(sizeProp) }), u$1("label", { htmlFor: id, children: LABELS[sizeProp] })] }, sizeProp)); + }) }), u$1("div", { className: "module-filters", children: [u$1("div", { className: "module-filter", children: [u$1("label", { htmlFor: "module-filter-exclude", children: "Exclude" }), u$1("input", { type: "text", id: "module-filter-exclude", value: excludeValue, onInput: handleExcludeChange, placeholder: PLACEHOLDER })] }), u$1("div", { className: "module-filter", children: [u$1("label", { htmlFor: "module-filter-include", children: "Include" }), u$1("input", { type: "text", id: "module-filter-include", value: includeValue, onInput: handleIncludeChange, placeholder: PLACEHOLDER })] })] })] })); + }; + + function getDefaultExportFromCjs (x) { + return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x; + } + + var utils$3 = {}; + + const WIN_SLASH = '\\\\/'; + const WIN_NO_SLASH = `[^${WIN_SLASH}]`; + + /** + * Posix glob regex + */ + + const DOT_LITERAL = '\\.'; + const PLUS_LITERAL = '\\+'; + const QMARK_LITERAL = '\\?'; + const SLASH_LITERAL = '\\/'; + const ONE_CHAR = '(?=.)'; + const QMARK = '[^/]'; + const END_ANCHOR = `(?:${SLASH_LITERAL}|$)`; + const START_ANCHOR = `(?:^|${SLASH_LITERAL})`; + const DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`; + const NO_DOT = `(?!${DOT_LITERAL})`; + const NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`; + const NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`; + const NO_DOTS_SLASH = `(?!${DOTS_SLASH})`; + const QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`; + const STAR = `${QMARK}*?`; + const SEP = '/'; + + const POSIX_CHARS = { + DOT_LITERAL, + PLUS_LITERAL, + QMARK_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + QMARK, + END_ANCHOR, + DOTS_SLASH, + NO_DOT, + NO_DOTS, + NO_DOT_SLASH, + NO_DOTS_SLASH, + QMARK_NO_DOT, + STAR, + START_ANCHOR, + SEP + }; + + /** + * Windows glob regex + */ + + const WINDOWS_CHARS = { + ...POSIX_CHARS, + + SLASH_LITERAL: `[${WIN_SLASH}]`, + QMARK: WIN_NO_SLASH, + STAR: `${WIN_NO_SLASH}*?`, + DOTS_SLASH: `${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$)`, + NO_DOT: `(?!${DOT_LITERAL})`, + NO_DOTS: `(?!(?:^|[${WIN_SLASH}])${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, + NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}(?:[${WIN_SLASH}]|$))`, + NO_DOTS_SLASH: `(?!${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, + QMARK_NO_DOT: `[^.${WIN_SLASH}]`, + START_ANCHOR: `(?:^|[${WIN_SLASH}])`, + END_ANCHOR: `(?:[${WIN_SLASH}]|$)`, + SEP: '\\' + }; + + /** + * POSIX Bracket Regex + */ + + const POSIX_REGEX_SOURCE$1 = { + alnum: 'a-zA-Z0-9', + alpha: 'a-zA-Z', + ascii: '\\x00-\\x7F', + blank: ' \\t', + cntrl: '\\x00-\\x1F\\x7F', + digit: '0-9', + graph: '\\x21-\\x7E', + lower: 'a-z', + print: '\\x20-\\x7E ', + punct: '\\-!"#$%&\'()\\*+,./:;<=>?@[\\]^_`{|}~', + space: ' \\t\\r\\n\\v\\f', + upper: 'A-Z', + word: 'A-Za-z0-9_', + xdigit: 'A-Fa-f0-9' + }; + + var constants$3 = { + MAX_LENGTH: 1024 * 64, + POSIX_REGEX_SOURCE: POSIX_REGEX_SOURCE$1, + + // regular expressions + REGEX_BACKSLASH: /\\(?![*+?^${}(|)[\]])/g, + REGEX_NON_SPECIAL_CHARS: /^[^@![\].,$*+?^{}()|\\/]+/, + REGEX_SPECIAL_CHARS: /[-*+?.^${}(|)[\]]/, + REGEX_SPECIAL_CHARS_BACKREF: /(\\?)((\W)(\3*))/g, + REGEX_SPECIAL_CHARS_GLOBAL: /([-*+?.^${}(|)[\]])/g, + REGEX_REMOVE_BACKSLASH: /(?:\[.*?[^\\]\]|\\(?=.))/g, + + // Replace globs with equivalent patterns to reduce parsing time. + REPLACEMENTS: { + '***': '*', + '**/**': '**', + '**/**/**': '**' + }, + + // Digits + CHAR_0: 48, /* 0 */ + CHAR_9: 57, /* 9 */ + + // Alphabet chars. + CHAR_UPPERCASE_A: 65, /* A */ + CHAR_LOWERCASE_A: 97, /* a */ + CHAR_UPPERCASE_Z: 90, /* Z */ + CHAR_LOWERCASE_Z: 122, /* z */ + + CHAR_LEFT_PARENTHESES: 40, /* ( */ + CHAR_RIGHT_PARENTHESES: 41, /* ) */ + + CHAR_ASTERISK: 42, /* * */ + + // Non-alphabetic chars. + CHAR_AMPERSAND: 38, /* & */ + CHAR_AT: 64, /* @ */ + CHAR_BACKWARD_SLASH: 92, /* \ */ + CHAR_CARRIAGE_RETURN: 13, /* \r */ + CHAR_CIRCUMFLEX_ACCENT: 94, /* ^ */ + CHAR_COLON: 58, /* : */ + CHAR_COMMA: 44, /* , */ + CHAR_DOT: 46, /* . */ + CHAR_DOUBLE_QUOTE: 34, /* " */ + CHAR_EQUAL: 61, /* = */ + CHAR_EXCLAMATION_MARK: 33, /* ! */ + CHAR_FORM_FEED: 12, /* \f */ + CHAR_FORWARD_SLASH: 47, /* / */ + CHAR_GRAVE_ACCENT: 96, /* ` */ + CHAR_HASH: 35, /* # */ + CHAR_HYPHEN_MINUS: 45, /* - */ + CHAR_LEFT_ANGLE_BRACKET: 60, /* < */ + CHAR_LEFT_CURLY_BRACE: 123, /* { */ + CHAR_LEFT_SQUARE_BRACKET: 91, /* [ */ + CHAR_LINE_FEED: 10, /* \n */ + CHAR_NO_BREAK_SPACE: 160, /* \u00A0 */ + CHAR_PERCENT: 37, /* % */ + CHAR_PLUS: 43, /* + */ + CHAR_QUESTION_MARK: 63, /* ? */ + CHAR_RIGHT_ANGLE_BRACKET: 62, /* > */ + CHAR_RIGHT_CURLY_BRACE: 125, /* } */ + CHAR_RIGHT_SQUARE_BRACKET: 93, /* ] */ + CHAR_SEMICOLON: 59, /* ; */ + CHAR_SINGLE_QUOTE: 39, /* ' */ + CHAR_SPACE: 32, /* */ + CHAR_TAB: 9, /* \t */ + CHAR_UNDERSCORE: 95, /* _ */ + CHAR_VERTICAL_LINE: 124, /* | */ + CHAR_ZERO_WIDTH_NOBREAK_SPACE: 65279, /* \uFEFF */ + + /** + * Create EXTGLOB_CHARS + */ + + extglobChars(chars) { + return { + '!': { type: 'negate', open: '(?:(?!(?:', close: `))${chars.STAR})` }, + '?': { type: 'qmark', open: '(?:', close: ')?' }, + '+': { type: 'plus', open: '(?:', close: ')+' }, + '*': { type: 'star', open: '(?:', close: ')*' }, + '@': { type: 'at', open: '(?:', close: ')' } + }; + }, + + /** + * Create GLOB_CHARS + */ + + globChars(win32) { + return win32 === true ? WINDOWS_CHARS : POSIX_CHARS; + } + }; + + (function (exports) { + + const { + REGEX_BACKSLASH, + REGEX_REMOVE_BACKSLASH, + REGEX_SPECIAL_CHARS, + REGEX_SPECIAL_CHARS_GLOBAL + } = constants$3; + + exports.isObject = val => val !== null && typeof val === 'object' && !Array.isArray(val); + exports.hasRegexChars = str => REGEX_SPECIAL_CHARS.test(str); + exports.isRegexChar = str => str.length === 1 && exports.hasRegexChars(str); + exports.escapeRegex = str => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, '\\$1'); + exports.toPosixSlashes = str => str.replace(REGEX_BACKSLASH, '/'); + + exports.removeBackslashes = str => { + return str.replace(REGEX_REMOVE_BACKSLASH, match => { + return match === '\\' ? '' : match; + }); + }; + + exports.supportsLookbehinds = () => { + const segs = process.version.slice(1).split('.').map(Number); + if (segs.length === 3 && segs[0] >= 9 || (segs[0] === 8 && segs[1] >= 10)) { + return true; + } + return false; + }; + + exports.escapeLast = (input, char, lastIdx) => { + const idx = input.lastIndexOf(char, lastIdx); + if (idx === -1) return input; + if (input[idx - 1] === '\\') return exports.escapeLast(input, char, idx - 1); + return `${input.slice(0, idx)}\\${input.slice(idx)}`; + }; + + exports.removePrefix = (input, state = {}) => { + let output = input; + if (output.startsWith('./')) { + output = output.slice(2); + state.prefix = './'; + } + return output; + }; + + exports.wrapOutput = (input, state = {}, options = {}) => { + const prepend = options.contains ? '' : '^'; + const append = options.contains ? '' : '$'; + + let output = `${prepend}(?:${input})${append}`; + if (state.negated === true) { + output = `(?:^(?!${output}).*$)`; + } + return output; + }; + + exports.basename = (path, { windows } = {}) => { + if (windows) { + return path.replace(/[\\/]$/, '').replace(/.*[\\/]/, ''); + } else { + return path.replace(/\/$/, '').replace(/.*\//, ''); + } + }; + } (utils$3)); + + const utils$2 = utils$3; + const { + CHAR_ASTERISK, /* * */ + CHAR_AT, /* @ */ + CHAR_BACKWARD_SLASH, /* \ */ + CHAR_COMMA, /* , */ + CHAR_DOT, /* . */ + CHAR_EXCLAMATION_MARK, /* ! */ + CHAR_FORWARD_SLASH, /* / */ + CHAR_LEFT_CURLY_BRACE, /* { */ + CHAR_LEFT_PARENTHESES, /* ( */ + CHAR_LEFT_SQUARE_BRACKET, /* [ */ + CHAR_PLUS, /* + */ + CHAR_QUESTION_MARK, /* ? */ + CHAR_RIGHT_CURLY_BRACE, /* } */ + CHAR_RIGHT_PARENTHESES, /* ) */ + CHAR_RIGHT_SQUARE_BRACKET /* ] */ + } = constants$3; + + const isPathSeparator = code => { + return code === CHAR_FORWARD_SLASH || code === CHAR_BACKWARD_SLASH; + }; + + const depth = token => { + if (token.isPrefix !== true) { + token.depth = token.isGlobstar ? Infinity : 1; + } + }; + + /** + * Quickly scans a glob pattern and returns an object with a handful of + * useful properties, like `isGlob`, `path` (the leading non-glob, if it exists), + * `glob` (the actual pattern), and `negated` (true if the path starts with `!`). + * + * ```js + * const pm = require('picomatch'); + * console.log(pm.scan('foo/bar/*.js')); + * { isGlob: true, input: 'foo/bar/*.js', base: 'foo/bar', glob: '*.js' } + * ``` + * @param {String} `str` + * @param {Object} `options` + * @return {Object} Returns an object with tokens and regex source string. + * @api public + */ + + const scan$1 = (input, options) => { + const opts = options || {}; + + const length = input.length - 1; + const scanToEnd = opts.parts === true || opts.scanToEnd === true; + const slashes = []; + const tokens = []; + const parts = []; + + let str = input; + let index = -1; + let start = 0; + let lastIndex = 0; + let isBrace = false; + let isBracket = false; + let isGlob = false; + let isExtglob = false; + let isGlobstar = false; + let braceEscaped = false; + let backslashes = false; + let negated = false; + let finished = false; + let braces = 0; + let prev; + let code; + let token = { value: '', depth: 0, isGlob: false }; + + const eos = () => index >= length; + const peek = () => str.charCodeAt(index + 1); + const advance = () => { + prev = code; + return str.charCodeAt(++index); + }; + + while (index < length) { + code = advance(); + let next; + + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + code = advance(); + + if (code === CHAR_LEFT_CURLY_BRACE) { + braceEscaped = true; + } + continue; + } + + if (braceEscaped === true || code === CHAR_LEFT_CURLY_BRACE) { + braces++; + + while (eos() !== true && (code = advance())) { + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + advance(); + continue; + } + + if (code === CHAR_LEFT_CURLY_BRACE) { + braces++; + continue; + } + + if (braceEscaped !== true && code === CHAR_DOT && (code = advance()) === CHAR_DOT) { + isBrace = token.isBrace = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + + break; + } + + if (braceEscaped !== true && code === CHAR_COMMA) { + isBrace = token.isBrace = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + + break; + } + + if (code === CHAR_RIGHT_CURLY_BRACE) { + braces--; + + if (braces === 0) { + braceEscaped = false; + isBrace = token.isBrace = true; + finished = true; + break; + } + } + } + + if (scanToEnd === true) { + continue; + } + + break; + } + + if (code === CHAR_FORWARD_SLASH) { + slashes.push(index); + tokens.push(token); + token = { value: '', depth: 0, isGlob: false }; + + if (finished === true) continue; + if (prev === CHAR_DOT && index === (start + 1)) { + start += 2; + continue; + } + + lastIndex = index + 1; + continue; + } + + if (opts.noext !== true) { + const isExtglobChar = code === CHAR_PLUS + || code === CHAR_AT + || code === CHAR_ASTERISK + || code === CHAR_QUESTION_MARK + || code === CHAR_EXCLAMATION_MARK; + + if (isExtglobChar === true && peek() === CHAR_LEFT_PARENTHESES) { + isGlob = token.isGlob = true; + isExtglob = token.isExtglob = true; + finished = true; + + if (scanToEnd === true) { + while (eos() !== true && (code = advance())) { + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + code = advance(); + continue; + } + + if (code === CHAR_RIGHT_PARENTHESES) { + isGlob = token.isGlob = true; + finished = true; + break; + } + } + continue; + } + break; + } + } + + if (code === CHAR_ASTERISK) { + if (prev === CHAR_ASTERISK) isGlobstar = token.isGlobstar = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + break; + } + + if (code === CHAR_QUESTION_MARK) { + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + break; + } + + if (code === CHAR_LEFT_SQUARE_BRACKET) { + while (eos() !== true && (next = advance())) { + if (next === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + advance(); + continue; + } + + if (next === CHAR_RIGHT_SQUARE_BRACKET) { + isBracket = token.isBracket = true; + isGlob = token.isGlob = true; + finished = true; + + if (scanToEnd === true) { + continue; + } + break; + } + } + } + + if (opts.nonegate !== true && code === CHAR_EXCLAMATION_MARK && index === start) { + negated = token.negated = true; + start++; + continue; + } + + if (opts.noparen !== true && code === CHAR_LEFT_PARENTHESES) { + isGlob = token.isGlob = true; + + if (scanToEnd === true) { + while (eos() !== true && (code = advance())) { + if (code === CHAR_LEFT_PARENTHESES) { + backslashes = token.backslashes = true; + code = advance(); + continue; + } + + if (code === CHAR_RIGHT_PARENTHESES) { + finished = true; + break; + } + } + continue; + } + break; + } + + if (isGlob === true) { + finished = true; + + if (scanToEnd === true) { + continue; + } + + break; + } + } + + if (opts.noext === true) { + isExtglob = false; + isGlob = false; + } + + let base = str; + let prefix = ''; + let glob = ''; + + if (start > 0) { + prefix = str.slice(0, start); + str = str.slice(start); + lastIndex -= start; + } + + if (base && isGlob === true && lastIndex > 0) { + base = str.slice(0, lastIndex); + glob = str.slice(lastIndex); + } else if (isGlob === true) { + base = ''; + glob = str; + } else { + base = str; + } + + if (base && base !== '' && base !== '/' && base !== str) { + if (isPathSeparator(base.charCodeAt(base.length - 1))) { + base = base.slice(0, -1); + } + } + + if (opts.unescape === true) { + if (glob) glob = utils$2.removeBackslashes(glob); + + if (base && backslashes === true) { + base = utils$2.removeBackslashes(base); + } + } + + const state = { + prefix, + input, + start, + base, + glob, + isBrace, + isBracket, + isGlob, + isExtglob, + isGlobstar, + negated + }; + + if (opts.tokens === true) { + state.maxDepth = 0; + if (!isPathSeparator(code)) { + tokens.push(token); + } + state.tokens = tokens; + } + + if (opts.parts === true || opts.tokens === true) { + let prevIndex; + + for (let idx = 0; idx < slashes.length; idx++) { + const n = prevIndex ? prevIndex + 1 : start; + const i = slashes[idx]; + const value = input.slice(n, i); + if (opts.tokens) { + if (idx === 0 && start !== 0) { + tokens[idx].isPrefix = true; + tokens[idx].value = prefix; + } else { + tokens[idx].value = value; + } + depth(tokens[idx]); + state.maxDepth += tokens[idx].depth; + } + if (idx !== 0 || value !== '') { + parts.push(value); + } + prevIndex = i; + } + + if (prevIndex && prevIndex + 1 < input.length) { + const value = input.slice(prevIndex + 1); + parts.push(value); + + if (opts.tokens) { + tokens[tokens.length - 1].value = value; + depth(tokens[tokens.length - 1]); + state.maxDepth += tokens[tokens.length - 1].depth; + } + } + + state.slashes = slashes; + state.parts = parts; + } + + return state; + }; + + var scan_1 = scan$1; + + const constants$2 = constants$3; + const utils$1 = utils$3; + + /** + * Constants + */ + + const { + MAX_LENGTH, + POSIX_REGEX_SOURCE, + REGEX_NON_SPECIAL_CHARS, + REGEX_SPECIAL_CHARS_BACKREF, + REPLACEMENTS + } = constants$2; + + /** + * Helpers + */ + + const expandRange = (args, options) => { + if (typeof options.expandRange === 'function') { + return options.expandRange(...args, options); + } + + args.sort(); + const value = `[${args.join('-')}]`; + + try { + /* eslint-disable-next-line no-new */ + new RegExp(value); + } catch (ex) { + return args.map(v => utils$1.escapeRegex(v)).join('..'); + } + + return value; + }; + + /** + * Create the message for a syntax error + */ + + const syntaxError = (type, char) => { + return `Missing ${type}: "${char}" - use "\\\\${char}" to match literal characters`; + }; + + /** + * Parse the given input string. + * @param {String} input + * @param {Object} options + * @return {Object} + */ + + const parse$2 = (input, options) => { + if (typeof input !== 'string') { + throw new TypeError('Expected a string'); + } + + input = REPLACEMENTS[input] || input; + + const opts = { ...options }; + const max = typeof opts.maxLength === 'number' ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; + + let len = input.length; + if (len > max) { + throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`); + } + + const bos = { type: 'bos', value: '', output: opts.prepend || '' }; + const tokens = [bos]; + + const capture = opts.capture ? '' : '?:'; + + // create constants based on platform, for windows or posix + const PLATFORM_CHARS = constants$2.globChars(opts.windows); + const EXTGLOB_CHARS = constants$2.extglobChars(PLATFORM_CHARS); + + const { + DOT_LITERAL, + PLUS_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + DOTS_SLASH, + NO_DOT, + NO_DOT_SLASH, + NO_DOTS_SLASH, + QMARK, + QMARK_NO_DOT, + STAR, + START_ANCHOR + } = PLATFORM_CHARS; + + const globstar = (opts) => { + return `(${capture}(?:(?!${START_ANCHOR}${opts.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; + }; + + const nodot = opts.dot ? '' : NO_DOT; + const qmarkNoDot = opts.dot ? QMARK : QMARK_NO_DOT; + let star = opts.bash === true ? globstar(opts) : STAR; + + if (opts.capture) { + star = `(${star})`; + } + + // minimatch options support + if (typeof opts.noext === 'boolean') { + opts.noextglob = opts.noext; + } + + const state = { + input, + index: -1, + start: 0, + dot: opts.dot === true, + consumed: '', + output: '', + prefix: '', + backtrack: false, + negated: false, + brackets: 0, + braces: 0, + parens: 0, + quotes: 0, + globstar: false, + tokens + }; + + input = utils$1.removePrefix(input, state); + len = input.length; + + const extglobs = []; + const braces = []; + const stack = []; + let prev = bos; + let value; + + /** + * Tokenizing helpers + */ + + const eos = () => state.index === len - 1; + const peek = state.peek = (n = 1) => input[state.index + n]; + const advance = state.advance = () => input[++state.index]; + const remaining = () => input.slice(state.index + 1); + const consume = (value = '', num = 0) => { + state.consumed += value; + state.index += num; + }; + const append = token => { + state.output += token.output != null ? token.output : token.value; + consume(token.value); + }; + + const negate = () => { + let count = 1; + + while (peek() === '!' && (peek(2) !== '(' || peek(3) === '?')) { + advance(); + state.start++; + count++; + } + + if (count % 2 === 0) { + return false; + } + + state.negated = true; + state.start++; + return true; + }; + + const increment = type => { + state[type]++; + stack.push(type); + }; + + const decrement = type => { + state[type]--; + stack.pop(); + }; + + /** + * Push tokens onto the tokens array. This helper speeds up + * tokenizing by 1) helping us avoid backtracking as much as possible, + * and 2) helping us avoid creating extra tokens when consecutive + * characters are plain text. This improves performance and simplifies + * lookbehinds. + */ + + const push = tok => { + if (prev.type === 'globstar') { + const isBrace = state.braces > 0 && (tok.type === 'comma' || tok.type === 'brace'); + const isExtglob = tok.extglob === true || (extglobs.length && (tok.type === 'pipe' || tok.type === 'paren')); + + if (tok.type !== 'slash' && tok.type !== 'paren' && !isBrace && !isExtglob) { + state.output = state.output.slice(0, -prev.output.length); + prev.type = 'star'; + prev.value = '*'; + prev.output = star; + state.output += prev.output; + } + } + + if (extglobs.length && tok.type !== 'paren' && !EXTGLOB_CHARS[tok.value]) { + extglobs[extglobs.length - 1].inner += tok.value; + } + + if (tok.value || tok.output) append(tok); + if (prev && prev.type === 'text' && tok.type === 'text') { + prev.value += tok.value; + prev.output = (prev.output || '') + tok.value; + return; + } + + tok.prev = prev; + tokens.push(tok); + prev = tok; + }; + + const extglobOpen = (type, value) => { + const token = { ...EXTGLOB_CHARS[value], conditions: 1, inner: '' }; + + token.prev = prev; + token.parens = state.parens; + token.output = state.output; + const output = (opts.capture ? '(' : '') + token.open; + + increment('parens'); + push({ type, value, output: state.output ? '' : ONE_CHAR }); + push({ type: 'paren', extglob: true, value: advance(), output }); + extglobs.push(token); + }; + + const extglobClose = token => { + let output = token.close + (opts.capture ? ')' : ''); + + if (token.type === 'negate') { + let extglobStar = star; + + if (token.inner && token.inner.length > 1 && token.inner.includes('/')) { + extglobStar = globstar(opts); + } + + if (extglobStar !== star || eos() || /^\)+$/.test(remaining())) { + output = token.close = `)$))${extglobStar}`; + } + + if (token.prev.type === 'bos' && eos()) { + state.negatedExtglob = true; + } + } + + push({ type: 'paren', extglob: true, value, output }); + decrement('parens'); + }; + + /** + * Fast paths + */ + + if (opts.fastpaths !== false && !/(^[*!]|[/()[\]{}"])/.test(input)) { + let backslashes = false; + + let output = input.replace(REGEX_SPECIAL_CHARS_BACKREF, (m, esc, chars, first, rest, index) => { + if (first === '\\') { + backslashes = true; + return m; + } + + if (first === '?') { + if (esc) { + return esc + first + (rest ? QMARK.repeat(rest.length) : ''); + } + if (index === 0) { + return qmarkNoDot + (rest ? QMARK.repeat(rest.length) : ''); + } + return QMARK.repeat(chars.length); + } + + if (first === '.') { + return DOT_LITERAL.repeat(chars.length); + } + + if (first === '*') { + if (esc) { + return esc + first + (rest ? star : ''); + } + return star; + } + return esc ? m : `\\${m}`; + }); + + if (backslashes === true) { + if (opts.unescape === true) { + output = output.replace(/\\/g, ''); + } else { + output = output.replace(/\\+/g, m => { + return m.length % 2 === 0 ? '\\\\' : (m ? '\\' : ''); + }); + } + } + + if (output === input && opts.contains === true) { + state.output = input; + return state; + } + + state.output = utils$1.wrapOutput(output, state, options); + return state; + } + + /** + * Tokenize input until we reach end-of-string + */ + + while (!eos()) { + value = advance(); + + if (value === '\u0000') { + continue; + } + + /** + * Escaped characters + */ + + if (value === '\\') { + const next = peek(); + + if (next === '/' && opts.bash !== true) { + continue; + } + + if (next === '.' || next === ';') { + continue; + } + + if (!next) { + value += '\\'; + push({ type: 'text', value }); + continue; + } + + // collapse slashes to reduce potential for exploits + const match = /^\\+/.exec(remaining()); + let slashes = 0; + + if (match && match[0].length > 2) { + slashes = match[0].length; + state.index += slashes; + if (slashes % 2 !== 0) { + value += '\\'; + } + } + + if (opts.unescape === true) { + value = advance() || ''; + } else { + value += advance() || ''; + } + + if (state.brackets === 0) { + push({ type: 'text', value }); + continue; + } + } + + /** + * If we're inside a regex character class, continue + * until we reach the closing bracket. + */ + + if (state.brackets > 0 && (value !== ']' || prev.value === '[' || prev.value === '[^')) { + if (opts.posix !== false && value === ':') { + const inner = prev.value.slice(1); + if (inner.includes('[')) { + prev.posix = true; + + if (inner.includes(':')) { + const idx = prev.value.lastIndexOf('['); + const pre = prev.value.slice(0, idx); + const rest = prev.value.slice(idx + 2); + const posix = POSIX_REGEX_SOURCE[rest]; + if (posix) { + prev.value = pre + posix; + state.backtrack = true; + advance(); + + if (!bos.output && tokens.indexOf(prev) === 1) { + bos.output = ONE_CHAR; + } + continue; + } + } + } + } + + if ((value === '[' && peek() !== ':') || (value === '-' && peek() === ']')) { + value = `\\${value}`; + } + + if (value === ']' && (prev.value === '[' || prev.value === '[^')) { + value = `\\${value}`; + } + + if (opts.posix === true && value === '!' && prev.value === '[') { + value = '^'; + } + + prev.value += value; + append({ value }); + continue; + } + + /** + * If we're inside a quoted string, continue + * until we reach the closing double quote. + */ + + if (state.quotes === 1 && value !== '"') { + value = utils$1.escapeRegex(value); + prev.value += value; + append({ value }); + continue; + } + + /** + * Double quotes + */ + + if (value === '"') { + state.quotes = state.quotes === 1 ? 0 : 1; + if (opts.keepQuotes === true) { + push({ type: 'text', value }); + } + continue; + } + + /** + * Parentheses + */ + + if (value === '(') { + increment('parens'); + push({ type: 'paren', value }); + continue; + } + + if (value === ')') { + if (state.parens === 0 && opts.strictBrackets === true) { + throw new SyntaxError(syntaxError('opening', '(')); + } + + const extglob = extglobs[extglobs.length - 1]; + if (extglob && state.parens === extglob.parens + 1) { + extglobClose(extglobs.pop()); + continue; + } + + push({ type: 'paren', value, output: state.parens ? ')' : '\\)' }); + decrement('parens'); + continue; + } + + /** + * Square brackets + */ + + if (value === '[') { + if (opts.nobracket === true || !remaining().includes(']')) { + if (opts.nobracket !== true && opts.strictBrackets === true) { + throw new SyntaxError(syntaxError('closing', ']')); + } + + value = `\\${value}`; + } else { + increment('brackets'); + } + + push({ type: 'bracket', value }); + continue; + } + + if (value === ']') { + if (opts.nobracket === true || (prev && prev.type === 'bracket' && prev.value.length === 1)) { + push({ type: 'text', value, output: `\\${value}` }); + continue; + } + + if (state.brackets === 0) { + if (opts.strictBrackets === true) { + throw new SyntaxError(syntaxError('opening', '[')); + } + + push({ type: 'text', value, output: `\\${value}` }); + continue; + } + + decrement('brackets'); + + const prevValue = prev.value.slice(1); + if (prev.posix !== true && prevValue[0] === '^' && !prevValue.includes('/')) { + value = `/${value}`; + } + + prev.value += value; + append({ value }); + + // when literal brackets are explicitly disabled + // assume we should match with a regex character class + if (opts.literalBrackets === false || utils$1.hasRegexChars(prevValue)) { + continue; + } + + const escaped = utils$1.escapeRegex(prev.value); + state.output = state.output.slice(0, -prev.value.length); + + // when literal brackets are explicitly enabled + // assume we should escape the brackets to match literal characters + if (opts.literalBrackets === true) { + state.output += escaped; + prev.value = escaped; + continue; + } + + // when the user specifies nothing, try to match both + prev.value = `(${capture}${escaped}|${prev.value})`; + state.output += prev.value; + continue; + } + + /** + * Braces + */ + + if (value === '{' && opts.nobrace !== true) { + increment('braces'); + + const open = { + type: 'brace', + value, + output: '(', + outputIndex: state.output.length, + tokensIndex: state.tokens.length + }; + + braces.push(open); + push(open); + continue; + } + + if (value === '}') { + const brace = braces[braces.length - 1]; + + if (opts.nobrace === true || !brace) { + push({ type: 'text', value, output: value }); + continue; + } + + let output = ')'; + + if (brace.dots === true) { + const arr = tokens.slice(); + const range = []; + + for (let i = arr.length - 1; i >= 0; i--) { + tokens.pop(); + if (arr[i].type === 'brace') { + break; + } + if (arr[i].type !== 'dots') { + range.unshift(arr[i].value); + } + } + + output = expandRange(range, opts); + state.backtrack = true; + } + + if (brace.comma !== true && brace.dots !== true) { + const out = state.output.slice(0, brace.outputIndex); + const toks = state.tokens.slice(brace.tokensIndex); + brace.value = brace.output = '\\{'; + value = output = '\\}'; + state.output = out; + for (const t of toks) { + state.output += (t.output || t.value); + } + } + + push({ type: 'brace', value, output }); + decrement('braces'); + braces.pop(); + continue; + } + + /** + * Pipes + */ + + if (value === '|') { + if (extglobs.length > 0) { + extglobs[extglobs.length - 1].conditions++; + } + push({ type: 'text', value }); + continue; + } + + /** + * Commas + */ + + if (value === ',') { + let output = value; + + const brace = braces[braces.length - 1]; + if (brace && stack[stack.length - 1] === 'braces') { + brace.comma = true; + output = '|'; + } + + push({ type: 'comma', value, output }); + continue; + } + + /** + * Slashes + */ + + if (value === '/') { + // if the beginning of the glob is "./", advance the start + // to the current index, and don't add the "./" characters + // to the state. This greatly simplifies lookbehinds when + // checking for BOS characters like "!" and "." (not "./") + if (prev.type === 'dot' && state.index === state.start + 1) { + state.start = state.index + 1; + state.consumed = ''; + state.output = ''; + tokens.pop(); + prev = bos; // reset "prev" to the first token + continue; + } + + push({ type: 'slash', value, output: SLASH_LITERAL }); + continue; + } + + /** + * Dots + */ + + if (value === '.') { + if (state.braces > 0 && prev.type === 'dot') { + if (prev.value === '.') prev.output = DOT_LITERAL; + const brace = braces[braces.length - 1]; + prev.type = 'dots'; + prev.output += value; + prev.value += value; + brace.dots = true; + continue; + } + + if ((state.braces + state.parens) === 0 && prev.type !== 'bos' && prev.type !== 'slash') { + push({ type: 'text', value, output: DOT_LITERAL }); + continue; + } + + push({ type: 'dot', value, output: DOT_LITERAL }); + continue; + } + + /** + * Question marks + */ + + if (value === '?') { + const isGroup = prev && prev.value === '('; + if (!isGroup && opts.noextglob !== true && peek() === '(' && peek(2) !== '?') { + extglobOpen('qmark', value); + continue; + } + + if (prev && prev.type === 'paren') { + const next = peek(); + let output = value; + + if (next === '<' && !utils$1.supportsLookbehinds()) { + throw new Error('Node.js v10 or higher is required for regex lookbehinds'); + } + + if ((prev.value === '(' && !/[!=<:]/.test(next)) || (next === '<' && !/<([!=]|\w+>)/.test(remaining()))) { + output = `\\${value}`; + } + + push({ type: 'text', value, output }); + continue; + } + + if (opts.dot !== true && (prev.type === 'slash' || prev.type === 'bos')) { + push({ type: 'qmark', value, output: QMARK_NO_DOT }); + continue; + } + + push({ type: 'qmark', value, output: QMARK }); + continue; + } + + /** + * Exclamation + */ + + if (value === '!') { + if (opts.noextglob !== true && peek() === '(') { + if (peek(2) !== '?' || !/[!=<:]/.test(peek(3))) { + extglobOpen('negate', value); + continue; + } + } + + if (opts.nonegate !== true && state.index === 0) { + negate(); + continue; + } + } + + /** + * Plus + */ + + if (value === '+') { + if (opts.noextglob !== true && peek() === '(' && peek(2) !== '?') { + extglobOpen('plus', value); + continue; + } + + if ((prev && prev.value === '(') || opts.regex === false) { + push({ type: 'plus', value, output: PLUS_LITERAL }); + continue; + } + + if ((prev && (prev.type === 'bracket' || prev.type === 'paren' || prev.type === 'brace')) || state.parens > 0) { + push({ type: 'plus', value }); + continue; + } + + push({ type: 'plus', value: PLUS_LITERAL }); + continue; + } + + /** + * Plain text + */ + + if (value === '@') { + if (opts.noextglob !== true && peek() === '(' && peek(2) !== '?') { + push({ type: 'at', extglob: true, value, output: '' }); + continue; + } + + push({ type: 'text', value }); + continue; + } + + /** + * Plain text + */ + + if (value !== '*') { + if (value === '$' || value === '^') { + value = `\\${value}`; + } + + const match = REGEX_NON_SPECIAL_CHARS.exec(remaining()); + if (match) { + value += match[0]; + state.index += match[0].length; + } + + push({ type: 'text', value }); + continue; + } + + /** + * Stars + */ + + if (prev && (prev.type === 'globstar' || prev.star === true)) { + prev.type = 'star'; + prev.star = true; + prev.value += value; + prev.output = star; + state.backtrack = true; + state.globstar = true; + consume(value); + continue; + } + + let rest = remaining(); + if (opts.noextglob !== true && /^\([^?]/.test(rest)) { + extglobOpen('star', value); + continue; + } + + if (prev.type === 'star') { + if (opts.noglobstar === true) { + consume(value); + continue; + } + + const prior = prev.prev; + const before = prior.prev; + const isStart = prior.type === 'slash' || prior.type === 'bos'; + const afterStar = before && (before.type === 'star' || before.type === 'globstar'); + + if (opts.bash === true && (!isStart || (rest[0] && rest[0] !== '/'))) { + push({ type: 'star', value, output: '' }); + continue; + } + + const isBrace = state.braces > 0 && (prior.type === 'comma' || prior.type === 'brace'); + const isExtglob = extglobs.length && (prior.type === 'pipe' || prior.type === 'paren'); + if (!isStart && prior.type !== 'paren' && !isBrace && !isExtglob) { + push({ type: 'star', value, output: '' }); + continue; + } + + // strip consecutive `/**/` + while (rest.slice(0, 3) === '/**') { + const after = input[state.index + 4]; + if (after && after !== '/') { + break; + } + rest = rest.slice(3); + consume('/**', 3); + } + + if (prior.type === 'bos' && eos()) { + prev.type = 'globstar'; + prev.value += value; + prev.output = globstar(opts); + state.output = prev.output; + state.globstar = true; + consume(value); + continue; + } + + if (prior.type === 'slash' && prior.prev.type !== 'bos' && !afterStar && eos()) { + state.output = state.output.slice(0, -(prior.output + prev.output).length); + prior.output = `(?:${prior.output}`; + + prev.type = 'globstar'; + prev.output = globstar(opts) + (opts.strictSlashes ? ')' : '|$)'); + prev.value += value; + state.globstar = true; + state.output += prior.output + prev.output; + consume(value); + continue; + } + + if (prior.type === 'slash' && prior.prev.type !== 'bos' && rest[0] === '/') { + const end = rest[1] !== void 0 ? '|$' : ''; + + state.output = state.output.slice(0, -(prior.output + prev.output).length); + prior.output = `(?:${prior.output}`; + + prev.type = 'globstar'; + prev.output = `${globstar(opts)}${SLASH_LITERAL}|${SLASH_LITERAL}${end})`; + prev.value += value; + + state.output += prior.output + prev.output; + state.globstar = true; + + consume(value + advance()); + + push({ type: 'slash', value: '/', output: '' }); + continue; + } + + if (prior.type === 'bos' && rest[0] === '/') { + prev.type = 'globstar'; + prev.value += value; + prev.output = `(?:^|${SLASH_LITERAL}|${globstar(opts)}${SLASH_LITERAL})`; + state.output = prev.output; + state.globstar = true; + consume(value + advance()); + push({ type: 'slash', value: '/', output: '' }); + continue; + } + + // remove single star from output + state.output = state.output.slice(0, -prev.output.length); + + // reset previous token to globstar + prev.type = 'globstar'; + prev.output = globstar(opts); + prev.value += value; + + // reset output with globstar + state.output += prev.output; + state.globstar = true; + consume(value); + continue; + } + + const token = { type: 'star', value, output: star }; + + if (opts.bash === true) { + token.output = '.*?'; + if (prev.type === 'bos' || prev.type === 'slash') { + token.output = nodot + token.output; + } + push(token); + continue; + } + + if (prev && (prev.type === 'bracket' || prev.type === 'paren') && opts.regex === true) { + token.output = value; + push(token); + continue; + } + + if (state.index === state.start || prev.type === 'slash' || prev.type === 'dot') { + if (prev.type === 'dot') { + state.output += NO_DOT_SLASH; + prev.output += NO_DOT_SLASH; + + } else if (opts.dot === true) { + state.output += NO_DOTS_SLASH; + prev.output += NO_DOTS_SLASH; + + } else { + state.output += nodot; + prev.output += nodot; + } + + if (peek() !== '*') { + state.output += ONE_CHAR; + prev.output += ONE_CHAR; + } + } + + push(token); + } + + while (state.brackets > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', ']')); + state.output = utils$1.escapeLast(state.output, '['); + decrement('brackets'); + } + + while (state.parens > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', ')')); + state.output = utils$1.escapeLast(state.output, '('); + decrement('parens'); + } + + while (state.braces > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', '}')); + state.output = utils$1.escapeLast(state.output, '{'); + decrement('braces'); + } + + if (opts.strictSlashes !== true && (prev.type === 'star' || prev.type === 'bracket')) { + push({ type: 'maybe_slash', value: '', output: `${SLASH_LITERAL}?` }); + } + + // rebuild the output if we had to backtrack at any point + if (state.backtrack === true) { + state.output = ''; + + for (const token of state.tokens) { + state.output += token.output != null ? token.output : token.value; + + if (token.suffix) { + state.output += token.suffix; + } + } + } + + return state; + }; + + /** + * Fast paths for creating regular expressions for common glob patterns. + * This can significantly speed up processing and has very little downside + * impact when none of the fast paths match. + */ + + parse$2.fastpaths = (input, options) => { + const opts = { ...options }; + const max = typeof opts.maxLength === 'number' ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; + const len = input.length; + if (len > max) { + throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`); + } + + input = REPLACEMENTS[input] || input; + + // create constants based on platform, for windows or posix + const { + DOT_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + DOTS_SLASH, + NO_DOT, + NO_DOTS, + NO_DOTS_SLASH, + STAR, + START_ANCHOR + } = constants$2.globChars(opts.windows); + + const nodot = opts.dot ? NO_DOTS : NO_DOT; + const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT; + const capture = opts.capture ? '' : '?:'; + const state = { negated: false, prefix: '' }; + let star = opts.bash === true ? '.*?' : STAR; + + if (opts.capture) { + star = `(${star})`; + } + + const globstar = (opts) => { + if (opts.noglobstar === true) return star; + return `(${capture}(?:(?!${START_ANCHOR}${opts.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; + }; + + const create = str => { + switch (str) { + case '*': + return `${nodot}${ONE_CHAR}${star}`; + + case '.*': + return `${DOT_LITERAL}${ONE_CHAR}${star}`; + + case '*.*': + return `${nodot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; + + case '*/*': + return `${nodot}${star}${SLASH_LITERAL}${ONE_CHAR}${slashDot}${star}`; + + case '**': + return nodot + globstar(opts); + + case '**/*': + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${ONE_CHAR}${star}`; + + case '**/*.*': + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; + + case '**/.*': + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`; + + default: { + const match = /^(.*?)\.(\w+)$/.exec(str); + if (!match) return; + + const source = create(match[1]); + if (!source) return; + + return source + DOT_LITERAL + match[2]; + } + } + }; + + const output = utils$1.removePrefix(input, state); + let source = create(output); + + if (source && opts.strictSlashes !== true) { + source += `${SLASH_LITERAL}?`; + } + + return source; + }; + + var parse_1 = parse$2; + + const scan = scan_1; + const parse$1 = parse_1; + const utils = utils$3; + const constants$1 = constants$3; + const isObject = val => val && typeof val === 'object' && !Array.isArray(val); + + /** + * Creates a matcher function from one or more glob patterns. The + * returned function takes a string to match as its first argument, + * and returns true if the string is a match. The returned matcher + * function also takes a boolean as the second argument that, when true, + * returns an object with additional information. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch(glob[, options]); + * + * const isMatch = picomatch('*.!(*a)'); + * console.log(isMatch('a.a')); //=> false + * console.log(isMatch('a.b')); //=> true + * ``` + * @name picomatch + * @param {String|Array} `globs` One or more glob patterns. + * @param {Object=} `options` + * @return {Function=} Returns a matcher function. + * @api public + */ + + const picomatch = (glob, options, returnState = false) => { + if (Array.isArray(glob)) { + const fns = glob.map(input => picomatch(input, options, returnState)); + const arrayMatcher = str => { + for (const isMatch of fns) { + const state = isMatch(str); + if (state) return state; + } + return false; + }; + return arrayMatcher; + } + + const isState = isObject(glob) && glob.tokens && glob.input; + + if (glob === '' || (typeof glob !== 'string' && !isState)) { + throw new TypeError('Expected pattern to be a non-empty string'); + } + + const opts = options || {}; + const posix = opts.windows; + const regex = isState + ? picomatch.compileRe(glob, options) + : picomatch.makeRe(glob, options, false, true); + + const state = regex.state; + delete regex.state; + + let isIgnored = () => false; + if (opts.ignore) { + const ignoreOpts = { ...options, ignore: null, onMatch: null, onResult: null }; + isIgnored = picomatch(opts.ignore, ignoreOpts, returnState); + } + + const matcher = (input, returnObject = false) => { + const { isMatch, match, output } = picomatch.test(input, regex, options, { glob, posix }); + const result = { glob, state, regex, posix, input, output, match, isMatch }; + + if (typeof opts.onResult === 'function') { + opts.onResult(result); + } + + if (isMatch === false) { + result.isMatch = false; + return returnObject ? result : false; + } + + if (isIgnored(input)) { + if (typeof opts.onIgnore === 'function') { + opts.onIgnore(result); + } + result.isMatch = false; + return returnObject ? result : false; + } + + if (typeof opts.onMatch === 'function') { + opts.onMatch(result); + } + return returnObject ? result : true; + }; + + if (returnState) { + matcher.state = state; + } + + return matcher; + }; + + /** + * Test `input` with the given `regex`. This is used by the main + * `picomatch()` function to test the input string. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.test(input, regex[, options]); + * + * console.log(picomatch.test('foo/bar', /^(?:([^/]*?)\/([^/]*?))$/)); + * // { isMatch: true, match: [ 'foo/', 'foo', 'bar' ], output: 'foo/bar' } + * ``` + * @param {String} `input` String to test. + * @param {RegExp} `regex` + * @return {Object} Returns an object with matching info. + * @api public + */ + + picomatch.test = (input, regex, options, { glob, posix } = {}) => { + if (typeof input !== 'string') { + throw new TypeError('Expected input to be a string'); + } + + if (input === '') { + return { isMatch: false, output: '' }; + } + + const opts = options || {}; + const format = opts.format || (posix ? utils.toPosixSlashes : null); + let match = input === glob; + let output = (match && format) ? format(input) : input; + + if (match === false) { + output = format ? format(input) : input; + match = output === glob; + } + + if (match === false || opts.capture === true) { + if (opts.matchBase === true || opts.basename === true) { + match = picomatch.matchBase(input, regex, options, posix); + } else { + match = regex.exec(output); + } + } + + return { isMatch: Boolean(match), match, output }; + }; + + /** + * Match the basename of a filepath. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.matchBase(input, glob[, options]); + * console.log(picomatch.matchBase('foo/bar.js', '*.js'); // true + * ``` + * @param {String} `input` String to test. + * @param {RegExp|String} `glob` Glob pattern or regex created by [.makeRe](#makeRe). + * @return {Boolean} + * @api public + */ + + picomatch.matchBase = (input, glob, options) => { + const regex = glob instanceof RegExp ? glob : picomatch.makeRe(glob, options); + return regex.test(utils.basename(input)); + }; + + /** + * Returns true if **any** of the given glob `patterns` match the specified `string`. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.isMatch(string, patterns[, options]); + * + * console.log(picomatch.isMatch('a.a', ['b.*', '*.a'])); //=> true + * console.log(picomatch.isMatch('a.a', 'b.*')); //=> false + * ``` + * @param {String|Array} str The string to test. + * @param {String|Array} patterns One or more glob patterns to use for matching. + * @param {Object} [options] See available [options](#options). + * @return {Boolean} Returns true if any patterns match `str` + * @api public + */ + + picomatch.isMatch = (str, patterns, options) => picomatch(patterns, options)(str); + + /** + * Parse a glob pattern to create the source string for a regular + * expression. + * + * ```js + * const picomatch = require('picomatch'); + * const result = picomatch.parse(pattern[, options]); + * ``` + * @param {String} `pattern` + * @param {Object} `options` + * @return {Object} Returns an object with useful properties and output to be used as a regex source string. + * @api public + */ + + picomatch.parse = (pattern, options) => { + if (Array.isArray(pattern)) return pattern.map(p => picomatch.parse(p, options)); + return parse$1(pattern, { ...options, fastpaths: false }); + }; + + /** + * Scan a glob pattern to separate the pattern into segments. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.scan(input[, options]); + * + * const result = picomatch.scan('!./foo/*.js'); + * console.log(result); + * { prefix: '!./', + * input: '!./foo/*.js', + * start: 3, + * base: 'foo', + * glob: '*.js', + * isBrace: false, + * isBracket: false, + * isGlob: true, + * isExtglob: false, + * isGlobstar: false, + * negated: true } + * ``` + * @param {String} `input` Glob pattern to scan. + * @param {Object} `options` + * @return {Object} Returns an object with + * @api public + */ + + picomatch.scan = (input, options) => scan(input, options); + + /** + * Create a regular expression from a parsed glob pattern. + * + * ```js + * const picomatch = require('picomatch'); + * const state = picomatch.parse('*.js'); + * // picomatch.compileRe(state[, options]); + * + * console.log(picomatch.compileRe(state)); + * //=> /^(?:(?!\.)(?=.)[^/]*?\.js)$/ + * ``` + * @param {String} `state` The object returned from the `.parse` method. + * @param {Object} `options` + * @return {RegExp} Returns a regex created from the given pattern. + * @api public + */ + + picomatch.compileRe = (parsed, options, returnOutput = false, returnState = false) => { + if (returnOutput === true) { + return parsed.output; + } + + const opts = options || {}; + const prepend = opts.contains ? '' : '^'; + const append = opts.contains ? '' : '$'; + + let source = `${prepend}(?:${parsed.output})${append}`; + if (parsed && parsed.negated === true) { + source = `^(?!${source}).*$`; + } + + const regex = picomatch.toRegex(source, options); + if (returnState === true) { + regex.state = parsed; + } + + return regex; + }; + + picomatch.makeRe = (input, options, returnOutput = false, returnState = false) => { + if (!input || typeof input !== 'string') { + throw new TypeError('Expected a non-empty string'); + } + + const opts = options || {}; + let parsed = { negated: false, fastpaths: true }; + let prefix = ''; + let output; + + if (input.startsWith('./')) { + input = input.slice(2); + prefix = parsed.prefix = './'; + } + + if (opts.fastpaths !== false && (input[0] === '.' || input[0] === '*')) { + output = parse$1.fastpaths(input, options); + } + + if (output === undefined) { + parsed = parse$1(input, options); + parsed.prefix = prefix + (parsed.prefix || ''); + } else { + parsed.output = output; + } + + return picomatch.compileRe(parsed, options, returnOutput, returnState); + }; + + /** + * Create a regular expression from the given regex source string. + * + * ```js + * const picomatch = require('picomatch'); + * // picomatch.toRegex(source[, options]); + * + * const { output } = picomatch.parse('*.js'); + * console.log(picomatch.toRegex(output)); + * //=> /^(?:(?!\.)(?=.)[^/]*?\.js)$/ + * ``` + * @param {String} `source` Regular expression source string. + * @param {Object} `options` + * @return {RegExp} + * @api public + */ + + picomatch.toRegex = (source, options) => { + try { + const opts = options || {}; + return new RegExp(source, opts.flags || (opts.nocase ? 'i' : '')); + } catch (err) { + if (options && options.debug === true) throw err; + return /$^/; + } + }; + + /** + * Picomatch constants. + * @return {Object} + */ + + picomatch.constants = constants$1; + + /** + * Expose "picomatch" + */ + + var picomatch_1 = picomatch; + + var picomatchBrowser = picomatch_1; + + var pm = /*@__PURE__*/getDefaultExportFromCjs(picomatchBrowser); + + function isArray(arg) { + return Array.isArray(arg); + } + function ensureArray(thing) { + if (isArray(thing)) + return thing; + if (thing == null) + return []; + return [thing]; + } + const globToTest = (glob) => { + const pattern = glob; + const fn = pm(pattern, { dot: true }); + return { + test: (what) => { + const result = fn(what); + return result; + }, + }; + }; + const testTrue = { + test: () => true, + }; + const getMatcher = (filter) => { + const bundleTest = "bundle" in filter && filter.bundle != null ? globToTest(filter.bundle) : testTrue; + const fileTest = "file" in filter && filter.file != null ? globToTest(filter.file) : testTrue; + return { bundleTest, fileTest }; + }; + const createFilter = (include, exclude) => { + const includeMatchers = ensureArray(include).map(getMatcher); + const excludeMatchers = ensureArray(exclude).map(getMatcher); + return (bundleId, id) => { + for (let i = 0; i < excludeMatchers.length; ++i) { + const { bundleTest, fileTest } = excludeMatchers[i]; + if (bundleTest.test(bundleId) && fileTest.test(id)) + return false; + } + for (let i = 0; i < includeMatchers.length; ++i) { + const { bundleTest, fileTest } = includeMatchers[i]; + if (bundleTest.test(bundleId) && fileTest.test(id)) + return true; + } + return !includeMatchers.length; + }; + }; + + const throttleFilter = (callback, limit) => { + let waiting = false; + return (val) => { + if (!waiting) { + callback(val); + waiting = true; + setTimeout(() => { + waiting = false; + }, limit); + } + }; + }; + const prepareFilter = (filt) => { + if (filt === "") + return []; + return (filt + .split(",") + // remove spaces before and after + .map((entry) => entry.trim()) + // unquote " + .map((entry) => entry.startsWith('"') && entry.endsWith('"') ? entry.substring(1, entry.length - 1) : entry) + // unquote ' + .map((entry) => entry.startsWith("'") && entry.endsWith("'") ? entry.substring(1, entry.length - 1) : entry) + // remove empty strings + .filter((entry) => entry) + // parse bundle:file + .map((entry) => entry.split(":")) + // normalize entry just in case + .flatMap((entry) => { + if (entry.length === 0) + return []; + let bundle = null; + let file = null; + if (entry.length === 1 && entry[0]) { + file = entry[0]; + return [{ file, bundle }]; + } + bundle = entry[0] || null; + file = entry.slice(1).join(":") || null; + return [{ bundle, file }]; + })); + }; + const useFilter = () => { + const [includeFilter, setIncludeFilter] = h(""); + const [excludeFilter, setExcludeFilter] = h(""); + const setIncludeFilterTrottled = F(() => throttleFilter(setIncludeFilter, 200), []); + const setExcludeFilterTrottled = F(() => throttleFilter(setExcludeFilter, 200), []); + const isIncluded = F(() => createFilter(prepareFilter(includeFilter), prepareFilter(excludeFilter)), [includeFilter, excludeFilter]); + const getModuleFilterMultiplier = T((bundleId, data) => { + return isIncluded(bundleId, data.id) ? 1 : 0; + }, [isIncluded]); + return { + getModuleFilterMultiplier, + includeFilter, + excludeFilter, + setExcludeFilter: setExcludeFilterTrottled, + setIncludeFilter: setIncludeFilterTrottled, + }; + }; + + function ascending(a, b) { + return a == null || b == null ? NaN : a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN; + } + + function descending(a, b) { + return a == null || b == null ? NaN + : b < a ? -1 + : b > a ? 1 + : b >= a ? 0 + : NaN; + } + + function bisector(f) { + let compare1, compare2, delta; + + // If an accessor is specified, promote it to a comparator. In this case we + // can test whether the search value is (self-) comparable. We can’t do this + // for a comparator (except for specific, known comparators) because we can’t + // tell if the comparator is symmetric, and an asymmetric comparator can’t be + // used to test whether a single value is comparable. + if (f.length !== 2) { + compare1 = ascending; + compare2 = (d, x) => ascending(f(d), x); + delta = (d, x) => f(d) - x; + } else { + compare1 = f === ascending || f === descending ? f : zero$1; + compare2 = f; + delta = f; + } + + function left(a, x, lo = 0, hi = a.length) { + if (lo < hi) { + if (compare1(x, x) !== 0) return hi; + do { + const mid = (lo + hi) >>> 1; + if (compare2(a[mid], x) < 0) lo = mid + 1; + else hi = mid; + } while (lo < hi); + } + return lo; + } + + function right(a, x, lo = 0, hi = a.length) { + if (lo < hi) { + if (compare1(x, x) !== 0) return hi; + do { + const mid = (lo + hi) >>> 1; + if (compare2(a[mid], x) <= 0) lo = mid + 1; + else hi = mid; + } while (lo < hi); + } + return lo; + } + + function center(a, x, lo = 0, hi = a.length) { + const i = left(a, x, lo, hi - 1); + return i > lo && delta(a[i - 1], x) > -delta(a[i], x) ? i - 1 : i; + } + + return {left, center, right}; + } + + function zero$1() { + return 0; + } + + function number$1(x) { + return x === null ? NaN : +x; + } + + const ascendingBisect = bisector(ascending); + const bisectRight = ascendingBisect.right; + bisector(number$1).center; + var bisect = bisectRight; + + class InternMap extends Map { + constructor(entries, key = keyof) { + super(); + Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}}); + if (entries != null) for (const [key, value] of entries) this.set(key, value); + } + get(key) { + return super.get(intern_get(this, key)); + } + has(key) { + return super.has(intern_get(this, key)); + } + set(key, value) { + return super.set(intern_set(this, key), value); + } + delete(key) { + return super.delete(intern_delete(this, key)); + } + } + + function intern_get({_intern, _key}, value) { + const key = _key(value); + return _intern.has(key) ? _intern.get(key) : value; + } + + function intern_set({_intern, _key}, value) { + const key = _key(value); + if (_intern.has(key)) return _intern.get(key); + _intern.set(key, value); + return value; + } + + function intern_delete({_intern, _key}, value) { + const key = _key(value); + if (_intern.has(key)) { + value = _intern.get(key); + _intern.delete(key); + } + return value; + } + + function keyof(value) { + return value !== null && typeof value === "object" ? value.valueOf() : value; + } + + function identity$2(x) { + return x; + } + + function group(values, ...keys) { + return nest(values, identity$2, identity$2, keys); + } + + function nest(values, map, reduce, keys) { + return (function regroup(values, i) { + if (i >= keys.length) return reduce(values); + const groups = new InternMap(); + const keyof = keys[i++]; + let index = -1; + for (const value of values) { + const key = keyof(value, ++index, values); + const group = groups.get(key); + if (group) group.push(value); + else groups.set(key, [value]); + } + for (const [key, values] of groups) { + groups.set(key, regroup(values, i)); + } + return map(groups); + })(values, 0); + } + + const e10 = Math.sqrt(50), + e5 = Math.sqrt(10), + e2 = Math.sqrt(2); + + function tickSpec(start, stop, count) { + const step = (stop - start) / Math.max(0, count), + power = Math.floor(Math.log10(step)), + error = step / Math.pow(10, power), + factor = error >= e10 ? 10 : error >= e5 ? 5 : error >= e2 ? 2 : 1; + let i1, i2, inc; + if (power < 0) { + inc = Math.pow(10, -power) / factor; + i1 = Math.round(start * inc); + i2 = Math.round(stop * inc); + if (i1 / inc < start) ++i1; + if (i2 / inc > stop) --i2; + inc = -inc; + } else { + inc = Math.pow(10, power) * factor; + i1 = Math.round(start / inc); + i2 = Math.round(stop / inc); + if (i1 * inc < start) ++i1; + if (i2 * inc > stop) --i2; + } + if (i2 < i1 && 0.5 <= count && count < 2) return tickSpec(start, stop, count * 2); + return [i1, i2, inc]; + } + + function ticks(start, stop, count) { + stop = +stop, start = +start, count = +count; + if (!(count > 0)) return []; + if (start === stop) return [start]; + const reverse = stop < start, [i1, i2, inc] = reverse ? tickSpec(stop, start, count) : tickSpec(start, stop, count); + if (!(i2 >= i1)) return []; + const n = i2 - i1 + 1, ticks = new Array(n); + if (reverse) { + if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) / -inc; + else for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) * inc; + } else { + if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) / -inc; + else for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) * inc; + } + return ticks; + } + + function tickIncrement(start, stop, count) { + stop = +stop, start = +start, count = +count; + return tickSpec(start, stop, count)[2]; + } + + function tickStep(start, stop, count) { + stop = +stop, start = +start, count = +count; + const reverse = stop < start, inc = reverse ? tickIncrement(stop, start, count) : tickIncrement(start, stop, count); + return (reverse ? -1 : 1) * (inc < 0 ? 1 / -inc : inc); + } + + const TOP_PADDING = 20; + const PADDING = 2; + + const Node = ({ node, onMouseOver, onClick, selected }) => { + const { getModuleColor } = q(StaticContext); + const { backgroundColor, fontColor } = getModuleColor(node); + const { x0, x1, y1, y0, data, children = null } = node; + const textRef = _(null); + const textRectRef = _(); + const width = x1 - x0; + const height = y1 - y0; + const textProps = { + "font-size": "0.7em", + "dominant-baseline": "middle", + "text-anchor": "middle", + x: width / 2, + }; + if (children != null) { + textProps.y = (TOP_PADDING + PADDING) / 2; + } + else { + textProps.y = height / 2; + } + y(() => { + if (width == 0 || height == 0 || !textRef.current) { + return; + } + if (textRectRef.current == null) { + textRectRef.current = textRef.current.getBoundingClientRect(); + } + let scale = 1; + if (children != null) { + scale = Math.min((width * 0.9) / textRectRef.current.width, Math.min(height, TOP_PADDING + PADDING) / textRectRef.current.height); + scale = Math.min(1, scale); + textRef.current.setAttribute("y", String(Math.min(TOP_PADDING + PADDING, height) / 2 / scale)); + textRef.current.setAttribute("x", String(width / 2 / scale)); + } + else { + scale = Math.min((width * 0.9) / textRectRef.current.width, (height * 0.9) / textRectRef.current.height); + scale = Math.min(1, scale); + textRef.current.setAttribute("y", String(height / 2 / scale)); + textRef.current.setAttribute("x", String(width / 2 / scale)); + } + textRef.current.setAttribute("transform", `scale(${scale.toFixed(2)})`); + }, [children, height, width]); + if (width == 0 || height == 0) { + return null; + } + return (u$1("g", { className: "node", transform: `translate(${x0},${y0})`, onClick: (event) => { + event.stopPropagation(); + onClick(node); + }, onMouseOver: (event) => { + event.stopPropagation(); + onMouseOver(node); + }, children: [u$1("rect", { fill: backgroundColor, rx: 2, ry: 2, width: x1 - x0, height: y1 - y0, stroke: selected ? "#fff" : undefined, "stroke-width": selected ? 2 : undefined }), u$1("text", Object.assign({ ref: textRef, fill: fontColor, onClick: (event) => { + var _a; + if (((_a = window.getSelection()) === null || _a === void 0 ? void 0 : _a.toString()) !== "") { + event.stopPropagation(); + } + } }, textProps, { children: data.name }))] })); + }; + + const TreeMap = ({ root, onNodeHover, selectedNode, onNodeClick, }) => { + const { width, height, getModuleIds } = q(StaticContext); + console.time("layering"); + // this will make groups by height + const nestedData = F(() => { + const nestedDataMap = group(root.descendants(), (d) => d.height); + const nestedData = Array.from(nestedDataMap, ([key, values]) => ({ + key, + values, + })); + nestedData.sort((a, b) => b.key - a.key); + return nestedData; + }, [root]); + console.timeEnd("layering"); + return (u$1("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: `0 0 ${width} ${height}`, children: nestedData.map(({ key, values }) => { + return (u$1("g", { className: "layer", children: values.map((node) => { + return (u$1(Node, { node: node, onMouseOver: onNodeHover, selected: selectedNode === node, onClick: onNodeClick }, getModuleIds(node.data).nodeUid.id)); + }) }, key)); + }) })); + }; + + var bytes$1 = {exports: {}}; + + /*! + * bytes + * Copyright(c) 2012-2014 TJ Holowaychuk + * Copyright(c) 2015 Jed Watson + * MIT Licensed + */ + + /** + * Module exports. + * @public + */ + + bytes$1.exports = bytes; + var format_1 = bytes$1.exports.format = format$1; + bytes$1.exports.parse = parse; + + /** + * Module variables. + * @private + */ + + var formatThousandsRegExp = /\B(?=(\d{3})+(?!\d))/g; + + var formatDecimalsRegExp = /(?:\.0*|(\.[^0]+)0+)$/; + + var map$1 = { + b: 1, + kb: 1 << 10, + mb: 1 << 20, + gb: 1 << 30, + tb: Math.pow(1024, 4), + pb: Math.pow(1024, 5), + }; + + var parseRegExp = /^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb|pb)$/i; + + /** + * Convert the given value in bytes into a string or parse to string to an integer in bytes. + * + * @param {string|number} value + * @param {{ + * case: [string], + * decimalPlaces: [number] + * fixedDecimals: [boolean] + * thousandsSeparator: [string] + * unitSeparator: [string] + * }} [options] bytes options. + * + * @returns {string|number|null} + */ + + function bytes(value, options) { + if (typeof value === 'string') { + return parse(value); + } + + if (typeof value === 'number') { + return format$1(value, options); + } + + return null; + } + + /** + * Format the given value in bytes into a string. + * + * If the value is negative, it is kept as such. If it is a float, + * it is rounded. + * + * @param {number} value + * @param {object} [options] + * @param {number} [options.decimalPlaces=2] + * @param {number} [options.fixedDecimals=false] + * @param {string} [options.thousandsSeparator=] + * @param {string} [options.unit=] + * @param {string} [options.unitSeparator=] + * + * @returns {string|null} + * @public + */ + + function format$1(value, options) { + if (!Number.isFinite(value)) { + return null; + } + + var mag = Math.abs(value); + var thousandsSeparator = (options && options.thousandsSeparator) || ''; + var unitSeparator = (options && options.unitSeparator) || ''; + var decimalPlaces = (options && options.decimalPlaces !== undefined) ? options.decimalPlaces : 2; + var fixedDecimals = Boolean(options && options.fixedDecimals); + var unit = (options && options.unit) || ''; + + if (!unit || !map$1[unit.toLowerCase()]) { + if (mag >= map$1.pb) { + unit = 'PB'; + } else if (mag >= map$1.tb) { + unit = 'TB'; + } else if (mag >= map$1.gb) { + unit = 'GB'; + } else if (mag >= map$1.mb) { + unit = 'MB'; + } else if (mag >= map$1.kb) { + unit = 'KB'; + } else { + unit = 'B'; + } + } + + var val = value / map$1[unit.toLowerCase()]; + var str = val.toFixed(decimalPlaces); + + if (!fixedDecimals) { + str = str.replace(formatDecimalsRegExp, '$1'); + } + + if (thousandsSeparator) { + str = str.split('.').map(function (s, i) { + return i === 0 + ? s.replace(formatThousandsRegExp, thousandsSeparator) + : s + }).join('.'); + } + + return str + unitSeparator + unit; + } + + /** + * Parse the string value into an integer in bytes. + * + * If no unit is given, it is assumed the value is in bytes. + * + * @param {number|string} val + * + * @returns {number|null} + * @public + */ + + function parse(val) { + if (typeof val === 'number' && !isNaN(val)) { + return val; + } + + if (typeof val !== 'string') { + return null; + } + + // Test if the string passed is valid + var results = parseRegExp.exec(val); + var floatValue; + var unit = 'b'; + + if (!results) { + // Nothing could be extracted from the given string + floatValue = parseInt(val, 10); + unit = 'b'; + } else { + // Retrieve the value and the unit + floatValue = parseFloat(results[1]); + unit = results[4].toLowerCase(); + } + + if (isNaN(floatValue)) { + return null; + } + + return Math.floor(map$1[unit] * floatValue); + } + + const Tooltip_marginX = 10; + const Tooltip_marginY = 30; + const SOURCEMAP_RENDERED = (u$1("span", { children: [" ", u$1("b", { children: LABELS.renderedLength }), " is a number of characters in the file after individual and ", u$1("br", {}), " ", "whole bundle transformations according to sourcemap."] })); + const RENDRED = (u$1("span", { children: [u$1("b", { children: LABELS.renderedLength }), " is a byte size of individual file after transformations and treeshake."] })); + const COMPRESSED = (u$1("span", { children: [u$1("b", { children: LABELS.gzipLength }), " and ", u$1("b", { children: LABELS.brotliLength }), " is a byte size of individual file after individual transformations,", u$1("br", {}), " treeshake and compression."] })); + const Tooltip = ({ node, visible, root, sizeProperty, }) => { + const { availableSizeProperties, getModuleSize, data } = q(StaticContext); + const ref = _(null); + const [style, setStyle] = h({}); + const content = F(() => { + if (!node) + return null; + const mainSize = getModuleSize(node.data, sizeProperty); + const percentageNum = (100 * mainSize) / getModuleSize(root.data, sizeProperty); + const percentage = percentageNum.toFixed(2); + const percentageString = percentage + "%"; + const path = node + .ancestors() + .reverse() + .map((d) => d.data.name) + .join("/"); + let dataNode = null; + if (!isModuleTree(node.data)) { + const mainUid = data.nodeParts[node.data.uid].metaUid; + dataNode = data.nodeMetas[mainUid]; + } + return (u$1(g$1, { children: [u$1("div", { children: path }), availableSizeProperties.map((sizeProp) => { + if (sizeProp === sizeProperty) { + return (u$1("div", { children: [u$1("b", { children: [LABELS[sizeProp], ": ", format_1(mainSize)] }), " ", "(", percentageString, ")"] }, sizeProp)); + } + else { + return (u$1("div", { children: [LABELS[sizeProp], ": ", format_1(getModuleSize(node.data, sizeProp))] }, sizeProp)); + } + }), u$1("br", {}), dataNode && dataNode.importedBy.length > 0 && (u$1("div", { children: [u$1("div", { children: [u$1("b", { children: "Imported By" }), ":"] }), dataNode.importedBy.map(({ uid }) => { + const id = data.nodeMetas[uid].id; + return u$1("div", { children: id }, id); + })] })), u$1("br", {}), u$1("small", { children: data.options.sourcemap ? SOURCEMAP_RENDERED : RENDRED }), (data.options.gzip || data.options.brotli) && (u$1(g$1, { children: [u$1("br", {}), u$1("small", { children: COMPRESSED })] }))] })); + }, [availableSizeProperties, data, getModuleSize, node, root.data, sizeProperty]); + const updatePosition = (mouseCoords) => { + if (!ref.current) + return; + const pos = { + left: mouseCoords.x + Tooltip_marginX, + top: mouseCoords.y + Tooltip_marginY, + }; + const boundingRect = ref.current.getBoundingClientRect(); + if (pos.left + boundingRect.width > window.innerWidth) { + // Shifting horizontally + pos.left = window.innerWidth - boundingRect.width; + } + if (pos.top + boundingRect.height > window.innerHeight) { + // Flipping vertically + pos.top = mouseCoords.y - Tooltip_marginY - boundingRect.height; + } + setStyle(pos); + }; + p(() => { + const handleMouseMove = (event) => { + updatePosition({ + x: event.pageX, + y: event.pageY, + }); + }; + document.addEventListener("mousemove", handleMouseMove, true); + return () => { + document.removeEventListener("mousemove", handleMouseMove, true); + }; + }, []); + return (u$1("div", { className: `tooltip ${visible ? "" : "tooltip-hidden"}`, ref: ref, style: style, children: content })); + }; + + const Chart = ({ root, sizeProperty, selectedNode, setSelectedNode, }) => { + const [showTooltip, setShowTooltip] = h(false); + const [tooltipNode, setTooltipNode] = h(undefined); + p(() => { + const handleMouseOut = () => { + setShowTooltip(false); + }; + document.addEventListener("mouseover", handleMouseOut); + return () => { + document.removeEventListener("mouseover", handleMouseOut); + }; + }, []); + return (u$1(g$1, { children: [u$1(TreeMap, { root: root, onNodeHover: (node) => { + setTooltipNode(node); + setShowTooltip(true); + }, selectedNode: selectedNode, onNodeClick: (node) => { + setSelectedNode(selectedNode === node ? undefined : node); + } }), u$1(Tooltip, { visible: showTooltip, node: tooltipNode, root: root, sizeProperty: sizeProperty })] })); + }; + + const Main = () => { + const { availableSizeProperties, rawHierarchy, getModuleSize, layout, data } = q(StaticContext); + const [sizeProperty, setSizeProperty] = h(availableSizeProperties[0]); + const [selectedNode, setSelectedNode] = h(undefined); + const { getModuleFilterMultiplier, setExcludeFilter, setIncludeFilter } = useFilter(); + console.time("getNodeSizeMultiplier"); + const getNodeSizeMultiplier = F(() => { + const selectedMultiplier = 1; // selectedSize < rootSize * increaseFactor ? (rootSize * increaseFactor) / selectedSize : rootSize / selectedSize; + const nonSelectedMultiplier = 0; // 1 / selectedMultiplier + if (selectedNode === undefined) { + return () => 1; + } + else if (isModuleTree(selectedNode.data)) { + const leaves = new Set(selectedNode.leaves().map((d) => d.data)); + return (node) => { + if (leaves.has(node)) { + return selectedMultiplier; + } + return nonSelectedMultiplier; + }; + } + else { + return (node) => { + if (node === selectedNode.data) { + return selectedMultiplier; + } + return nonSelectedMultiplier; + }; + } + }, [getModuleSize, rawHierarchy.data, selectedNode, sizeProperty]); + console.timeEnd("getNodeSizeMultiplier"); + console.time("root hierarchy compute"); + // root here always be the same as rawHierarchy even after layouting + const root = F(() => { + const rootWithSizesAndSorted = rawHierarchy + .sum((node) => { + var _a; + if (isModuleTree(node)) + return 0; + const meta = data.nodeMetas[data.nodeParts[node.uid].metaUid]; + const bundleId = (_a = Object.entries(meta.moduleParts).find(([bundleId, uid]) => uid == node.uid)) === null || _a === void 0 ? void 0 : _a[0]; + const ownSize = getModuleSize(node, sizeProperty); + const zoomMultiplier = getNodeSizeMultiplier(node); + const filterMultiplier = getModuleFilterMultiplier(bundleId, meta); + return ownSize * zoomMultiplier * filterMultiplier; + }) + .sort((a, b) => getModuleSize(a.data, sizeProperty) - getModuleSize(b.data, sizeProperty)); + return layout(rootWithSizesAndSorted); + }, [ + data, + getModuleFilterMultiplier, + getModuleSize, + getNodeSizeMultiplier, + layout, + rawHierarchy, + sizeProperty, + ]); + console.timeEnd("root hierarchy compute"); + return (u$1(g$1, { children: [u$1(SideBar, { sizeProperty: sizeProperty, availableSizeProperties: availableSizeProperties, setSizeProperty: setSizeProperty, onExcludeChange: setExcludeFilter, onIncludeChange: setIncludeFilter }), u$1(Chart, { root: root, sizeProperty: sizeProperty, selectedNode: selectedNode, setSelectedNode: setSelectedNode })] })); + }; + + function initRange(domain, range) { + switch (arguments.length) { + case 0: break; + case 1: this.range(domain); break; + default: this.range(range).domain(domain); break; + } + return this; + } + + function initInterpolator(domain, interpolator) { + switch (arguments.length) { + case 0: break; + case 1: { + if (typeof domain === "function") this.interpolator(domain); + else this.range(domain); + break; + } + default: { + this.domain(domain); + if (typeof interpolator === "function") this.interpolator(interpolator); + else this.range(interpolator); + break; + } + } + return this; + } + + function define(constructor, factory, prototype) { + constructor.prototype = factory.prototype = prototype; + prototype.constructor = constructor; + } + + function extend(parent, definition) { + var prototype = Object.create(parent.prototype); + for (var key in definition) prototype[key] = definition[key]; + return prototype; + } + + function Color() {} + + var darker = 0.7; + var brighter = 1 / darker; + + var reI = "\\s*([+-]?\\d+)\\s*", + reN = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*", + reP = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*", + reHex = /^#([0-9a-f]{3,8})$/, + reRgbInteger = new RegExp(`^rgb\\(${reI},${reI},${reI}\\)$`), + reRgbPercent = new RegExp(`^rgb\\(${reP},${reP},${reP}\\)$`), + reRgbaInteger = new RegExp(`^rgba\\(${reI},${reI},${reI},${reN}\\)$`), + reRgbaPercent = new RegExp(`^rgba\\(${reP},${reP},${reP},${reN}\\)$`), + reHslPercent = new RegExp(`^hsl\\(${reN},${reP},${reP}\\)$`), + reHslaPercent = new RegExp(`^hsla\\(${reN},${reP},${reP},${reN}\\)$`); + + var named = { + aliceblue: 0xf0f8ff, + antiquewhite: 0xfaebd7, + aqua: 0x00ffff, + aquamarine: 0x7fffd4, + azure: 0xf0ffff, + beige: 0xf5f5dc, + bisque: 0xffe4c4, + black: 0x000000, + blanchedalmond: 0xffebcd, + blue: 0x0000ff, + blueviolet: 0x8a2be2, + brown: 0xa52a2a, + burlywood: 0xdeb887, + cadetblue: 0x5f9ea0, + chartreuse: 0x7fff00, + chocolate: 0xd2691e, + coral: 0xff7f50, + cornflowerblue: 0x6495ed, + cornsilk: 0xfff8dc, + crimson: 0xdc143c, + cyan: 0x00ffff, + darkblue: 0x00008b, + darkcyan: 0x008b8b, + darkgoldenrod: 0xb8860b, + darkgray: 0xa9a9a9, + darkgreen: 0x006400, + darkgrey: 0xa9a9a9, + darkkhaki: 0xbdb76b, + darkmagenta: 0x8b008b, + darkolivegreen: 0x556b2f, + darkorange: 0xff8c00, + darkorchid: 0x9932cc, + darkred: 0x8b0000, + darksalmon: 0xe9967a, + darkseagreen: 0x8fbc8f, + darkslateblue: 0x483d8b, + darkslategray: 0x2f4f4f, + darkslategrey: 0x2f4f4f, + darkturquoise: 0x00ced1, + darkviolet: 0x9400d3, + deeppink: 0xff1493, + deepskyblue: 0x00bfff, + dimgray: 0x696969, + dimgrey: 0x696969, + dodgerblue: 0x1e90ff, + firebrick: 0xb22222, + floralwhite: 0xfffaf0, + forestgreen: 0x228b22, + fuchsia: 0xff00ff, + gainsboro: 0xdcdcdc, + ghostwhite: 0xf8f8ff, + gold: 0xffd700, + goldenrod: 0xdaa520, + gray: 0x808080, + green: 0x008000, + greenyellow: 0xadff2f, + grey: 0x808080, + honeydew: 0xf0fff0, + hotpink: 0xff69b4, + indianred: 0xcd5c5c, + indigo: 0x4b0082, + ivory: 0xfffff0, + khaki: 0xf0e68c, + lavender: 0xe6e6fa, + lavenderblush: 0xfff0f5, + lawngreen: 0x7cfc00, + lemonchiffon: 0xfffacd, + lightblue: 0xadd8e6, + lightcoral: 0xf08080, + lightcyan: 0xe0ffff, + lightgoldenrodyellow: 0xfafad2, + lightgray: 0xd3d3d3, + lightgreen: 0x90ee90, + lightgrey: 0xd3d3d3, + lightpink: 0xffb6c1, + lightsalmon: 0xffa07a, + lightseagreen: 0x20b2aa, + lightskyblue: 0x87cefa, + lightslategray: 0x778899, + lightslategrey: 0x778899, + lightsteelblue: 0xb0c4de, + lightyellow: 0xffffe0, + lime: 0x00ff00, + limegreen: 0x32cd32, + linen: 0xfaf0e6, + magenta: 0xff00ff, + maroon: 0x800000, + mediumaquamarine: 0x66cdaa, + mediumblue: 0x0000cd, + mediumorchid: 0xba55d3, + mediumpurple: 0x9370db, + mediumseagreen: 0x3cb371, + mediumslateblue: 0x7b68ee, + mediumspringgreen: 0x00fa9a, + mediumturquoise: 0x48d1cc, + mediumvioletred: 0xc71585, + midnightblue: 0x191970, + mintcream: 0xf5fffa, + mistyrose: 0xffe4e1, + moccasin: 0xffe4b5, + navajowhite: 0xffdead, + navy: 0x000080, + oldlace: 0xfdf5e6, + olive: 0x808000, + olivedrab: 0x6b8e23, + orange: 0xffa500, + orangered: 0xff4500, + orchid: 0xda70d6, + palegoldenrod: 0xeee8aa, + palegreen: 0x98fb98, + paleturquoise: 0xafeeee, + palevioletred: 0xdb7093, + papayawhip: 0xffefd5, + peachpuff: 0xffdab9, + peru: 0xcd853f, + pink: 0xffc0cb, + plum: 0xdda0dd, + powderblue: 0xb0e0e6, + purple: 0x800080, + rebeccapurple: 0x663399, + red: 0xff0000, + rosybrown: 0xbc8f8f, + royalblue: 0x4169e1, + saddlebrown: 0x8b4513, + salmon: 0xfa8072, + sandybrown: 0xf4a460, + seagreen: 0x2e8b57, + seashell: 0xfff5ee, + sienna: 0xa0522d, + silver: 0xc0c0c0, + skyblue: 0x87ceeb, + slateblue: 0x6a5acd, + slategray: 0x708090, + slategrey: 0x708090, + snow: 0xfffafa, + springgreen: 0x00ff7f, + steelblue: 0x4682b4, + tan: 0xd2b48c, + teal: 0x008080, + thistle: 0xd8bfd8, + tomato: 0xff6347, + turquoise: 0x40e0d0, + violet: 0xee82ee, + wheat: 0xf5deb3, + white: 0xffffff, + whitesmoke: 0xf5f5f5, + yellow: 0xffff00, + yellowgreen: 0x9acd32 + }; + + define(Color, color, { + copy(channels) { + return Object.assign(new this.constructor, this, channels); + }, + displayable() { + return this.rgb().displayable(); + }, + hex: color_formatHex, // Deprecated! Use color.formatHex. + formatHex: color_formatHex, + formatHex8: color_formatHex8, + formatHsl: color_formatHsl, + formatRgb: color_formatRgb, + toString: color_formatRgb + }); + + function color_formatHex() { + return this.rgb().formatHex(); + } + + function color_formatHex8() { + return this.rgb().formatHex8(); + } + + function color_formatHsl() { + return hslConvert(this).formatHsl(); + } + + function color_formatRgb() { + return this.rgb().formatRgb(); + } + + function color(format) { + var m, l; + format = (format + "").trim().toLowerCase(); + return (m = reHex.exec(format)) ? (l = m[1].length, m = parseInt(m[1], 16), l === 6 ? rgbn(m) // #ff0000 + : l === 3 ? new Rgb((m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), ((m & 0xf) << 4) | (m & 0xf), 1) // #f00 + : l === 8 ? rgba(m >> 24 & 0xff, m >> 16 & 0xff, m >> 8 & 0xff, (m & 0xff) / 0xff) // #ff000000 + : l === 4 ? rgba((m >> 12 & 0xf) | (m >> 8 & 0xf0), (m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), (((m & 0xf) << 4) | (m & 0xf)) / 0xff) // #f000 + : null) // invalid hex + : (m = reRgbInteger.exec(format)) ? new Rgb(m[1], m[2], m[3], 1) // rgb(255, 0, 0) + : (m = reRgbPercent.exec(format)) ? new Rgb(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, 1) // rgb(100%, 0%, 0%) + : (m = reRgbaInteger.exec(format)) ? rgba(m[1], m[2], m[3], m[4]) // rgba(255, 0, 0, 1) + : (m = reRgbaPercent.exec(format)) ? rgba(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, m[4]) // rgb(100%, 0%, 0%, 1) + : (m = reHslPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, 1) // hsl(120, 50%, 50%) + : (m = reHslaPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, m[4]) // hsla(120, 50%, 50%, 1) + : named.hasOwnProperty(format) ? rgbn(named[format]) // eslint-disable-line no-prototype-builtins + : format === "transparent" ? new Rgb(NaN, NaN, NaN, 0) + : null; + } + + function rgbn(n) { + return new Rgb(n >> 16 & 0xff, n >> 8 & 0xff, n & 0xff, 1); + } + + function rgba(r, g, b, a) { + if (a <= 0) r = g = b = NaN; + return new Rgb(r, g, b, a); + } + + function rgbConvert(o) { + if (!(o instanceof Color)) o = color(o); + if (!o) return new Rgb; + o = o.rgb(); + return new Rgb(o.r, o.g, o.b, o.opacity); + } + + function rgb$1(r, g, b, opacity) { + return arguments.length === 1 ? rgbConvert(r) : new Rgb(r, g, b, opacity == null ? 1 : opacity); + } + + function Rgb(r, g, b, opacity) { + this.r = +r; + this.g = +g; + this.b = +b; + this.opacity = +opacity; + } + + define(Rgb, rgb$1, extend(Color, { + brighter(k) { + k = k == null ? brighter : Math.pow(brighter, k); + return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity); + }, + darker(k) { + k = k == null ? darker : Math.pow(darker, k); + return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity); + }, + rgb() { + return this; + }, + clamp() { + return new Rgb(clampi(this.r), clampi(this.g), clampi(this.b), clampa(this.opacity)); + }, + displayable() { + return (-0.5 <= this.r && this.r < 255.5) + && (-0.5 <= this.g && this.g < 255.5) + && (-0.5 <= this.b && this.b < 255.5) + && (0 <= this.opacity && this.opacity <= 1); + }, + hex: rgb_formatHex, // Deprecated! Use color.formatHex. + formatHex: rgb_formatHex, + formatHex8: rgb_formatHex8, + formatRgb: rgb_formatRgb, + toString: rgb_formatRgb + })); + + function rgb_formatHex() { + return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}`; + } + + function rgb_formatHex8() { + return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}${hex((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`; + } + + function rgb_formatRgb() { + const a = clampa(this.opacity); + return `${a === 1 ? "rgb(" : "rgba("}${clampi(this.r)}, ${clampi(this.g)}, ${clampi(this.b)}${a === 1 ? ")" : `, ${a})`}`; + } + + function clampa(opacity) { + return isNaN(opacity) ? 1 : Math.max(0, Math.min(1, opacity)); + } + + function clampi(value) { + return Math.max(0, Math.min(255, Math.round(value) || 0)); + } + + function hex(value) { + value = clampi(value); + return (value < 16 ? "0" : "") + value.toString(16); + } + + function hsla(h, s, l, a) { + if (a <= 0) h = s = l = NaN; + else if (l <= 0 || l >= 1) h = s = NaN; + else if (s <= 0) h = NaN; + return new Hsl(h, s, l, a); + } + + function hslConvert(o) { + if (o instanceof Hsl) return new Hsl(o.h, o.s, o.l, o.opacity); + if (!(o instanceof Color)) o = color(o); + if (!o) return new Hsl; + if (o instanceof Hsl) return o; + o = o.rgb(); + var r = o.r / 255, + g = o.g / 255, + b = o.b / 255, + min = Math.min(r, g, b), + max = Math.max(r, g, b), + h = NaN, + s = max - min, + l = (max + min) / 2; + if (s) { + if (r === max) h = (g - b) / s + (g < b) * 6; + else if (g === max) h = (b - r) / s + 2; + else h = (r - g) / s + 4; + s /= l < 0.5 ? max + min : 2 - max - min; + h *= 60; + } else { + s = l > 0 && l < 1 ? 0 : h; + } + return new Hsl(h, s, l, o.opacity); + } + + function hsl(h, s, l, opacity) { + return arguments.length === 1 ? hslConvert(h) : new Hsl(h, s, l, opacity == null ? 1 : opacity); + } + + function Hsl(h, s, l, opacity) { + this.h = +h; + this.s = +s; + this.l = +l; + this.opacity = +opacity; + } + + define(Hsl, hsl, extend(Color, { + brighter(k) { + k = k == null ? brighter : Math.pow(brighter, k); + return new Hsl(this.h, this.s, this.l * k, this.opacity); + }, + darker(k) { + k = k == null ? darker : Math.pow(darker, k); + return new Hsl(this.h, this.s, this.l * k, this.opacity); + }, + rgb() { + var h = this.h % 360 + (this.h < 0) * 360, + s = isNaN(h) || isNaN(this.s) ? 0 : this.s, + l = this.l, + m2 = l + (l < 0.5 ? l : 1 - l) * s, + m1 = 2 * l - m2; + return new Rgb( + hsl2rgb(h >= 240 ? h - 240 : h + 120, m1, m2), + hsl2rgb(h, m1, m2), + hsl2rgb(h < 120 ? h + 240 : h - 120, m1, m2), + this.opacity + ); + }, + clamp() { + return new Hsl(clamph(this.h), clampt(this.s), clampt(this.l), clampa(this.opacity)); + }, + displayable() { + return (0 <= this.s && this.s <= 1 || isNaN(this.s)) + && (0 <= this.l && this.l <= 1) + && (0 <= this.opacity && this.opacity <= 1); + }, + formatHsl() { + const a = clampa(this.opacity); + return `${a === 1 ? "hsl(" : "hsla("}${clamph(this.h)}, ${clampt(this.s) * 100}%, ${clampt(this.l) * 100}%${a === 1 ? ")" : `, ${a})`}`; + } + })); + + function clamph(value) { + value = (value || 0) % 360; + return value < 0 ? value + 360 : value; + } + + function clampt(value) { + return Math.max(0, Math.min(1, value || 0)); + } + + /* From FvD 13.37, CSS Color Module Level 3 */ + function hsl2rgb(h, m1, m2) { + return (h < 60 ? m1 + (m2 - m1) * h / 60 + : h < 180 ? m2 + : h < 240 ? m1 + (m2 - m1) * (240 - h) / 60 + : m1) * 255; + } + + var constant = x => () => x; + + function linear$1(a, d) { + return function(t) { + return a + t * d; + }; + } + + function exponential(a, b, y) { + return a = Math.pow(a, y), b = Math.pow(b, y) - a, y = 1 / y, function(t) { + return Math.pow(a + t * b, y); + }; + } + + function gamma(y) { + return (y = +y) === 1 ? nogamma : function(a, b) { + return b - a ? exponential(a, b, y) : constant(isNaN(a) ? b : a); + }; + } + + function nogamma(a, b) { + var d = b - a; + return d ? linear$1(a, d) : constant(isNaN(a) ? b : a); + } + + var rgb = (function rgbGamma(y) { + var color = gamma(y); + + function rgb(start, end) { + var r = color((start = rgb$1(start)).r, (end = rgb$1(end)).r), + g = color(start.g, end.g), + b = color(start.b, end.b), + opacity = nogamma(start.opacity, end.opacity); + return function(t) { + start.r = r(t); + start.g = g(t); + start.b = b(t); + start.opacity = opacity(t); + return start + ""; + }; + } + + rgb.gamma = rgbGamma; + + return rgb; + })(1); + + function numberArray(a, b) { + if (!b) b = []; + var n = a ? Math.min(b.length, a.length) : 0, + c = b.slice(), + i; + return function(t) { + for (i = 0; i < n; ++i) c[i] = a[i] * (1 - t) + b[i] * t; + return c; + }; + } + + function isNumberArray(x) { + return ArrayBuffer.isView(x) && !(x instanceof DataView); + } + + function genericArray(a, b) { + var nb = b ? b.length : 0, + na = a ? Math.min(nb, a.length) : 0, + x = new Array(na), + c = new Array(nb), + i; + + for (i = 0; i < na; ++i) x[i] = interpolate(a[i], b[i]); + for (; i < nb; ++i) c[i] = b[i]; + + return function(t) { + for (i = 0; i < na; ++i) c[i] = x[i](t); + return c; + }; + } + + function date(a, b) { + var d = new Date; + return a = +a, b = +b, function(t) { + return d.setTime(a * (1 - t) + b * t), d; + }; + } + + function interpolateNumber(a, b) { + return a = +a, b = +b, function(t) { + return a * (1 - t) + b * t; + }; + } + + function object(a, b) { + var i = {}, + c = {}, + k; + + if (a === null || typeof a !== "object") a = {}; + if (b === null || typeof b !== "object") b = {}; + + for (k in b) { + if (k in a) { + i[k] = interpolate(a[k], b[k]); + } else { + c[k] = b[k]; + } + } + + return function(t) { + for (k in i) c[k] = i[k](t); + return c; + }; + } + + var reA = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, + reB = new RegExp(reA.source, "g"); + + function zero(b) { + return function() { + return b; + }; + } + + function one(b) { + return function(t) { + return b(t) + ""; + }; + } + + function string(a, b) { + var bi = reA.lastIndex = reB.lastIndex = 0, // scan index for next number in b + am, // current match in a + bm, // current match in b + bs, // string preceding current number in b, if any + i = -1, // index in s + s = [], // string constants and placeholders + q = []; // number interpolators + + // Coerce inputs to strings. + a = a + "", b = b + ""; + + // Interpolate pairs of numbers in a & b. + while ((am = reA.exec(a)) + && (bm = reB.exec(b))) { + if ((bs = bm.index) > bi) { // a string precedes the next number in b + bs = b.slice(bi, bs); + if (s[i]) s[i] += bs; // coalesce with previous string + else s[++i] = bs; + } + if ((am = am[0]) === (bm = bm[0])) { // numbers in a & b match + if (s[i]) s[i] += bm; // coalesce with previous string + else s[++i] = bm; + } else { // interpolate non-matching numbers + s[++i] = null; + q.push({i: i, x: interpolateNumber(am, bm)}); + } + bi = reB.lastIndex; + } + + // Add remains of b. + if (bi < b.length) { + bs = b.slice(bi); + if (s[i]) s[i] += bs; // coalesce with previous string + else s[++i] = bs; + } + + // Special optimization for only a single match. + // Otherwise, interpolate each of the numbers and rejoin the string. + return s.length < 2 ? (q[0] + ? one(q[0].x) + : zero(b)) + : (b = q.length, function(t) { + for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t); + return s.join(""); + }); + } + + function interpolate(a, b) { + var t = typeof b, c; + return b == null || t === "boolean" ? constant(b) + : (t === "number" ? interpolateNumber + : t === "string" ? ((c = color(b)) ? (b = c, rgb) : string) + : b instanceof color ? rgb + : b instanceof Date ? date + : isNumberArray(b) ? numberArray + : Array.isArray(b) ? genericArray + : typeof b.valueOf !== "function" && typeof b.toString !== "function" || isNaN(b) ? object + : interpolateNumber)(a, b); + } + + function interpolateRound(a, b) { + return a = +a, b = +b, function(t) { + return Math.round(a * (1 - t) + b * t); + }; + } + + function constants(x) { + return function() { + return x; + }; + } + + function number(x) { + return +x; + } + + var unit = [0, 1]; + + function identity$1(x) { + return x; + } + + function normalize(a, b) { + return (b -= (a = +a)) + ? function(x) { return (x - a) / b; } + : constants(isNaN(b) ? NaN : 0.5); + } + + function clamper(a, b) { + var t; + if (a > b) t = a, a = b, b = t; + return function(x) { return Math.max(a, Math.min(b, x)); }; + } + + // normalize(a, b)(x) takes a domain value x in [a,b] and returns the corresponding parameter t in [0,1]. + // interpolate(a, b)(t) takes a parameter t in [0,1] and returns the corresponding range value x in [a,b]. + function bimap(domain, range, interpolate) { + var d0 = domain[0], d1 = domain[1], r0 = range[0], r1 = range[1]; + if (d1 < d0) d0 = normalize(d1, d0), r0 = interpolate(r1, r0); + else d0 = normalize(d0, d1), r0 = interpolate(r0, r1); + return function(x) { return r0(d0(x)); }; + } + + function polymap(domain, range, interpolate) { + var j = Math.min(domain.length, range.length) - 1, + d = new Array(j), + r = new Array(j), + i = -1; + + // Reverse descending domains. + if (domain[j] < domain[0]) { + domain = domain.slice().reverse(); + range = range.slice().reverse(); + } + + while (++i < j) { + d[i] = normalize(domain[i], domain[i + 1]); + r[i] = interpolate(range[i], range[i + 1]); + } + + return function(x) { + var i = bisect(domain, x, 1, j) - 1; + return r[i](d[i](x)); + }; + } + + function copy$1(source, target) { + return target + .domain(source.domain()) + .range(source.range()) + .interpolate(source.interpolate()) + .clamp(source.clamp()) + .unknown(source.unknown()); + } + + function transformer$1() { + var domain = unit, + range = unit, + interpolate$1 = interpolate, + transform, + untransform, + unknown, + clamp = identity$1, + piecewise, + output, + input; + + function rescale() { + var n = Math.min(domain.length, range.length); + if (clamp !== identity$1) clamp = clamper(domain[0], domain[n - 1]); + piecewise = n > 2 ? polymap : bimap; + output = input = null; + return scale; + } + + function scale(x) { + return x == null || isNaN(x = +x) ? unknown : (output || (output = piecewise(domain.map(transform), range, interpolate$1)))(transform(clamp(x))); + } + + scale.invert = function(y) { + return clamp(untransform((input || (input = piecewise(range, domain.map(transform), interpolateNumber)))(y))); + }; + + scale.domain = function(_) { + return arguments.length ? (domain = Array.from(_, number), rescale()) : domain.slice(); + }; + + scale.range = function(_) { + return arguments.length ? (range = Array.from(_), rescale()) : range.slice(); + }; + + scale.rangeRound = function(_) { + return range = Array.from(_), interpolate$1 = interpolateRound, rescale(); + }; + + scale.clamp = function(_) { + return arguments.length ? (clamp = _ ? true : identity$1, rescale()) : clamp !== identity$1; + }; + + scale.interpolate = function(_) { + return arguments.length ? (interpolate$1 = _, rescale()) : interpolate$1; + }; + + scale.unknown = function(_) { + return arguments.length ? (unknown = _, scale) : unknown; + }; + + return function(t, u) { + transform = t, untransform = u; + return rescale(); + }; + } + + function continuous() { + return transformer$1()(identity$1, identity$1); + } + + function formatDecimal(x) { + return Math.abs(x = Math.round(x)) >= 1e21 + ? x.toLocaleString("en").replace(/,/g, "") + : x.toString(10); + } + + // Computes the decimal coefficient and exponent of the specified number x with + // significant digits p, where x is positive and p is in [1, 21] or undefined. + // For example, formatDecimalParts(1.23) returns ["123", 0]. + function formatDecimalParts(x, p) { + if ((i = (x = p ? x.toExponential(p - 1) : x.toExponential()).indexOf("e")) < 0) return null; // NaN, ±Infinity + var i, coefficient = x.slice(0, i); + + // The string returned by toExponential either has the form \d\.\d+e[-+]\d+ + // (e.g., 1.2e+3) or the form \de[-+]\d+ (e.g., 1e+3). + return [ + coefficient.length > 1 ? coefficient[0] + coefficient.slice(2) : coefficient, + +x.slice(i + 1) + ]; + } + + function exponent(x) { + return x = formatDecimalParts(Math.abs(x)), x ? x[1] : NaN; + } + + function formatGroup(grouping, thousands) { + return function(value, width) { + var i = value.length, + t = [], + j = 0, + g = grouping[0], + length = 0; + + while (i > 0 && g > 0) { + if (length + g + 1 > width) g = Math.max(1, width - length); + t.push(value.substring(i -= g, i + g)); + if ((length += g + 1) > width) break; + g = grouping[j = (j + 1) % grouping.length]; + } + + return t.reverse().join(thousands); + }; + } + + function formatNumerals(numerals) { + return function(value) { + return value.replace(/[0-9]/g, function(i) { + return numerals[+i]; + }); + }; + } + + // [[fill]align][sign][symbol][0][width][,][.precision][~][type] + var re = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i; + + function formatSpecifier(specifier) { + if (!(match = re.exec(specifier))) throw new Error("invalid format: " + specifier); + var match; + return new FormatSpecifier({ + fill: match[1], + align: match[2], + sign: match[3], + symbol: match[4], + zero: match[5], + width: match[6], + comma: match[7], + precision: match[8] && match[8].slice(1), + trim: match[9], + type: match[10] + }); + } + + formatSpecifier.prototype = FormatSpecifier.prototype; // instanceof + + function FormatSpecifier(specifier) { + this.fill = specifier.fill === undefined ? " " : specifier.fill + ""; + this.align = specifier.align === undefined ? ">" : specifier.align + ""; + this.sign = specifier.sign === undefined ? "-" : specifier.sign + ""; + this.symbol = specifier.symbol === undefined ? "" : specifier.symbol + ""; + this.zero = !!specifier.zero; + this.width = specifier.width === undefined ? undefined : +specifier.width; + this.comma = !!specifier.comma; + this.precision = specifier.precision === undefined ? undefined : +specifier.precision; + this.trim = !!specifier.trim; + this.type = specifier.type === undefined ? "" : specifier.type + ""; + } + + FormatSpecifier.prototype.toString = function() { + return this.fill + + this.align + + this.sign + + this.symbol + + (this.zero ? "0" : "") + + (this.width === undefined ? "" : Math.max(1, this.width | 0)) + + (this.comma ? "," : "") + + (this.precision === undefined ? "" : "." + Math.max(0, this.precision | 0)) + + (this.trim ? "~" : "") + + this.type; + }; + + // Trims insignificant zeros, e.g., replaces 1.2000k with 1.2k. + function formatTrim(s) { + out: for (var n = s.length, i = 1, i0 = -1, i1; i < n; ++i) { + switch (s[i]) { + case ".": i0 = i1 = i; break; + case "0": if (i0 === 0) i0 = i; i1 = i; break; + default: if (!+s[i]) break out; if (i0 > 0) i0 = 0; break; + } + } + return i0 > 0 ? s.slice(0, i0) + s.slice(i1 + 1) : s; + } + + var prefixExponent; + + function formatPrefixAuto(x, p) { + var d = formatDecimalParts(x, p); + if (!d) return x + ""; + var coefficient = d[0], + exponent = d[1], + i = exponent - (prefixExponent = Math.max(-8, Math.min(8, Math.floor(exponent / 3))) * 3) + 1, + n = coefficient.length; + return i === n ? coefficient + : i > n ? coefficient + new Array(i - n + 1).join("0") + : i > 0 ? coefficient.slice(0, i) + "." + coefficient.slice(i) + : "0." + new Array(1 - i).join("0") + formatDecimalParts(x, Math.max(0, p + i - 1))[0]; // less than 1y! + } + + function formatRounded(x, p) { + var d = formatDecimalParts(x, p); + if (!d) return x + ""; + var coefficient = d[0], + exponent = d[1]; + return exponent < 0 ? "0." + new Array(-exponent).join("0") + coefficient + : coefficient.length > exponent + 1 ? coefficient.slice(0, exponent + 1) + "." + coefficient.slice(exponent + 1) + : coefficient + new Array(exponent - coefficient.length + 2).join("0"); + } + + var formatTypes = { + "%": (x, p) => (x * 100).toFixed(p), + "b": (x) => Math.round(x).toString(2), + "c": (x) => x + "", + "d": formatDecimal, + "e": (x, p) => x.toExponential(p), + "f": (x, p) => x.toFixed(p), + "g": (x, p) => x.toPrecision(p), + "o": (x) => Math.round(x).toString(8), + "p": (x, p) => formatRounded(x * 100, p), + "r": formatRounded, + "s": formatPrefixAuto, + "X": (x) => Math.round(x).toString(16).toUpperCase(), + "x": (x) => Math.round(x).toString(16) + }; + + function identity(x) { + return x; + } + + var map = Array.prototype.map, + prefixes = ["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"]; + + function formatLocale(locale) { + var group = locale.grouping === undefined || locale.thousands === undefined ? identity : formatGroup(map.call(locale.grouping, Number), locale.thousands + ""), + currencyPrefix = locale.currency === undefined ? "" : locale.currency[0] + "", + currencySuffix = locale.currency === undefined ? "" : locale.currency[1] + "", + decimal = locale.decimal === undefined ? "." : locale.decimal + "", + numerals = locale.numerals === undefined ? identity : formatNumerals(map.call(locale.numerals, String)), + percent = locale.percent === undefined ? "%" : locale.percent + "", + minus = locale.minus === undefined ? "−" : locale.minus + "", + nan = locale.nan === undefined ? "NaN" : locale.nan + ""; + + function newFormat(specifier) { + specifier = formatSpecifier(specifier); + + var fill = specifier.fill, + align = specifier.align, + sign = specifier.sign, + symbol = specifier.symbol, + zero = specifier.zero, + width = specifier.width, + comma = specifier.comma, + precision = specifier.precision, + trim = specifier.trim, + type = specifier.type; + + // The "n" type is an alias for ",g". + if (type === "n") comma = true, type = "g"; + + // The "" type, and any invalid type, is an alias for ".12~g". + else if (!formatTypes[type]) precision === undefined && (precision = 12), trim = true, type = "g"; + + // If zero fill is specified, padding goes after sign and before digits. + if (zero || (fill === "0" && align === "=")) zero = true, fill = "0", align = "="; + + // Compute the prefix and suffix. + // For SI-prefix, the suffix is lazily computed. + var prefix = symbol === "$" ? currencyPrefix : symbol === "#" && /[boxX]/.test(type) ? "0" + type.toLowerCase() : "", + suffix = symbol === "$" ? currencySuffix : /[%p]/.test(type) ? percent : ""; + + // What format function should we use? + // Is this an integer type? + // Can this type generate exponential notation? + var formatType = formatTypes[type], + maybeSuffix = /[defgprs%]/.test(type); + + // Set the default precision if not specified, + // or clamp the specified precision to the supported range. + // For significant precision, it must be in [1, 21]. + // For fixed precision, it must be in [0, 20]. + precision = precision === undefined ? 6 + : /[gprs]/.test(type) ? Math.max(1, Math.min(21, precision)) + : Math.max(0, Math.min(20, precision)); + + function format(value) { + var valuePrefix = prefix, + valueSuffix = suffix, + i, n, c; + + if (type === "c") { + valueSuffix = formatType(value) + valueSuffix; + value = ""; + } else { + value = +value; + + // Determine the sign. -0 is not less than 0, but 1 / -0 is! + var valueNegative = value < 0 || 1 / value < 0; + + // Perform the initial formatting. + value = isNaN(value) ? nan : formatType(Math.abs(value), precision); + + // Trim insignificant zeros. + if (trim) value = formatTrim(value); + + // If a negative value rounds to zero after formatting, and no explicit positive sign is requested, hide the sign. + if (valueNegative && +value === 0 && sign !== "+") valueNegative = false; + + // Compute the prefix and suffix. + valuePrefix = (valueNegative ? (sign === "(" ? sign : minus) : sign === "-" || sign === "(" ? "" : sign) + valuePrefix; + valueSuffix = (type === "s" ? prefixes[8 + prefixExponent / 3] : "") + valueSuffix + (valueNegative && sign === "(" ? ")" : ""); + + // Break the formatted value into the integer “value” part that can be + // grouped, and fractional or exponential “suffix” part that is not. + if (maybeSuffix) { + i = -1, n = value.length; + while (++i < n) { + if (c = value.charCodeAt(i), 48 > c || c > 57) { + valueSuffix = (c === 46 ? decimal + value.slice(i + 1) : value.slice(i)) + valueSuffix; + value = value.slice(0, i); + break; + } + } + } + } + + // If the fill character is not "0", grouping is applied before padding. + if (comma && !zero) value = group(value, Infinity); + + // Compute the padding. + var length = valuePrefix.length + value.length + valueSuffix.length, + padding = length < width ? new Array(width - length + 1).join(fill) : ""; + + // If the fill character is "0", grouping is applied after padding. + if (comma && zero) value = group(padding + value, padding.length ? width - valueSuffix.length : Infinity), padding = ""; + + // Reconstruct the final output based on the desired alignment. + switch (align) { + case "<": value = valuePrefix + value + valueSuffix + padding; break; + case "=": value = valuePrefix + padding + value + valueSuffix; break; + case "^": value = padding.slice(0, length = padding.length >> 1) + valuePrefix + value + valueSuffix + padding.slice(length); break; + default: value = padding + valuePrefix + value + valueSuffix; break; + } + + return numerals(value); + } + + format.toString = function() { + return specifier + ""; + }; + + return format; + } + + function formatPrefix(specifier, value) { + var f = newFormat((specifier = formatSpecifier(specifier), specifier.type = "f", specifier)), + e = Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3, + k = Math.pow(10, -e), + prefix = prefixes[8 + e / 3]; + return function(value) { + return f(k * value) + prefix; + }; + } + + return { + format: newFormat, + formatPrefix: formatPrefix + }; + } + + var locale; + var format; + var formatPrefix; + + defaultLocale({ + thousands: ",", + grouping: [3], + currency: ["$", ""] + }); + + function defaultLocale(definition) { + locale = formatLocale(definition); + format = locale.format; + formatPrefix = locale.formatPrefix; + return locale; + } + + function precisionFixed(step) { + return Math.max(0, -exponent(Math.abs(step))); + } + + function precisionPrefix(step, value) { + return Math.max(0, Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3 - exponent(Math.abs(step))); + } + + function precisionRound(step, max) { + step = Math.abs(step), max = Math.abs(max) - step; + return Math.max(0, exponent(max) - exponent(step)) + 1; + } + + function tickFormat(start, stop, count, specifier) { + var step = tickStep(start, stop, count), + precision; + specifier = formatSpecifier(specifier == null ? ",f" : specifier); + switch (specifier.type) { + case "s": { + var value = Math.max(Math.abs(start), Math.abs(stop)); + if (specifier.precision == null && !isNaN(precision = precisionPrefix(step, value))) specifier.precision = precision; + return formatPrefix(specifier, value); + } + case "": + case "e": + case "g": + case "p": + case "r": { + if (specifier.precision == null && !isNaN(precision = precisionRound(step, Math.max(Math.abs(start), Math.abs(stop))))) specifier.precision = precision - (specifier.type === "e"); + break; + } + case "f": + case "%": { + if (specifier.precision == null && !isNaN(precision = precisionFixed(step))) specifier.precision = precision - (specifier.type === "%") * 2; + break; + } + } + return format(specifier); + } + + function linearish(scale) { + var domain = scale.domain; + + scale.ticks = function(count) { + var d = domain(); + return ticks(d[0], d[d.length - 1], count == null ? 10 : count); + }; + + scale.tickFormat = function(count, specifier) { + var d = domain(); + return tickFormat(d[0], d[d.length - 1], count == null ? 10 : count, specifier); + }; + + scale.nice = function(count) { + if (count == null) count = 10; + + var d = domain(); + var i0 = 0; + var i1 = d.length - 1; + var start = d[i0]; + var stop = d[i1]; + var prestep; + var step; + var maxIter = 10; + + if (stop < start) { + step = start, start = stop, stop = step; + step = i0, i0 = i1, i1 = step; + } + + while (maxIter-- > 0) { + step = tickIncrement(start, stop, count); + if (step === prestep) { + d[i0] = start; + d[i1] = stop; + return domain(d); + } else if (step > 0) { + start = Math.floor(start / step) * step; + stop = Math.ceil(stop / step) * step; + } else if (step < 0) { + start = Math.ceil(start * step) / step; + stop = Math.floor(stop * step) / step; + } else { + break; + } + prestep = step; + } + + return scale; + }; + + return scale; + } + + function linear() { + var scale = continuous(); + + scale.copy = function() { + return copy$1(scale, linear()); + }; + + initRange.apply(scale, arguments); + + return linearish(scale); + } + + function transformer() { + var x0 = 0, + x1 = 1, + t0, + t1, + k10, + transform, + interpolator = identity$1, + clamp = false, + unknown; + + function scale(x) { + return x == null || isNaN(x = +x) ? unknown : interpolator(k10 === 0 ? 0.5 : (x = (transform(x) - t0) * k10, clamp ? Math.max(0, Math.min(1, x)) : x)); + } + + scale.domain = function(_) { + return arguments.length ? ([x0, x1] = _, t0 = transform(x0 = +x0), t1 = transform(x1 = +x1), k10 = t0 === t1 ? 0 : 1 / (t1 - t0), scale) : [x0, x1]; + }; + + scale.clamp = function(_) { + return arguments.length ? (clamp = !!_, scale) : clamp; + }; + + scale.interpolator = function(_) { + return arguments.length ? (interpolator = _, scale) : interpolator; + }; + + function range(interpolate) { + return function(_) { + var r0, r1; + return arguments.length ? ([r0, r1] = _, interpolator = interpolate(r0, r1), scale) : [interpolator(0), interpolator(1)]; + }; + } + + scale.range = range(interpolate); + + scale.rangeRound = range(interpolateRound); + + scale.unknown = function(_) { + return arguments.length ? (unknown = _, scale) : unknown; + }; + + return function(t) { + transform = t, t0 = t(x0), t1 = t(x1), k10 = t0 === t1 ? 0 : 1 / (t1 - t0); + return scale; + }; + } + + function copy(source, target) { + return target + .domain(source.domain()) + .interpolator(source.interpolator()) + .clamp(source.clamp()) + .unknown(source.unknown()); + } + + function sequential() { + var scale = linearish(transformer()(identity$1)); + + scale.copy = function() { + return copy(scale, sequential()); + }; + + return initInterpolator.apply(scale, arguments); + } + + const COLOR_BASE = "#cecece"; + + // https://www.w3.org/TR/WCAG20/#relativeluminancedef + const rc = 0.2126; + const gc = 0.7152; + const bc = 0.0722; + // low-gamma adjust coefficient + const lowc = 1 / 12.92; + function adjustGamma(p) { + return Math.pow((p + 0.055) / 1.055, 2.4); + } + function relativeLuminance(o) { + const rsrgb = o.r / 255; + const gsrgb = o.g / 255; + const bsrgb = o.b / 255; + const r = rsrgb <= 0.03928 ? rsrgb * lowc : adjustGamma(rsrgb); + const g = gsrgb <= 0.03928 ? gsrgb * lowc : adjustGamma(gsrgb); + const b = bsrgb <= 0.03928 ? bsrgb * lowc : adjustGamma(bsrgb); + return r * rc + g * gc + b * bc; + } + const createRainbowColor = (root) => { + const colorParentMap = new Map(); + colorParentMap.set(root, COLOR_BASE); + if (root.children != null) { + const colorScale = sequential([0, root.children.length], (n) => hsl(360 * n, 0.3, 0.85)); + root.children.forEach((c, id) => { + colorParentMap.set(c, colorScale(id).toString()); + }); + } + const colorMap = new Map(); + const lightScale = linear().domain([0, root.height]).range([0.9, 0.3]); + const getBackgroundColor = (node) => { + const parents = node.ancestors(); + const colorStr = parents.length === 1 + ? colorParentMap.get(parents[0]) + : colorParentMap.get(parents[parents.length - 2]); + const hslColor = hsl(colorStr); + hslColor.l = lightScale(node.depth); + return hslColor; + }; + return (node) => { + if (!colorMap.has(node)) { + const backgroundColor = getBackgroundColor(node); + const l = relativeLuminance(backgroundColor.rgb()); + const fontColor = l > 0.19 ? "#000" : "#fff"; + colorMap.set(node, { + backgroundColor: backgroundColor.toString(), + fontColor, + }); + } + return colorMap.get(node); + }; + }; + + const StaticContext = F$1({}); + const drawChart = (parentNode, data, width, height) => { + const availableSizeProperties = getAvailableSizeOptions(data.options); + console.time("layout create"); + const layout = treemap() + .size([width, height]) + .paddingOuter(PADDING) + .paddingTop(TOP_PADDING) + .paddingInner(PADDING) + .round(true) + .tile(treemapResquarify); + console.timeEnd("layout create"); + console.time("rawHierarchy create"); + const rawHierarchy = hierarchy(data.tree); + console.timeEnd("rawHierarchy create"); + const nodeSizesCache = new Map(); + const nodeIdsCache = new Map(); + const getModuleSize = (node, sizeKey) => { var _a, _b; return (_b = (_a = nodeSizesCache.get(node)) === null || _a === void 0 ? void 0 : _a[sizeKey]) !== null && _b !== void 0 ? _b : 0; }; + console.time("rawHierarchy eachAfter cache"); + rawHierarchy.eachAfter((node) => { + var _a; + const nodeData = node.data; + nodeIdsCache.set(nodeData, { + nodeUid: generateUniqueId("node"), + clipUid: generateUniqueId("clip"), + }); + const sizes = { renderedLength: 0, gzipLength: 0, brotliLength: 0 }; + if (isModuleTree(nodeData)) { + for (const sizeKey of availableSizeProperties) { + sizes[sizeKey] = nodeData.children.reduce((acc, child) => getModuleSize(child, sizeKey) + acc, 0); + } + } + else { + for (const sizeKey of availableSizeProperties) { + sizes[sizeKey] = (_a = data.nodeParts[nodeData.uid][sizeKey]) !== null && _a !== void 0 ? _a : 0; + } + } + nodeSizesCache.set(nodeData, sizes); + }); + console.timeEnd("rawHierarchy eachAfter cache"); + const getModuleIds = (node) => nodeIdsCache.get(node); + console.time("color"); + const getModuleColor = createRainbowColor(rawHierarchy); + console.timeEnd("color"); + q$1(u$1(StaticContext.Provider, { value: { + data, + availableSizeProperties, + width, + height, + getModuleSize, + getModuleIds, + getModuleColor, + rawHierarchy, + layout, + }, children: u$1(Main, {}) }), parentNode); + }; + + exports.StaticContext = StaticContext; + exports.default = drawChart; + + Object.defineProperty(exports, '__esModule', { value: true }); + + return exports; + +})({}); + + /*-->*/ + </script> + <script> + /*<!--*/ + const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.js","children":[{"name":"node_modules/@stdlib","children":[{"name":"error-tools-fmtprodmsg/lib/main.js","uid":"fb258eb7-1"},{"name":"assert-has-symbol-support/lib/main.js","uid":"fb258eb7-3"},{"name":"assert-has-tostringtag-support/lib/main.js","uid":"fb258eb7-5"},{"name":"utils-native-class/lib","children":[{"uid":"fb258eb7-7","name":"tostring.js"},{"uid":"fb258eb7-9","name":"main.js"},{"uid":"fb258eb7-15","name":"tostringtag.js"},{"uid":"fb258eb7-17","name":"polyfill.js"},{"uid":"fb258eb7-19","name":"index.js"}]},{"name":"assert-has-own-property/lib/main.js","uid":"fb258eb7-11"},{"name":"symbol-ctor/lib/main.js","uid":"fb258eb7-13"},{"name":"assert-is-array/lib/main.js","uid":"fb258eb7-21"},{"name":"array-base-assert-is-accessor-array/lib/main.js","uid":"fb258eb7-23"},{"name":"array-base-accessor-getter/lib/main.js","uid":"fb258eb7-25"},{"name":"array-base-getter/lib/main.js","uid":"fb258eb7-27"},{"name":"utils-define-property/lib","children":[{"uid":"fb258eb7-29","name":"define_property.js"},{"uid":"fb258eb7-31","name":"has_define_property_support.js"},{"uid":"fb258eb7-33","name":"builtin.js"},{"uid":"fb258eb7-55","name":"polyfill.js"},{"uid":"fb258eb7-57","name":"index.js"}]},{"name":"string-base-format-interpolate/lib","children":[{"uid":"fb258eb7-35","name":"is_number.js"},{"uid":"fb258eb7-37","name":"zero_pad.js"},{"uid":"fb258eb7-39","name":"format_integer.js"},{"uid":"fb258eb7-41","name":"is_string.js"},{"uid":"fb258eb7-43","name":"format_double.js"},{"uid":"fb258eb7-45","name":"space_pad.js"},{"uid":"fb258eb7-47","name":"main.js"}]},{"name":"string-base-format-tokenize/lib/main.js","uid":"fb258eb7-49"},{"name":"string-format/lib","children":[{"uid":"fb258eb7-51","name":"is_string.js"},{"uid":"fb258eb7-53","name":"main.js"}]},{"name":"utils-define-nonenumerable-read-only-property/lib/main.js","uid":"fb258eb7-59"},{"name":"assert-tools-array-function/lib/main.js","uid":"fb258eb7-61"},{"name":"assert-is-object-like/lib","children":[{"uid":"fb258eb7-63","name":"main.js"},{"uid":"fb258eb7-65","name":"index.js"}]},{"name":"assert-is-buffer/lib/main.js","uid":"fb258eb7-67"},{"name":"regexp-function-name/lib","children":[{"uid":"fb258eb7-69","name":"main.js"},{"uid":"fb258eb7-71","name":"regexp.js"},{"uid":"fb258eb7-73","name":"index.js"}]},{"name":"utils-constructor-name/lib/main.js","uid":"fb258eb7-75"},{"name":"array-dtype/lib","children":[{"uid":"fb258eb7-77","name":"ctor2dtype.js"},{"uid":"fb258eb7-383","name":"ctors.js"},{"uid":"fb258eb7-385","name":"dtypes.js"},{"uid":"fb258eb7-387","name":"main.js"}]},{"name":"assert-is-float64array/lib/main.js","uid":"fb258eb7-79"},{"name":"assert-has-float64array-support/lib","children":[{"uid":"fb258eb7-81","name":"float64array.js"},{"uid":"fb258eb7-83","name":"main.js"}]},{"name":"array-float64/lib","children":[{"uid":"fb258eb7-85","name":"main.js"},{"uid":"fb258eb7-87","name":"polyfill.js"},{"uid":"fb258eb7-89","name":"index.js"}]},{"name":"assert-is-float32array/lib/main.js","uid":"fb258eb7-91"},{"name":"constants-float64-pinf/lib/index.js","uid":"fb258eb7-93"},{"name":"assert-has-float32array-support/lib","children":[{"uid":"fb258eb7-95","name":"float32array.js"},{"uid":"fb258eb7-97","name":"main.js"}]},{"name":"array-float32/lib","children":[{"uid":"fb258eb7-99","name":"main.js"},{"uid":"fb258eb7-101","name":"polyfill.js"},{"uid":"fb258eb7-103","name":"index.js"}]},{"name":"assert-is-uint32array/lib/main.js","uid":"fb258eb7-105"},{"name":"constants-uint32-max/lib/index.js","uid":"fb258eb7-107"},{"name":"assert-has-uint32array-support/lib","children":[{"uid":"fb258eb7-109","name":"uint32array.js"},{"uid":"fb258eb7-111","name":"main.js"}]},{"name":"array-uint32/lib","children":[{"uid":"fb258eb7-113","name":"main.js"},{"uid":"fb258eb7-115","name":"polyfill.js"},{"uid":"fb258eb7-117","name":"index.js"}]},{"name":"assert-is-int32array/lib/main.js","uid":"fb258eb7-119"},{"name":"constants-int32-max/lib/index.js","uid":"fb258eb7-121"},{"name":"constants-int32-min/lib/index.js","uid":"fb258eb7-123"},{"name":"assert-has-int32array-support/lib","children":[{"uid":"fb258eb7-125","name":"int32array.js"},{"uid":"fb258eb7-127","name":"main.js"}]},{"name":"array-int32/lib","children":[{"uid":"fb258eb7-129","name":"main.js"},{"uid":"fb258eb7-131","name":"polyfill.js"},{"uid":"fb258eb7-133","name":"index.js"}]},{"name":"assert-is-uint16array/lib/main.js","uid":"fb258eb7-135"},{"name":"constants-uint16-max/lib/index.js","uid":"fb258eb7-137"},{"name":"assert-has-uint16array-support/lib","children":[{"uid":"fb258eb7-139","name":"uint16array.js"},{"uid":"fb258eb7-141","name":"main.js"}]},{"name":"array-uint16/lib","children":[{"uid":"fb258eb7-143","name":"main.js"},{"uid":"fb258eb7-145","name":"polyfill.js"},{"uid":"fb258eb7-147","name":"index.js"}]},{"name":"assert-is-int16array/lib/main.js","uid":"fb258eb7-149"},{"name":"constants-int16-max/lib/index.js","uid":"fb258eb7-151"},{"name":"constants-int16-min/lib/index.js","uid":"fb258eb7-153"},{"name":"assert-has-int16array-support/lib","children":[{"uid":"fb258eb7-155","name":"int16array.js"},{"uid":"fb258eb7-157","name":"main.js"}]},{"name":"array-int16/lib","children":[{"uid":"fb258eb7-159","name":"main.js"},{"uid":"fb258eb7-161","name":"polyfill.js"},{"uid":"fb258eb7-163","name":"index.js"}]},{"name":"assert-is-uint8array/lib/main.js","uid":"fb258eb7-165"},{"name":"constants-uint8-max/lib/index.js","uid":"fb258eb7-167"},{"name":"assert-has-uint8array-support/lib","children":[{"uid":"fb258eb7-169","name":"uint8array.js"},{"uid":"fb258eb7-171","name":"main.js"}]},{"name":"array-uint8/lib","children":[{"uid":"fb258eb7-173","name":"main.js"},{"uid":"fb258eb7-175","name":"polyfill.js"},{"uid":"fb258eb7-177","name":"index.js"}]},{"name":"assert-is-uint8clampedarray/lib/main.js","uid":"fb258eb7-179"},{"name":"assert-has-uint8clampedarray-support/lib","children":[{"uid":"fb258eb7-181","name":"uint8clampedarray.js"},{"uid":"fb258eb7-183","name":"main.js"}]},{"name":"array-uint8c/lib","children":[{"uid":"fb258eb7-185","name":"main.js"},{"uid":"fb258eb7-187","name":"polyfill.js"},{"uid":"fb258eb7-189","name":"index.js"}]},{"name":"assert-is-int8array/lib/main.js","uid":"fb258eb7-191"},{"name":"constants-int8-max/lib/index.js","uid":"fb258eb7-193"},{"name":"constants-int8-min/lib/index.js","uid":"fb258eb7-195"},{"name":"assert-has-int8array-support/lib","children":[{"uid":"fb258eb7-197","name":"int8array.js"},{"uid":"fb258eb7-199","name":"main.js"}]},{"name":"array-int8/lib","children":[{"uid":"fb258eb7-201","name":"main.js"},{"uid":"fb258eb7-203","name":"polyfill.js"},{"uid":"fb258eb7-205","name":"index.js"}]},{"name":"assert-is-number/lib","children":[{"uid":"fb258eb7-207","name":"primitive.js"},{"uid":"fb258eb7-211","name":"tostring.js"},{"uid":"fb258eb7-213","name":"try2serialize.js"},{"uid":"fb258eb7-215","name":"object.js"},{"uid":"fb258eb7-217","name":"main.js"},{"uid":"fb258eb7-219","name":"index.js"}]},{"name":"number-ctor/lib/main.js","uid":"fb258eb7-209"},{"name":"constants-float64-ninf/lib/index.js","uid":"fb258eb7-221"},{"name":"math-base-special-floor/lib/main.js","uid":"fb258eb7-223"},{"name":"math-base-assert-is-integer/lib/main.js","uid":"fb258eb7-225"},{"name":"assert-is-integer/lib","children":[{"uid":"fb258eb7-227","name":"integer.js"},{"uid":"fb258eb7-229","name":"primitive.js"},{"uid":"fb258eb7-231","name":"object.js"},{"uid":"fb258eb7-233","name":"main.js"},{"uid":"fb258eb7-235","name":"index.js"}]},{"name":"assert-is-nonnegative-integer/lib","children":[{"uid":"fb258eb7-237","name":"primitive.js"},{"uid":"fb258eb7-239","name":"object.js"},{"uid":"fb258eb7-241","name":"main.js"},{"uid":"fb258eb7-243","name":"index.js"}]},{"name":"constants-array-max-array-length/lib/index.js","uid":"fb258eb7-245"},{"name":"assert-is-array-like-object/lib/main.js","uid":"fb258eb7-247"},{"name":"constants-array-max-typed-array-length/lib/index.js","uid":"fb258eb7-249"},{"name":"assert-is-collection/lib/main.js","uid":"fb258eb7-251"},{"name":"assert-is-arraybuffer/lib/main.js","uid":"fb258eb7-253"},{"name":"assert-is-object/lib/main.js","uid":"fb258eb7-255"},{"name":"assert-is-string/lib","children":[{"uid":"fb258eb7-257","name":"primitive.js"},{"uid":"fb258eb7-259","name":"valueof.js"},{"uid":"fb258eb7-261","name":"try2valueof.js"},{"uid":"fb258eb7-263","name":"object.js"},{"uid":"fb258eb7-265","name":"main.js"},{"uid":"fb258eb7-267","name":"index.js"}]},{"name":"utils-type-of/lib","children":[{"name":"fixtures","children":[{"uid":"fb258eb7-269","name":"re.js"},{"uid":"fb258eb7-297","name":"nodelist.js"},{"uid":"fb258eb7-299","name":"typedarray.js"}]},{"uid":"fb258eb7-301","name":"check.js"},{"uid":"fb258eb7-303","name":"main.js"},{"uid":"fb258eb7-305","name":"polyfill.js"},{"uid":"fb258eb7-307","name":"index.js"}]},{"name":"assert-is-boolean/lib","children":[{"uid":"fb258eb7-271","name":"primitive.js"},{"uid":"fb258eb7-275","name":"tostring.js"},{"uid":"fb258eb7-277","name":"try2serialize.js"},{"uid":"fb258eb7-279","name":"object.js"},{"uid":"fb258eb7-281","name":"main.js"},{"uid":"fb258eb7-283","name":"index.js"}]},{"name":"boolean-ctor/lib/main.js","uid":"fb258eb7-273"},{"name":"utils-global/lib","children":[{"uid":"fb258eb7-285","name":"codegen.js"},{"uid":"fb258eb7-287","name":"self.js"},{"uid":"fb258eb7-289","name":"window.js"},{"uid":"fb258eb7-291","name":"global.js"},{"uid":"fb258eb7-293","name":"global_this.js"},{"uid":"fb258eb7-295","name":"main.js"}]},{"name":"assert-is-function/lib/main.js","uid":"fb258eb7-309"},{"name":"complex-float64-ctor/lib","children":[{"uid":"fb258eb7-311","name":"tostring.js"},{"uid":"fb258eb7-313","name":"tojson.js"},{"uid":"fb258eb7-315","name":"main.js"}]},{"name":"number-float64-base-to-float32/lib","children":[{"uid":"fb258eb7-317","name":"main.js"},{"uid":"fb258eb7-319","name":"polyfill.js"},{"uid":"fb258eb7-321","name":"index.js"}]},{"name":"complex-float32-ctor/lib","children":[{"uid":"fb258eb7-323","name":"tostring.js"},{"uid":"fb258eb7-325","name":"tojson.js"},{"uid":"fb258eb7-327","name":"main.js"}]},{"name":"assert-is-complex-like/lib/main.js","uid":"fb258eb7-329"},{"name":"math-base-assert-is-even/lib/main.js","uid":"fb258eb7-331"},{"name":"array-base-assert-is-complex64array/lib/main.js","uid":"fb258eb7-333"},{"name":"array-base-assert-is-complex128array/lib/main.js","uid":"fb258eb7-335"},{"name":"assert-has-iterator-symbol-support/lib/main.js","uid":"fb258eb7-337"},{"name":"symbol-iterator/lib/main.js","uid":"fb258eb7-339"},{"name":"utils-define-nonenumerable-read-only-accessor/lib/main.js","uid":"fb258eb7-341"},{"name":"complex-float32/lib","children":[{"uid":"fb258eb7-343","name":"tostring.js"},{"uid":"fb258eb7-345","name":"tojson.js"},{"uid":"fb258eb7-347","name":"main.js"}]},{"name":"complex-realf/lib/main.js","uid":"fb258eb7-349"},{"name":"complex-imagf/lib/main.js","uid":"fb258eb7-351"},{"name":"strided-base-reinterpret-complex64/lib/main.js","uid":"fb258eb7-353"},{"name":"strided-base-reinterpret-complex128/lib/main.js","uid":"fb258eb7-355"},{"name":"array-complex64/lib","children":[{"uid":"fb258eb7-357","name":"from_iterator.js"},{"uid":"fb258eb7-359","name":"from_iterator_map.js"},{"uid":"fb258eb7-361","name":"from_array.js"},{"uid":"fb258eb7-363","name":"main.js"}]},{"name":"complex-float64/lib","children":[{"uid":"fb258eb7-365","name":"tostring.js"},{"uid":"fb258eb7-367","name":"tojson.js"},{"uid":"fb258eb7-369","name":"main.js"}]},{"name":"complex-real/lib/main.js","uid":"fb258eb7-371"},{"name":"complex-imag/lib/main.js","uid":"fb258eb7-373"},{"name":"array-complex128/lib","children":[{"uid":"fb258eb7-375","name":"from_iterator.js"},{"uid":"fb258eb7-377","name":"from_iterator_map.js"},{"uid":"fb258eb7-379","name":"from_array.js"},{"uid":"fb258eb7-381","name":"main.js"}]},{"name":"array-base-resolve-getter/lib/main.js","uid":"fb258eb7-389"}]},{"name":"lib","children":[{"uid":"fb258eb7-391","name":"main.js"},{"uid":"fb258eb7-393","name":"index.js"}]}]}],"isRoot":true},"nodeParts":{"fb258eb7-1":{"renderedLength":1170,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-0"},"fb258eb7-3":{"renderedLength":975,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-2"},"fb258eb7-5":{"renderedLength":1021,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-4"},"fb258eb7-7":{"renderedLength":690,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-6"},"fb258eb7-9":{"renderedLength":1277,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-8"},"fb258eb7-11":{"renderedLength":1329,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-10"},"fb258eb7-13":{"renderedLength":757,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-12"},"fb258eb7-15":{"renderedLength":719,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-14"},"fb258eb7-17":{"renderedLength":1902,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-16"},"fb258eb7-19":{"renderedLength":806,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-18"},"fb258eb7-21":{"renderedLength":1172,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-20"},"fb258eb7-23":{"renderedLength":1271,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-22"},"fb258eb7-25":{"renderedLength":3475,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-24"},"fb258eb7-27":{"renderedLength":6375,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-26"},"fb258eb7-29":{"renderedLength":742,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-28"},"fb258eb7-31":{"renderedLength":1093,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-30"},"fb258eb7-33":{"renderedLength":2991,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-32"},"fb258eb7-35":{"renderedLength":1216,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-34"},"fb258eb7-37":{"renderedLength":1808,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-36"},"fb258eb7-39":{"renderedLength":2661,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-38"},"fb258eb7-41":{"renderedLength":1154,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-40"},"fb258eb7-43":{"renderedLength":3125,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-42"},"fb258eb7-45":{"renderedLength":1387,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-44"},"fb258eb7-47":{"renderedLength":6312,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-46"},"fb258eb7-49":{"renderedLength":1997,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-48"},"fb258eb7-51":{"renderedLength":1154,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-50"},"fb258eb7-53":{"renderedLength":1470,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-52"},"fb258eb7-55":{"renderedLength":4787,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-54"},"fb258eb7-57":{"renderedLength":852,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-56"},"fb258eb7-59":{"renderedLength":1231,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-58"},"fb258eb7-61":{"renderedLength":1905,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-60"},"fb258eb7-63":{"renderedLength":1101,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-62"},"fb258eb7-65":{"renderedLength":803,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-64"},"fb258eb7-67":{"renderedLength":1592,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-66"},"fb258eb7-69":{"renderedLength":1312,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-68"},"fb258eb7-71":{"renderedLength":1319,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-70"},"fb258eb7-73":{"renderedLength":722,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-72"},"fb258eb7-75":{"renderedLength":1623,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-74"},"fb258eb7-77":{"renderedLength":1058,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-76"},"fb258eb7-79":{"renderedLength":1311,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-78"},"fb258eb7-81":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-80"},"fb258eb7-83":{"renderedLength":1322,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-82"},"fb258eb7-85":{"renderedLength":772,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-84"},"fb258eb7-87":{"renderedLength":901,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-86"},"fb258eb7-89":{"renderedLength":800,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-88"},"fb258eb7-91":{"renderedLength":1311,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-90"},"fb258eb7-93":{"renderedLength":1364,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-92"},"fb258eb7-95":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-94"},"fb258eb7-97":{"renderedLength":1355,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-96"},"fb258eb7-99":{"renderedLength":772,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-98"},"fb258eb7-101":{"renderedLength":901,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-100"},"fb258eb7-103":{"renderedLength":800,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-102"},"fb258eb7-105":{"renderedLength":1300,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-104"},"fb258eb7-107":{"renderedLength":1183,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-106"},"fb258eb7-109":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-108"},"fb258eb7-111":{"renderedLength":1479,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-110"},"fb258eb7-113":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-112"},"fb258eb7-115":{"renderedLength":886,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-114"},"fb258eb7-117":{"renderedLength":798,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-116"},"fb258eb7-119":{"renderedLength":1291,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-118"},"fb258eb7-121":{"renderedLength":1198,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-120"},"fb258eb7-123":{"renderedLength":1217,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-122"},"fb258eb7-125":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-124"},"fb258eb7-127":{"renderedLength":1363,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-126"},"fb258eb7-129":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-128"},"fb258eb7-131":{"renderedLength":900,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-130"},"fb258eb7-133":{"renderedLength":796,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-132"},"fb258eb7-135":{"renderedLength":1300,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-134"},"fb258eb7-137":{"renderedLength":1175,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-136"},"fb258eb7-139":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-138"},"fb258eb7-141":{"renderedLength":1479,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-140"},"fb258eb7-143":{"renderedLength":770,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-142"},"fb258eb7-145":{"renderedLength":886,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-144"},"fb258eb7-147":{"renderedLength":798,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-146"},"fb258eb7-149":{"renderedLength":1291,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-148"},"fb258eb7-151":{"renderedLength":1167,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-150"},"fb258eb7-153":{"renderedLength":1186,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-152"},"fb258eb7-155":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-154"},"fb258eb7-157":{"renderedLength":1363,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-156"},"fb258eb7-159":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-158"},"fb258eb7-161":{"renderedLength":900,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-160"},"fb258eb7-163":{"renderedLength":796,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-162"},"fb258eb7-165":{"renderedLength":1289,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-164"},"fb258eb7-167":{"renderedLength":1154,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-166"},"fb258eb7-169":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-168"},"fb258eb7-171":{"renderedLength":1468,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-170"},"fb258eb7-173":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-172"},"fb258eb7-175":{"renderedLength":885,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-174"},"fb258eb7-177":{"renderedLength":796,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-176"},"fb258eb7-179":{"renderedLength":1366,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-178"},"fb258eb7-181":{"renderedLength":780,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-180"},"fb258eb7-183":{"renderedLength":1514,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-182"},"fb258eb7-185":{"renderedLength":782,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-184"},"fb258eb7-187":{"renderedLength":902,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-186"},"fb258eb7-189":{"renderedLength":810,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-188"},"fb258eb7-191":{"renderedLength":1280,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-190"},"fb258eb7-193":{"renderedLength":1144,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-192"},"fb258eb7-195":{"renderedLength":1163,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-194"},"fb258eb7-197":{"renderedLength":764,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-196"},"fb258eb7-199":{"renderedLength":1354,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-198"},"fb258eb7-201":{"renderedLength":766,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-200"},"fb258eb7-203":{"renderedLength":897,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-202"},"fb258eb7-205":{"renderedLength":784,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-204"},"fb258eb7-207":{"renderedLength":1087,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-206"},"fb258eb7-209":{"renderedLength":719,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-208"},"fb258eb7-211":{"renderedLength":758,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-210"},"fb258eb7-213":{"renderedLength":988,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-212"},"fb258eb7-215":{"renderedLength":1272,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-214"},"fb258eb7-217":{"renderedLength":1165,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-216"},"fb258eb7-219":{"renderedLength":778,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-218"},"fb258eb7-221":{"renderedLength":1091,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-220"},"fb258eb7-223":{"renderedLength":1133,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-222"},"fb258eb7-225":{"renderedLength":1039,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-224"},"fb258eb7-227":{"renderedLength":974,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-226"},"fb258eb7-229":{"renderedLength":1113,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-228"},"fb258eb7-231":{"renderedLength":1115,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-230"},"fb258eb7-233":{"renderedLength":1177,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-232"},"fb258eb7-235":{"renderedLength":782,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-234"},"fb258eb7-237":{"renderedLength":1157,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-236"},"fb258eb7-239":{"renderedLength":1161,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-238"},"fb258eb7-241":{"renderedLength":1354,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-240"},"fb258eb7-243":{"renderedLength":826,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-242"},"fb258eb7-245":{"renderedLength":1072,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-244"},"fb258eb7-247":{"renderedLength":1299,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-246"},"fb258eb7-249":{"renderedLength":1079,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-248"},"fb258eb7-251":{"renderedLength":1189,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-250"},"fb258eb7-253":{"renderedLength":1356,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-252"},"fb258eb7-255":{"renderedLength":1064,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-254"},"fb258eb7-257":{"renderedLength":1026,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-256"},"fb258eb7-259":{"renderedLength":740,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-258"},"fb258eb7-261":{"renderedLength":978,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-260"},"fb258eb7-263":{"renderedLength":1276,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-262"},"fb258eb7-265":{"renderedLength":1037,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-264"},"fb258eb7-267":{"renderedLength":778,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-266"},"fb258eb7-269":{"renderedLength":650,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-268"},"fb258eb7-271":{"renderedLength":1147,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-270"},"fb258eb7-273":{"renderedLength":1099,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-272"},"fb258eb7-275":{"renderedLength":745,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-274"},"fb258eb7-277":{"renderedLength":986,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-276"},"fb258eb7-279":{"renderedLength":1322,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-278"},"fb258eb7-281":{"renderedLength":1292,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-280"},"fb258eb7-283":{"renderedLength":782,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-282"},"fb258eb7-285":{"renderedLength":890,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-284"},"fb258eb7-287":{"renderedLength":705,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-286"},"fb258eb7-289":{"renderedLength":709,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-288"},"fb258eb7-291":{"renderedLength":709,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-290"},"fb258eb7-293":{"renderedLength":747,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-292"},"fb258eb7-295":{"renderedLength":1865,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-294"},"fb258eb7-297":{"renderedLength":733,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-296"},"fb258eb7-299":{"renderedLength":710,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-298"},"fb258eb7-301":{"renderedLength":1330,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-300"},"fb258eb7-303":{"renderedLength":1694,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-302"},"fb258eb7-305":{"renderedLength":849,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-304"},"fb258eb7-307":{"renderedLength":694,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-306"},"fb258eb7-309":{"renderedLength":1181,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-308"},"fb258eb7-311":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-310"},"fb258eb7-313":{"renderedLength":911,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-312"},"fb258eb7-315":{"renderedLength":3742,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-314"},"fb258eb7-317":{"renderedLength":768,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-316"},"fb258eb7-319":{"renderedLength":1142,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-318"},"fb258eb7-321":{"renderedLength":856,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-320"},"fb258eb7-323":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-322"},"fb258eb7-325":{"renderedLength":910,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-324"},"fb258eb7-327":{"renderedLength":3760,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-326"},"fb258eb7-329":{"renderedLength":1413,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-328"},"fb258eb7-331":{"renderedLength":1142,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-330"},"fb258eb7-333":{"renderedLength":1753,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-332"},"fb258eb7-335":{"renderedLength":1765,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-334"},"fb258eb7-337":{"renderedLength":1079,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-336"},"fb258eb7-339":{"renderedLength":1527,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-338"},"fb258eb7-341":{"renderedLength":1315,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-340"},"fb258eb7-343":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-342"},"fb258eb7-345":{"renderedLength":910,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-344"},"fb258eb7-347":{"renderedLength":3746,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-346"},"fb258eb7-349":{"renderedLength":999,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-348"},"fb258eb7-351":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-350"},"fb258eb7-353":{"renderedLength":1283,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-352"},"fb258eb7-355":{"renderedLength":1286,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-354"},"fb258eb7-357":{"renderedLength":1347,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-356"},"fb258eb7-359":{"renderedLength":1531,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-358"},"fb258eb7-361":{"renderedLength":1193,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-360"},"fb258eb7-363":{"renderedLength":70229,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-362"},"fb258eb7-365":{"renderedLength":1007,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-364"},"fb258eb7-367":{"renderedLength":909,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-366"},"fb258eb7-369":{"renderedLength":3724,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-368"},"fb258eb7-371":{"renderedLength":999,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-370"},"fb258eb7-373":{"renderedLength":1009,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-372"},"fb258eb7-375":{"renderedLength":1343,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-374"},"fb258eb7-377":{"renderedLength":1527,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-376"},"fb258eb7-379":{"renderedLength":1189,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-378"},"fb258eb7-381":{"renderedLength":69884,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-380"},"fb258eb7-383":{"renderedLength":904,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-382"},"fb258eb7-385":{"renderedLength":846,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-384"},"fb258eb7-387":{"renderedLength":1373,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-386"},"fb258eb7-389":{"renderedLength":1083,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-388"},"fb258eb7-391":{"renderedLength":1880,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-390"},"fb258eb7-393":{"renderedLength":633,"gzipLength":0,"brotliLength":0,"metaUid":"fb258eb7-392"}},"nodeMetas":{"fb258eb7-0":{"id":"/node_modules/@stdlib/error-tools-fmtprodmsg/lib/main.js","moduleParts":{"index.js":"fb258eb7-1"},"imported":[],"importedBy":[{"uid":"fb258eb7-394"}]},"fb258eb7-2":{"id":"/node_modules/@stdlib/assert-has-symbol-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-3"},"imported":[],"importedBy":[{"uid":"fb258eb7-405"}]},"fb258eb7-4":{"id":"/node_modules/@stdlib/assert-has-tostringtag-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-5"},"imported":[{"uid":"fb258eb7-405"}],"importedBy":[{"uid":"fb258eb7-401"}]},"fb258eb7-6":{"id":"/node_modules/@stdlib/utils-native-class/lib/tostring.js","moduleParts":{"index.js":"fb258eb7-7"},"imported":[],"importedBy":[{"uid":"fb258eb7-8"},{"uid":"fb258eb7-16"}]},"fb258eb7-8":{"id":"/node_modules/@stdlib/utils-native-class/lib/main.js","moduleParts":{"index.js":"fb258eb7-9"},"imported":[{"uid":"fb258eb7-6"}],"importedBy":[{"uid":"fb258eb7-18"}]},"fb258eb7-10":{"id":"/node_modules/@stdlib/assert-has-own-property/lib/main.js","moduleParts":{"index.js":"fb258eb7-11"},"imported":[],"importedBy":[{"uid":"fb258eb7-402"}]},"fb258eb7-12":{"id":"/node_modules/@stdlib/symbol-ctor/lib/main.js","moduleParts":{"index.js":"fb258eb7-13"},"imported":[],"importedBy":[{"uid":"fb258eb7-406"}]},"fb258eb7-14":{"id":"/node_modules/@stdlib/utils-native-class/lib/tostringtag.js","moduleParts":{"index.js":"fb258eb7-15"},"imported":[{"uid":"fb258eb7-406"}],"importedBy":[{"uid":"fb258eb7-16"}]},"fb258eb7-16":{"id":"/node_modules/@stdlib/utils-native-class/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-17"},"imported":[{"uid":"fb258eb7-402"},{"uid":"fb258eb7-14"},{"uid":"fb258eb7-6"}],"importedBy":[{"uid":"fb258eb7-18"}]},"fb258eb7-18":{"id":"/node_modules/@stdlib/utils-native-class/lib/index.js","moduleParts":{"index.js":"fb258eb7-19"},"imported":[{"uid":"fb258eb7-401"},{"uid":"fb258eb7-8"},{"uid":"fb258eb7-16"}],"importedBy":[{"uid":"fb258eb7-20"},{"uid":"fb258eb7-74"},{"uid":"fb258eb7-252"},{"uid":"fb258eb7-262"},{"uid":"fb258eb7-78"},{"uid":"fb258eb7-90"},{"uid":"fb258eb7-104"},{"uid":"fb258eb7-118"},{"uid":"fb258eb7-134"},{"uid":"fb258eb7-148"},{"uid":"fb258eb7-164"},{"uid":"fb258eb7-178"},{"uid":"fb258eb7-190"},{"uid":"fb258eb7-214"},{"uid":"fb258eb7-278"}]},"fb258eb7-20":{"id":"/node_modules/@stdlib/assert-is-array/lib/main.js","moduleParts":{"index.js":"fb258eb7-21"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-395"}]},"fb258eb7-22":{"id":"/node_modules/@stdlib/array-base-assert-is-accessor-array/lib/main.js","moduleParts":{"index.js":"fb258eb7-23"},"imported":[],"importedBy":[{"uid":"fb258eb7-397"}]},"fb258eb7-24":{"id":"/node_modules/@stdlib/array-base-accessor-getter/lib/main.js","moduleParts":{"index.js":"fb258eb7-25"},"imported":[],"importedBy":[{"uid":"fb258eb7-398"}]},"fb258eb7-26":{"id":"/node_modules/@stdlib/array-base-getter/lib/main.js","moduleParts":{"index.js":"fb258eb7-27"},"imported":[],"importedBy":[{"uid":"fb258eb7-399"}]},"fb258eb7-28":{"id":"/node_modules/@stdlib/utils-define-property/lib/define_property.js","moduleParts":{"index.js":"fb258eb7-29"},"imported":[],"importedBy":[{"uid":"fb258eb7-30"}]},"fb258eb7-30":{"id":"/node_modules/@stdlib/utils-define-property/lib/has_define_property_support.js","moduleParts":{"index.js":"fb258eb7-31"},"imported":[{"uid":"fb258eb7-28"}],"importedBy":[{"uid":"fb258eb7-56"}]},"fb258eb7-32":{"id":"/node_modules/@stdlib/utils-define-property/lib/builtin.js","moduleParts":{"index.js":"fb258eb7-33"},"imported":[],"importedBy":[{"uid":"fb258eb7-56"}]},"fb258eb7-34":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/is_number.js","moduleParts":{"index.js":"fb258eb7-35"},"imported":[],"importedBy":[{"uid":"fb258eb7-38"},{"uid":"fb258eb7-42"}]},"fb258eb7-36":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/zero_pad.js","moduleParts":{"index.js":"fb258eb7-37"},"imported":[],"importedBy":[{"uid":"fb258eb7-46"},{"uid":"fb258eb7-38"}]},"fb258eb7-38":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/format_integer.js","moduleParts":{"index.js":"fb258eb7-39"},"imported":[{"uid":"fb258eb7-34"},{"uid":"fb258eb7-36"}],"importedBy":[{"uid":"fb258eb7-46"}]},"fb258eb7-40":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/is_string.js","moduleParts":{"index.js":"fb258eb7-41"},"imported":[],"importedBy":[{"uid":"fb258eb7-46"}]},"fb258eb7-42":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/format_double.js","moduleParts":{"index.js":"fb258eb7-43"},"imported":[{"uid":"fb258eb7-34"}],"importedBy":[{"uid":"fb258eb7-46"}]},"fb258eb7-44":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/space_pad.js","moduleParts":{"index.js":"fb258eb7-45"},"imported":[],"importedBy":[{"uid":"fb258eb7-46"}]},"fb258eb7-46":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/main.js","moduleParts":{"index.js":"fb258eb7-47"},"imported":[{"uid":"fb258eb7-38"},{"uid":"fb258eb7-40"},{"uid":"fb258eb7-42"},{"uid":"fb258eb7-44"},{"uid":"fb258eb7-36"}],"importedBy":[{"uid":"fb258eb7-454"}]},"fb258eb7-48":{"id":"/node_modules/@stdlib/string-base-format-tokenize/lib/main.js","moduleParts":{"index.js":"fb258eb7-49"},"imported":[],"importedBy":[{"uid":"fb258eb7-455"}]},"fb258eb7-50":{"id":"/node_modules/@stdlib/string-format/lib/is_string.js","moduleParts":{"index.js":"fb258eb7-51"},"imported":[],"importedBy":[{"uid":"fb258eb7-52"}]},"fb258eb7-52":{"id":"/node_modules/@stdlib/string-format/lib/main.js","moduleParts":{"index.js":"fb258eb7-53"},"imported":[{"uid":"fb258eb7-454"},{"uid":"fb258eb7-455"},{"uid":"fb258eb7-50"}],"importedBy":[{"uid":"fb258eb7-434"}]},"fb258eb7-54":{"id":"/node_modules/@stdlib/utils-define-property/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-55"},"imported":[{"uid":"fb258eb7-434"}],"importedBy":[{"uid":"fb258eb7-56"}]},"fb258eb7-56":{"id":"/node_modules/@stdlib/utils-define-property/lib/index.js","moduleParts":{"index.js":"fb258eb7-57"},"imported":[{"uid":"fb258eb7-30"},{"uid":"fb258eb7-32"},{"uid":"fb258eb7-54"}],"importedBy":[{"uid":"fb258eb7-58"},{"uid":"fb258eb7-340"},{"uid":"fb258eb7-346"},{"uid":"fb258eb7-368"},{"uid":"fb258eb7-314"},{"uid":"fb258eb7-326"}]},"fb258eb7-58":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-property/lib/main.js","moduleParts":{"index.js":"fb258eb7-59"},"imported":[{"uid":"fb258eb7-56"}],"importedBy":[{"uid":"fb258eb7-418"}]},"fb258eb7-60":{"id":"/node_modules/@stdlib/assert-tools-array-function/lib/main.js","moduleParts":{"index.js":"fb258eb7-61"},"imported":[{"uid":"fb258eb7-395"},{"uid":"fb258eb7-434"}],"importedBy":[{"uid":"fb258eb7-419"}]},"fb258eb7-62":{"id":"/node_modules/@stdlib/assert-is-object-like/lib/main.js","moduleParts":{"index.js":"fb258eb7-63"},"imported":[],"importedBy":[{"uid":"fb258eb7-64"}]},"fb258eb7-64":{"id":"/node_modules/@stdlib/assert-is-object-like/lib/index.js","moduleParts":{"index.js":"fb258eb7-65"},"imported":[{"uid":"fb258eb7-418"},{"uid":"fb258eb7-419"},{"uid":"fb258eb7-62"}],"importedBy":[{"uid":"fb258eb7-66"}]},"fb258eb7-66":{"id":"/node_modules/@stdlib/assert-is-buffer/lib/main.js","moduleParts":{"index.js":"fb258eb7-67"},"imported":[{"uid":"fb258eb7-64"}],"importedBy":[{"uid":"fb258eb7-403"}]},"fb258eb7-68":{"id":"/node_modules/@stdlib/regexp-function-name/lib/main.js","moduleParts":{"index.js":"fb258eb7-69"},"imported":[],"importedBy":[{"uid":"fb258eb7-72"},{"uid":"fb258eb7-70"}]},"fb258eb7-70":{"id":"/node_modules/@stdlib/regexp-function-name/lib/regexp.js","moduleParts":{"index.js":"fb258eb7-71"},"imported":[{"uid":"fb258eb7-68"}],"importedBy":[{"uid":"fb258eb7-72"}]},"fb258eb7-72":{"id":"/node_modules/@stdlib/regexp-function-name/lib/index.js","moduleParts":{"index.js":"fb258eb7-73"},"imported":[{"uid":"fb258eb7-418"},{"uid":"fb258eb7-68"},{"uid":"fb258eb7-70"}],"importedBy":[{"uid":"fb258eb7-74"}]},"fb258eb7-74":{"id":"/node_modules/@stdlib/utils-constructor-name/lib/main.js","moduleParts":{"index.js":"fb258eb7-75"},"imported":[{"uid":"fb258eb7-18"},{"uid":"fb258eb7-72"},{"uid":"fb258eb7-403"}],"importedBy":[{"uid":"fb258eb7-404"}]},"fb258eb7-76":{"id":"/node_modules/@stdlib/array-dtype/lib/ctor2dtype.js","moduleParts":{"index.js":"fb258eb7-77"},"imported":[],"importedBy":[{"uid":"fb258eb7-386"}]},"fb258eb7-78":{"id":"/node_modules/@stdlib/assert-is-float64array/lib/main.js","moduleParts":{"index.js":"fb258eb7-79"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-443"}]},"fb258eb7-80":{"id":"/node_modules/@stdlib/assert-has-float64array-support/lib/float64array.js","moduleParts":{"index.js":"fb258eb7-81"},"imported":[],"importedBy":[{"uid":"fb258eb7-82"}]},"fb258eb7-82":{"id":"/node_modules/@stdlib/assert-has-float64array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-83"},"imported":[{"uid":"fb258eb7-443"},{"uid":"fb258eb7-80"}],"importedBy":[{"uid":"fb258eb7-409"}]},"fb258eb7-84":{"id":"/node_modules/@stdlib/array-float64/lib/main.js","moduleParts":{"index.js":"fb258eb7-85"},"imported":[],"importedBy":[{"uid":"fb258eb7-88"}]},"fb258eb7-86":{"id":"/node_modules/@stdlib/array-float64/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-87"},"imported":[],"importedBy":[{"uid":"fb258eb7-88"}]},"fb258eb7-88":{"id":"/node_modules/@stdlib/array-float64/lib/index.js","moduleParts":{"index.js":"fb258eb7-89"},"imported":[{"uid":"fb258eb7-409"},{"uid":"fb258eb7-84"},{"uid":"fb258eb7-86"}],"importedBy":[{"uid":"fb258eb7-382"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-354"}]},"fb258eb7-90":{"id":"/node_modules/@stdlib/assert-is-float32array/lib/main.js","moduleParts":{"index.js":"fb258eb7-91"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-444"}]},"fb258eb7-92":{"id":"/node_modules/@stdlib/constants-float64-pinf/lib/index.js","moduleParts":{"index.js":"fb258eb7-93"},"imported":[],"importedBy":[{"uid":"fb258eb7-96"},{"uid":"fb258eb7-226"}]},"fb258eb7-94":{"id":"/node_modules/@stdlib/assert-has-float32array-support/lib/float32array.js","moduleParts":{"index.js":"fb258eb7-95"},"imported":[],"importedBy":[{"uid":"fb258eb7-96"}]},"fb258eb7-96":{"id":"/node_modules/@stdlib/assert-has-float32array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-97"},"imported":[{"uid":"fb258eb7-444"},{"uid":"fb258eb7-92"},{"uid":"fb258eb7-94"}],"importedBy":[{"uid":"fb258eb7-410"}]},"fb258eb7-98":{"id":"/node_modules/@stdlib/array-float32/lib/main.js","moduleParts":{"index.js":"fb258eb7-99"},"imported":[],"importedBy":[{"uid":"fb258eb7-102"}]},"fb258eb7-100":{"id":"/node_modules/@stdlib/array-float32/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-101"},"imported":[],"importedBy":[{"uid":"fb258eb7-102"}]},"fb258eb7-102":{"id":"/node_modules/@stdlib/array-float32/lib/index.js","moduleParts":{"index.js":"fb258eb7-103"},"imported":[{"uid":"fb258eb7-410"},{"uid":"fb258eb7-98"},{"uid":"fb258eb7-100"}],"importedBy":[{"uid":"fb258eb7-382"},{"uid":"fb258eb7-362"},{"uid":"fb258eb7-352"},{"uid":"fb258eb7-318"}]},"fb258eb7-104":{"id":"/node_modules/@stdlib/assert-is-uint32array/lib/main.js","moduleParts":{"index.js":"fb258eb7-105"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-445"}]},"fb258eb7-106":{"id":"/node_modules/@stdlib/constants-uint32-max/lib/index.js","moduleParts":{"index.js":"fb258eb7-107"},"imported":[],"importedBy":[{"uid":"fb258eb7-110"}]},"fb258eb7-108":{"id":"/node_modules/@stdlib/assert-has-uint32array-support/lib/uint32array.js","moduleParts":{"index.js":"fb258eb7-109"},"imported":[],"importedBy":[{"uid":"fb258eb7-110"}]},"fb258eb7-110":{"id":"/node_modules/@stdlib/assert-has-uint32array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-111"},"imported":[{"uid":"fb258eb7-445"},{"uid":"fb258eb7-106"},{"uid":"fb258eb7-108"}],"importedBy":[{"uid":"fb258eb7-411"}]},"fb258eb7-112":{"id":"/node_modules/@stdlib/array-uint32/lib/main.js","moduleParts":{"index.js":"fb258eb7-113"},"imported":[],"importedBy":[{"uid":"fb258eb7-116"}]},"fb258eb7-114":{"id":"/node_modules/@stdlib/array-uint32/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-115"},"imported":[],"importedBy":[{"uid":"fb258eb7-116"}]},"fb258eb7-116":{"id":"/node_modules/@stdlib/array-uint32/lib/index.js","moduleParts":{"index.js":"fb258eb7-117"},"imported":[{"uid":"fb258eb7-411"},{"uid":"fb258eb7-112"},{"uid":"fb258eb7-114"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-118":{"id":"/node_modules/@stdlib/assert-is-int32array/lib/main.js","moduleParts":{"index.js":"fb258eb7-119"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-446"}]},"fb258eb7-120":{"id":"/node_modules/@stdlib/constants-int32-max/lib/index.js","moduleParts":{"index.js":"fb258eb7-121"},"imported":[],"importedBy":[{"uid":"fb258eb7-126"}]},"fb258eb7-122":{"id":"/node_modules/@stdlib/constants-int32-min/lib/index.js","moduleParts":{"index.js":"fb258eb7-123"},"imported":[],"importedBy":[{"uid":"fb258eb7-126"}]},"fb258eb7-124":{"id":"/node_modules/@stdlib/assert-has-int32array-support/lib/int32array.js","moduleParts":{"index.js":"fb258eb7-125"},"imported":[],"importedBy":[{"uid":"fb258eb7-126"}]},"fb258eb7-126":{"id":"/node_modules/@stdlib/assert-has-int32array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-127"},"imported":[{"uid":"fb258eb7-446"},{"uid":"fb258eb7-120"},{"uid":"fb258eb7-122"},{"uid":"fb258eb7-124"}],"importedBy":[{"uid":"fb258eb7-412"}]},"fb258eb7-128":{"id":"/node_modules/@stdlib/array-int32/lib/main.js","moduleParts":{"index.js":"fb258eb7-129"},"imported":[],"importedBy":[{"uid":"fb258eb7-132"}]},"fb258eb7-130":{"id":"/node_modules/@stdlib/array-int32/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-131"},"imported":[],"importedBy":[{"uid":"fb258eb7-132"}]},"fb258eb7-132":{"id":"/node_modules/@stdlib/array-int32/lib/index.js","moduleParts":{"index.js":"fb258eb7-133"},"imported":[{"uid":"fb258eb7-412"},{"uid":"fb258eb7-128"},{"uid":"fb258eb7-130"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-134":{"id":"/node_modules/@stdlib/assert-is-uint16array/lib/main.js","moduleParts":{"index.js":"fb258eb7-135"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-447"}]},"fb258eb7-136":{"id":"/node_modules/@stdlib/constants-uint16-max/lib/index.js","moduleParts":{"index.js":"fb258eb7-137"},"imported":[],"importedBy":[{"uid":"fb258eb7-140"}]},"fb258eb7-138":{"id":"/node_modules/@stdlib/assert-has-uint16array-support/lib/uint16array.js","moduleParts":{"index.js":"fb258eb7-139"},"imported":[],"importedBy":[{"uid":"fb258eb7-140"}]},"fb258eb7-140":{"id":"/node_modules/@stdlib/assert-has-uint16array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-141"},"imported":[{"uid":"fb258eb7-447"},{"uid":"fb258eb7-136"},{"uid":"fb258eb7-138"}],"importedBy":[{"uid":"fb258eb7-413"}]},"fb258eb7-142":{"id":"/node_modules/@stdlib/array-uint16/lib/main.js","moduleParts":{"index.js":"fb258eb7-143"},"imported":[],"importedBy":[{"uid":"fb258eb7-146"}]},"fb258eb7-144":{"id":"/node_modules/@stdlib/array-uint16/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-145"},"imported":[],"importedBy":[{"uid":"fb258eb7-146"}]},"fb258eb7-146":{"id":"/node_modules/@stdlib/array-uint16/lib/index.js","moduleParts":{"index.js":"fb258eb7-147"},"imported":[{"uid":"fb258eb7-413"},{"uid":"fb258eb7-142"},{"uid":"fb258eb7-144"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-148":{"id":"/node_modules/@stdlib/assert-is-int16array/lib/main.js","moduleParts":{"index.js":"fb258eb7-149"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-448"}]},"fb258eb7-150":{"id":"/node_modules/@stdlib/constants-int16-max/lib/index.js","moduleParts":{"index.js":"fb258eb7-151"},"imported":[],"importedBy":[{"uid":"fb258eb7-156"}]},"fb258eb7-152":{"id":"/node_modules/@stdlib/constants-int16-min/lib/index.js","moduleParts":{"index.js":"fb258eb7-153"},"imported":[],"importedBy":[{"uid":"fb258eb7-156"}]},"fb258eb7-154":{"id":"/node_modules/@stdlib/assert-has-int16array-support/lib/int16array.js","moduleParts":{"index.js":"fb258eb7-155"},"imported":[],"importedBy":[{"uid":"fb258eb7-156"}]},"fb258eb7-156":{"id":"/node_modules/@stdlib/assert-has-int16array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-157"},"imported":[{"uid":"fb258eb7-448"},{"uid":"fb258eb7-150"},{"uid":"fb258eb7-152"},{"uid":"fb258eb7-154"}],"importedBy":[{"uid":"fb258eb7-414"}]},"fb258eb7-158":{"id":"/node_modules/@stdlib/array-int16/lib/main.js","moduleParts":{"index.js":"fb258eb7-159"},"imported":[],"importedBy":[{"uid":"fb258eb7-162"}]},"fb258eb7-160":{"id":"/node_modules/@stdlib/array-int16/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-161"},"imported":[],"importedBy":[{"uid":"fb258eb7-162"}]},"fb258eb7-162":{"id":"/node_modules/@stdlib/array-int16/lib/index.js","moduleParts":{"index.js":"fb258eb7-163"},"imported":[{"uid":"fb258eb7-414"},{"uid":"fb258eb7-158"},{"uid":"fb258eb7-160"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-164":{"id":"/node_modules/@stdlib/assert-is-uint8array/lib/main.js","moduleParts":{"index.js":"fb258eb7-165"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-449"}]},"fb258eb7-166":{"id":"/node_modules/@stdlib/constants-uint8-max/lib/index.js","moduleParts":{"index.js":"fb258eb7-167"},"imported":[],"importedBy":[{"uid":"fb258eb7-170"}]},"fb258eb7-168":{"id":"/node_modules/@stdlib/assert-has-uint8array-support/lib/uint8array.js","moduleParts":{"index.js":"fb258eb7-169"},"imported":[],"importedBy":[{"uid":"fb258eb7-170"}]},"fb258eb7-170":{"id":"/node_modules/@stdlib/assert-has-uint8array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-171"},"imported":[{"uid":"fb258eb7-449"},{"uid":"fb258eb7-166"},{"uid":"fb258eb7-168"}],"importedBy":[{"uid":"fb258eb7-415"}]},"fb258eb7-172":{"id":"/node_modules/@stdlib/array-uint8/lib/main.js","moduleParts":{"index.js":"fb258eb7-173"},"imported":[],"importedBy":[{"uid":"fb258eb7-176"}]},"fb258eb7-174":{"id":"/node_modules/@stdlib/array-uint8/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-175"},"imported":[],"importedBy":[{"uid":"fb258eb7-176"}]},"fb258eb7-176":{"id":"/node_modules/@stdlib/array-uint8/lib/index.js","moduleParts":{"index.js":"fb258eb7-177"},"imported":[{"uid":"fb258eb7-415"},{"uid":"fb258eb7-172"},{"uid":"fb258eb7-174"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-178":{"id":"/node_modules/@stdlib/assert-is-uint8clampedarray/lib/main.js","moduleParts":{"index.js":"fb258eb7-179"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-450"}]},"fb258eb7-180":{"id":"/node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/uint8clampedarray.js","moduleParts":{"index.js":"fb258eb7-181"},"imported":[],"importedBy":[{"uid":"fb258eb7-182"}]},"fb258eb7-182":{"id":"/node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-183"},"imported":[{"uid":"fb258eb7-450"},{"uid":"fb258eb7-180"}],"importedBy":[{"uid":"fb258eb7-416"}]},"fb258eb7-184":{"id":"/node_modules/@stdlib/array-uint8c/lib/main.js","moduleParts":{"index.js":"fb258eb7-185"},"imported":[],"importedBy":[{"uid":"fb258eb7-188"}]},"fb258eb7-186":{"id":"/node_modules/@stdlib/array-uint8c/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-187"},"imported":[],"importedBy":[{"uid":"fb258eb7-188"}]},"fb258eb7-188":{"id":"/node_modules/@stdlib/array-uint8c/lib/index.js","moduleParts":{"index.js":"fb258eb7-189"},"imported":[{"uid":"fb258eb7-416"},{"uid":"fb258eb7-184"},{"uid":"fb258eb7-186"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-190":{"id":"/node_modules/@stdlib/assert-is-int8array/lib/main.js","moduleParts":{"index.js":"fb258eb7-191"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-451"}]},"fb258eb7-192":{"id":"/node_modules/@stdlib/constants-int8-max/lib/index.js","moduleParts":{"index.js":"fb258eb7-193"},"imported":[],"importedBy":[{"uid":"fb258eb7-198"}]},"fb258eb7-194":{"id":"/node_modules/@stdlib/constants-int8-min/lib/index.js","moduleParts":{"index.js":"fb258eb7-195"},"imported":[],"importedBy":[{"uid":"fb258eb7-198"}]},"fb258eb7-196":{"id":"/node_modules/@stdlib/assert-has-int8array-support/lib/int8array.js","moduleParts":{"index.js":"fb258eb7-197"},"imported":[],"importedBy":[{"uid":"fb258eb7-198"}]},"fb258eb7-198":{"id":"/node_modules/@stdlib/assert-has-int8array-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-199"},"imported":[{"uid":"fb258eb7-451"},{"uid":"fb258eb7-192"},{"uid":"fb258eb7-194"},{"uid":"fb258eb7-196"}],"importedBy":[{"uid":"fb258eb7-417"}]},"fb258eb7-200":{"id":"/node_modules/@stdlib/array-int8/lib/main.js","moduleParts":{"index.js":"fb258eb7-201"},"imported":[],"importedBy":[{"uid":"fb258eb7-204"}]},"fb258eb7-202":{"id":"/node_modules/@stdlib/array-int8/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-203"},"imported":[],"importedBy":[{"uid":"fb258eb7-204"}]},"fb258eb7-204":{"id":"/node_modules/@stdlib/array-int8/lib/index.js","moduleParts":{"index.js":"fb258eb7-205"},"imported":[{"uid":"fb258eb7-417"},{"uid":"fb258eb7-200"},{"uid":"fb258eb7-202"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-206":{"id":"/node_modules/@stdlib/assert-is-number/lib/primitive.js","moduleParts":{"index.js":"fb258eb7-207"},"imported":[],"importedBy":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-216"}]},"fb258eb7-208":{"id":"/node_modules/@stdlib/number-ctor/lib/main.js","moduleParts":{"index.js":"fb258eb7-209"},"imported":[],"importedBy":[{"uid":"fb258eb7-456"}]},"fb258eb7-210":{"id":"/node_modules/@stdlib/assert-is-number/lib/tostring.js","moduleParts":{"index.js":"fb258eb7-211"},"imported":[{"uid":"fb258eb7-456"}],"importedBy":[{"uid":"fb258eb7-212"}]},"fb258eb7-212":{"id":"/node_modules/@stdlib/assert-is-number/lib/try2serialize.js","moduleParts":{"index.js":"fb258eb7-213"},"imported":[{"uid":"fb258eb7-210"}],"importedBy":[{"uid":"fb258eb7-214"}]},"fb258eb7-214":{"id":"/node_modules/@stdlib/assert-is-number/lib/object.js","moduleParts":{"index.js":"fb258eb7-215"},"imported":[{"uid":"fb258eb7-401"},{"uid":"fb258eb7-18"},{"uid":"fb258eb7-456"},{"uid":"fb258eb7-212"}],"importedBy":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-216"}]},"fb258eb7-216":{"id":"/node_modules/@stdlib/assert-is-number/lib/main.js","moduleParts":{"index.js":"fb258eb7-217"},"imported":[{"uid":"fb258eb7-206"},{"uid":"fb258eb7-214"}],"importedBy":[{"uid":"fb258eb7-218"}]},"fb258eb7-218":{"id":"/node_modules/@stdlib/assert-is-number/lib/index.js","moduleParts":{"index.js":"fb258eb7-219"},"imported":[{"uid":"fb258eb7-418"},{"uid":"fb258eb7-216"},{"uid":"fb258eb7-206"},{"uid":"fb258eb7-214"}],"importedBy":[{"uid":"fb258eb7-346"},{"uid":"fb258eb7-368"},{"uid":"fb258eb7-228"},{"uid":"fb258eb7-230"},{"uid":"fb258eb7-314"},{"uid":"fb258eb7-326"}]},"fb258eb7-220":{"id":"/node_modules/@stdlib/constants-float64-ninf/lib/index.js","moduleParts":{"index.js":"fb258eb7-221"},"imported":[{"uid":"fb258eb7-456"}],"importedBy":[{"uid":"fb258eb7-226"}]},"fb258eb7-222":{"id":"/node_modules/@stdlib/math-base-special-floor/lib/main.js","moduleParts":{"index.js":"fb258eb7-223"},"imported":[],"importedBy":[{"uid":"fb258eb7-437"}]},"fb258eb7-224":{"id":"/node_modules/@stdlib/math-base-assert-is-integer/lib/main.js","moduleParts":{"index.js":"fb258eb7-225"},"imported":[{"uid":"fb258eb7-437"}],"importedBy":[{"uid":"fb258eb7-427"}]},"fb258eb7-226":{"id":"/node_modules/@stdlib/assert-is-integer/lib/integer.js","moduleParts":{"index.js":"fb258eb7-227"},"imported":[{"uid":"fb258eb7-92"},{"uid":"fb258eb7-220"},{"uid":"fb258eb7-427"}],"importedBy":[{"uid":"fb258eb7-228"},{"uid":"fb258eb7-230"}]},"fb258eb7-228":{"id":"/node_modules/@stdlib/assert-is-integer/lib/primitive.js","moduleParts":{"index.js":"fb258eb7-229"},"imported":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-226"}],"importedBy":[{"uid":"fb258eb7-234"},{"uid":"fb258eb7-232"}]},"fb258eb7-230":{"id":"/node_modules/@stdlib/assert-is-integer/lib/object.js","moduleParts":{"index.js":"fb258eb7-231"},"imported":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-226"}],"importedBy":[{"uid":"fb258eb7-234"},{"uid":"fb258eb7-232"}]},"fb258eb7-232":{"id":"/node_modules/@stdlib/assert-is-integer/lib/main.js","moduleParts":{"index.js":"fb258eb7-233"},"imported":[{"uid":"fb258eb7-228"},{"uid":"fb258eb7-230"}],"importedBy":[{"uid":"fb258eb7-234"}]},"fb258eb7-234":{"id":"/node_modules/@stdlib/assert-is-integer/lib/index.js","moduleParts":{"index.js":"fb258eb7-235"},"imported":[{"uid":"fb258eb7-418"},{"uid":"fb258eb7-232"},{"uid":"fb258eb7-228"},{"uid":"fb258eb7-230"}],"importedBy":[{"uid":"fb258eb7-236"},{"uid":"fb258eb7-238"}]},"fb258eb7-236":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/primitive.js","moduleParts":{"index.js":"fb258eb7-237"},"imported":[{"uid":"fb258eb7-234"}],"importedBy":[{"uid":"fb258eb7-242"},{"uid":"fb258eb7-240"}]},"fb258eb7-238":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/object.js","moduleParts":{"index.js":"fb258eb7-239"},"imported":[{"uid":"fb258eb7-234"}],"importedBy":[{"uid":"fb258eb7-242"},{"uid":"fb258eb7-240"}]},"fb258eb7-240":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/main.js","moduleParts":{"index.js":"fb258eb7-241"},"imported":[{"uid":"fb258eb7-236"},{"uid":"fb258eb7-238"}],"importedBy":[{"uid":"fb258eb7-242"}]},"fb258eb7-242":{"id":"/node_modules/@stdlib/assert-is-nonnegative-integer/lib/index.js","moduleParts":{"index.js":"fb258eb7-243"},"imported":[{"uid":"fb258eb7-418"},{"uid":"fb258eb7-240"},{"uid":"fb258eb7-236"},{"uid":"fb258eb7-238"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-244":{"id":"/node_modules/@stdlib/constants-array-max-array-length/lib/index.js","moduleParts":{"index.js":"fb258eb7-245"},"imported":[],"importedBy":[{"uid":"fb258eb7-246"}]},"fb258eb7-246":{"id":"/node_modules/@stdlib/assert-is-array-like-object/lib/main.js","moduleParts":{"index.js":"fb258eb7-247"},"imported":[{"uid":"fb258eb7-427"},{"uid":"fb258eb7-244"}],"importedBy":[{"uid":"fb258eb7-420"}]},"fb258eb7-248":{"id":"/node_modules/@stdlib/constants-array-max-typed-array-length/lib/index.js","moduleParts":{"index.js":"fb258eb7-249"},"imported":[],"importedBy":[{"uid":"fb258eb7-250"}]},"fb258eb7-250":{"id":"/node_modules/@stdlib/assert-is-collection/lib/main.js","moduleParts":{"index.js":"fb258eb7-251"},"imported":[{"uid":"fb258eb7-427"},{"uid":"fb258eb7-248"}],"importedBy":[{"uid":"fb258eb7-421"}]},"fb258eb7-252":{"id":"/node_modules/@stdlib/assert-is-arraybuffer/lib/main.js","moduleParts":{"index.js":"fb258eb7-253"},"imported":[{"uid":"fb258eb7-18"}],"importedBy":[{"uid":"fb258eb7-422"}]},"fb258eb7-254":{"id":"/node_modules/@stdlib/assert-is-object/lib/main.js","moduleParts":{"index.js":"fb258eb7-255"},"imported":[{"uid":"fb258eb7-395"}],"importedBy":[{"uid":"fb258eb7-423"}]},"fb258eb7-256":{"id":"/node_modules/@stdlib/assert-is-string/lib/primitive.js","moduleParts":{"index.js":"fb258eb7-257"},"imported":[],"importedBy":[{"uid":"fb258eb7-266"},{"uid":"fb258eb7-264"}]},"fb258eb7-258":{"id":"/node_modules/@stdlib/assert-is-string/lib/valueof.js","moduleParts":{"index.js":"fb258eb7-259"},"imported":[],"importedBy":[{"uid":"fb258eb7-260"}]},"fb258eb7-260":{"id":"/node_modules/@stdlib/assert-is-string/lib/try2valueof.js","moduleParts":{"index.js":"fb258eb7-261"},"imported":[{"uid":"fb258eb7-258"}],"importedBy":[{"uid":"fb258eb7-262"}]},"fb258eb7-262":{"id":"/node_modules/@stdlib/assert-is-string/lib/object.js","moduleParts":{"index.js":"fb258eb7-263"},"imported":[{"uid":"fb258eb7-401"},{"uid":"fb258eb7-18"},{"uid":"fb258eb7-260"}],"importedBy":[{"uid":"fb258eb7-266"},{"uid":"fb258eb7-264"}]},"fb258eb7-264":{"id":"/node_modules/@stdlib/assert-is-string/lib/main.js","moduleParts":{"index.js":"fb258eb7-265"},"imported":[{"uid":"fb258eb7-256"},{"uid":"fb258eb7-262"}],"importedBy":[{"uid":"fb258eb7-266"}]},"fb258eb7-266":{"id":"/node_modules/@stdlib/assert-is-string/lib/index.js","moduleParts":{"index.js":"fb258eb7-267"},"imported":[{"uid":"fb258eb7-418"},{"uid":"fb258eb7-264"},{"uid":"fb258eb7-256"},{"uid":"fb258eb7-262"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-268":{"id":"/node_modules/@stdlib/utils-type-of/lib/fixtures/re.js","moduleParts":{"index.js":"fb258eb7-269"},"imported":[],"importedBy":[{"uid":"fb258eb7-300"}]},"fb258eb7-270":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/primitive.js","moduleParts":{"index.js":"fb258eb7-271"},"imported":[],"importedBy":[{"uid":"fb258eb7-282"},{"uid":"fb258eb7-280"}]},"fb258eb7-272":{"id":"/node_modules/@stdlib/boolean-ctor/lib/main.js","moduleParts":{"index.js":"fb258eb7-273"},"imported":[],"importedBy":[{"uid":"fb258eb7-458"}]},"fb258eb7-274":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/tostring.js","moduleParts":{"index.js":"fb258eb7-275"},"imported":[],"importedBy":[{"uid":"fb258eb7-276"}]},"fb258eb7-276":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/try2serialize.js","moduleParts":{"index.js":"fb258eb7-277"},"imported":[{"uid":"fb258eb7-274"}],"importedBy":[{"uid":"fb258eb7-278"}]},"fb258eb7-278":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/object.js","moduleParts":{"index.js":"fb258eb7-279"},"imported":[{"uid":"fb258eb7-401"},{"uid":"fb258eb7-18"},{"uid":"fb258eb7-458"},{"uid":"fb258eb7-276"}],"importedBy":[{"uid":"fb258eb7-282"},{"uid":"fb258eb7-280"}]},"fb258eb7-280":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/main.js","moduleParts":{"index.js":"fb258eb7-281"},"imported":[{"uid":"fb258eb7-270"},{"uid":"fb258eb7-278"}],"importedBy":[{"uid":"fb258eb7-282"}]},"fb258eb7-282":{"id":"/node_modules/@stdlib/assert-is-boolean/lib/index.js","moduleParts":{"index.js":"fb258eb7-283"},"imported":[{"uid":"fb258eb7-418"},{"uid":"fb258eb7-280"},{"uid":"fb258eb7-270"},{"uid":"fb258eb7-278"}],"importedBy":[{"uid":"fb258eb7-294"}]},"fb258eb7-284":{"id":"/node_modules/@stdlib/utils-global/lib/codegen.js","moduleParts":{"index.js":"fb258eb7-285"},"imported":[],"importedBy":[{"uid":"fb258eb7-294"}]},"fb258eb7-286":{"id":"/node_modules/@stdlib/utils-global/lib/self.js","moduleParts":{"index.js":"fb258eb7-287"},"imported":[],"importedBy":[{"uid":"fb258eb7-294"}]},"fb258eb7-288":{"id":"/node_modules/@stdlib/utils-global/lib/window.js","moduleParts":{"index.js":"fb258eb7-289"},"imported":[],"importedBy":[{"uid":"fb258eb7-294"}]},"fb258eb7-290":{"id":"/node_modules/@stdlib/utils-global/lib/global.js","moduleParts":{"index.js":"fb258eb7-291"},"imported":[],"importedBy":[{"uid":"fb258eb7-294"}]},"fb258eb7-292":{"id":"/node_modules/@stdlib/utils-global/lib/global_this.js","moduleParts":{"index.js":"fb258eb7-293"},"imported":[],"importedBy":[{"uid":"fb258eb7-294"}]},"fb258eb7-294":{"id":"/node_modules/@stdlib/utils-global/lib/main.js","moduleParts":{"index.js":"fb258eb7-295"},"imported":[{"uid":"fb258eb7-282"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-284"},{"uid":"fb258eb7-286"},{"uid":"fb258eb7-288"},{"uid":"fb258eb7-290"},{"uid":"fb258eb7-292"}],"importedBy":[{"uid":"fb258eb7-457"}]},"fb258eb7-296":{"id":"/node_modules/@stdlib/utils-type-of/lib/fixtures/nodelist.js","moduleParts":{"index.js":"fb258eb7-297"},"imported":[{"uid":"fb258eb7-457"}],"importedBy":[{"uid":"fb258eb7-300"}]},"fb258eb7-298":{"id":"/node_modules/@stdlib/utils-type-of/lib/fixtures/typedarray.js","moduleParts":{"index.js":"fb258eb7-299"},"imported":[],"importedBy":[{"uid":"fb258eb7-300"}]},"fb258eb7-300":{"id":"/node_modules/@stdlib/utils-type-of/lib/check.js","moduleParts":{"index.js":"fb258eb7-301"},"imported":[{"uid":"fb258eb7-268"},{"uid":"fb258eb7-296"},{"uid":"fb258eb7-298"}],"importedBy":[{"uid":"fb258eb7-306"}]},"fb258eb7-302":{"id":"/node_modules/@stdlib/utils-type-of/lib/main.js","moduleParts":{"index.js":"fb258eb7-303"},"imported":[{"uid":"fb258eb7-404"}],"importedBy":[{"uid":"fb258eb7-306"}]},"fb258eb7-304":{"id":"/node_modules/@stdlib/utils-type-of/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-305"},"imported":[{"uid":"fb258eb7-404"}],"importedBy":[{"uid":"fb258eb7-306"}]},"fb258eb7-306":{"id":"/node_modules/@stdlib/utils-type-of/lib/index.js","moduleParts":{"index.js":"fb258eb7-307"},"imported":[{"uid":"fb258eb7-300"},{"uid":"fb258eb7-302"},{"uid":"fb258eb7-304"}],"importedBy":[{"uid":"fb258eb7-308"}]},"fb258eb7-308":{"id":"/node_modules/@stdlib/assert-is-function/lib/main.js","moduleParts":{"index.js":"fb258eb7-309"},"imported":[{"uid":"fb258eb7-306"}],"importedBy":[{"uid":"fb258eb7-424"}]},"fb258eb7-310":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/tostring.js","moduleParts":{"index.js":"fb258eb7-311"},"imported":[],"importedBy":[{"uid":"fb258eb7-314"}]},"fb258eb7-312":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/tojson.js","moduleParts":{"index.js":"fb258eb7-313"},"imported":[],"importedBy":[{"uid":"fb258eb7-314"}]},"fb258eb7-314":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/main.js","moduleParts":{"index.js":"fb258eb7-315"},"imported":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-56"},{"uid":"fb258eb7-418"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-310"},{"uid":"fb258eb7-312"}],"importedBy":[{"uid":"fb258eb7-452"}]},"fb258eb7-316":{"id":"/node_modules/@stdlib/number-float64-base-to-float32/lib/main.js","moduleParts":{"index.js":"fb258eb7-317"},"imported":[],"importedBy":[{"uid":"fb258eb7-320"}]},"fb258eb7-318":{"id":"/node_modules/@stdlib/number-float64-base-to-float32/lib/polyfill.js","moduleParts":{"index.js":"fb258eb7-319"},"imported":[{"uid":"fb258eb7-102"}],"importedBy":[{"uid":"fb258eb7-320"}]},"fb258eb7-320":{"id":"/node_modules/@stdlib/number-float64-base-to-float32/lib/index.js","moduleParts":{"index.js":"fb258eb7-321"},"imported":[{"uid":"fb258eb7-316"},{"uid":"fb258eb7-318"}],"importedBy":[{"uid":"fb258eb7-346"},{"uid":"fb258eb7-326"}]},"fb258eb7-322":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/tostring.js","moduleParts":{"index.js":"fb258eb7-323"},"imported":[],"importedBy":[{"uid":"fb258eb7-326"}]},"fb258eb7-324":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/tojson.js","moduleParts":{"index.js":"fb258eb7-325"},"imported":[],"importedBy":[{"uid":"fb258eb7-326"}]},"fb258eb7-326":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/main.js","moduleParts":{"index.js":"fb258eb7-327"},"imported":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-56"},{"uid":"fb258eb7-418"},{"uid":"fb258eb7-320"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-322"},{"uid":"fb258eb7-324"}],"importedBy":[{"uid":"fb258eb7-453"}]},"fb258eb7-328":{"id":"/node_modules/@stdlib/assert-is-complex-like/lib/main.js","moduleParts":{"index.js":"fb258eb7-329"},"imported":[{"uid":"fb258eb7-452"},{"uid":"fb258eb7-453"}],"importedBy":[{"uid":"fb258eb7-425"}]},"fb258eb7-330":{"id":"/node_modules/@stdlib/math-base-assert-is-even/lib/main.js","moduleParts":{"index.js":"fb258eb7-331"},"imported":[{"uid":"fb258eb7-427"}],"importedBy":[{"uid":"fb258eb7-426"}]},"fb258eb7-332":{"id":"/node_modules/@stdlib/array-base-assert-is-complex64array/lib/main.js","moduleParts":{"index.js":"fb258eb7-333"},"imported":[],"importedBy":[{"uid":"fb258eb7-428"}]},"fb258eb7-334":{"id":"/node_modules/@stdlib/array-base-assert-is-complex128array/lib/main.js","moduleParts":{"index.js":"fb258eb7-335"},"imported":[],"importedBy":[{"uid":"fb258eb7-429"}]},"fb258eb7-336":{"id":"/node_modules/@stdlib/assert-has-iterator-symbol-support/lib/main.js","moduleParts":{"index.js":"fb258eb7-337"},"imported":[{"uid":"fb258eb7-402"},{"uid":"fb258eb7-406"}],"importedBy":[{"uid":"fb258eb7-430"}]},"fb258eb7-338":{"id":"/node_modules/@stdlib/symbol-iterator/lib/main.js","moduleParts":{"index.js":"fb258eb7-339"},"imported":[{"uid":"fb258eb7-430"}],"importedBy":[{"uid":"fb258eb7-431"}]},"fb258eb7-340":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-accessor/lib/main.js","moduleParts":{"index.js":"fb258eb7-341"},"imported":[{"uid":"fb258eb7-56"}],"importedBy":[{"uid":"fb258eb7-432"}]},"fb258eb7-342":{"id":"/node_modules/@stdlib/complex-float32/lib/tostring.js","moduleParts":{"index.js":"fb258eb7-343"},"imported":[],"importedBy":[{"uid":"fb258eb7-346"}]},"fb258eb7-344":{"id":"/node_modules/@stdlib/complex-float32/lib/tojson.js","moduleParts":{"index.js":"fb258eb7-345"},"imported":[],"importedBy":[{"uid":"fb258eb7-346"}]},"fb258eb7-346":{"id":"/node_modules/@stdlib/complex-float32/lib/main.js","moduleParts":{"index.js":"fb258eb7-347"},"imported":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-56"},{"uid":"fb258eb7-418"},{"uid":"fb258eb7-320"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-342"},{"uid":"fb258eb7-344"}],"importedBy":[{"uid":"fb258eb7-433"}]},"fb258eb7-348":{"id":"/node_modules/@stdlib/complex-realf/lib/main.js","moduleParts":{"index.js":"fb258eb7-349"},"imported":[],"importedBy":[{"uid":"fb258eb7-435"}]},"fb258eb7-350":{"id":"/node_modules/@stdlib/complex-imagf/lib/main.js","moduleParts":{"index.js":"fb258eb7-351"},"imported":[],"importedBy":[{"uid":"fb258eb7-436"}]},"fb258eb7-352":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex64/lib/main.js","moduleParts":{"index.js":"fb258eb7-353"},"imported":[{"uid":"fb258eb7-102"}],"importedBy":[{"uid":"fb258eb7-438"}]},"fb258eb7-354":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex128/lib/main.js","moduleParts":{"index.js":"fb258eb7-355"},"imported":[{"uid":"fb258eb7-88"}],"importedBy":[{"uid":"fb258eb7-439"}]},"fb258eb7-356":{"id":"/node_modules/@stdlib/array-complex64/lib/from_iterator.js","moduleParts":{"index.js":"fb258eb7-357"},"imported":[{"uid":"fb258eb7-420"},{"uid":"fb258eb7-425"},{"uid":"fb258eb7-435"},{"uid":"fb258eb7-436"},{"uid":"fb258eb7-434"}],"importedBy":[{"uid":"fb258eb7-362"}]},"fb258eb7-358":{"id":"/node_modules/@stdlib/array-complex64/lib/from_iterator_map.js","moduleParts":{"index.js":"fb258eb7-359"},"imported":[{"uid":"fb258eb7-420"},{"uid":"fb258eb7-425"},{"uid":"fb258eb7-435"},{"uid":"fb258eb7-436"},{"uid":"fb258eb7-434"}],"importedBy":[{"uid":"fb258eb7-362"}]},"fb258eb7-360":{"id":"/node_modules/@stdlib/array-complex64/lib/from_array.js","moduleParts":{"index.js":"fb258eb7-361"},"imported":[{"uid":"fb258eb7-425"},{"uid":"fb258eb7-435"},{"uid":"fb258eb7-436"}],"importedBy":[{"uid":"fb258eb7-362"}]},"fb258eb7-362":{"id":"/node_modules/@stdlib/array-complex64/lib/main.js","moduleParts":{"index.js":"fb258eb7-363"},"imported":[{"uid":"fb258eb7-242"},{"uid":"fb258eb7-420"},{"uid":"fb258eb7-421"},{"uid":"fb258eb7-422"},{"uid":"fb258eb7-423"},{"uid":"fb258eb7-395"},{"uid":"fb258eb7-266"},{"uid":"fb258eb7-424"},{"uid":"fb258eb7-425"},{"uid":"fb258eb7-426"},{"uid":"fb258eb7-427"},{"uid":"fb258eb7-428"},{"uid":"fb258eb7-429"},{"uid":"fb258eb7-430"},{"uid":"fb258eb7-431"},{"uid":"fb258eb7-418"},{"uid":"fb258eb7-432"},{"uid":"fb258eb7-102"},{"uid":"fb258eb7-433"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-435"},{"uid":"fb258eb7-436"},{"uid":"fb258eb7-437"},{"uid":"fb258eb7-438"},{"uid":"fb258eb7-439"},{"uid":"fb258eb7-399"},{"uid":"fb258eb7-398"},{"uid":"fb258eb7-356"},{"uid":"fb258eb7-358"},{"uid":"fb258eb7-360"}],"importedBy":[{"uid":"fb258eb7-407"}]},"fb258eb7-364":{"id":"/node_modules/@stdlib/complex-float64/lib/tostring.js","moduleParts":{"index.js":"fb258eb7-365"},"imported":[],"importedBy":[{"uid":"fb258eb7-368"}]},"fb258eb7-366":{"id":"/node_modules/@stdlib/complex-float64/lib/tojson.js","moduleParts":{"index.js":"fb258eb7-367"},"imported":[],"importedBy":[{"uid":"fb258eb7-368"}]},"fb258eb7-368":{"id":"/node_modules/@stdlib/complex-float64/lib/main.js","moduleParts":{"index.js":"fb258eb7-369"},"imported":[{"uid":"fb258eb7-218"},{"uid":"fb258eb7-56"},{"uid":"fb258eb7-418"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-364"},{"uid":"fb258eb7-366"}],"importedBy":[{"uid":"fb258eb7-440"}]},"fb258eb7-370":{"id":"/node_modules/@stdlib/complex-real/lib/main.js","moduleParts":{"index.js":"fb258eb7-371"},"imported":[],"importedBy":[{"uid":"fb258eb7-441"}]},"fb258eb7-372":{"id":"/node_modules/@stdlib/complex-imag/lib/main.js","moduleParts":{"index.js":"fb258eb7-373"},"imported":[],"importedBy":[{"uid":"fb258eb7-442"}]},"fb258eb7-374":{"id":"/node_modules/@stdlib/array-complex128/lib/from_iterator.js","moduleParts":{"index.js":"fb258eb7-375"},"imported":[{"uid":"fb258eb7-420"},{"uid":"fb258eb7-425"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-441"},{"uid":"fb258eb7-442"}],"importedBy":[{"uid":"fb258eb7-380"}]},"fb258eb7-376":{"id":"/node_modules/@stdlib/array-complex128/lib/from_iterator_map.js","moduleParts":{"index.js":"fb258eb7-377"},"imported":[{"uid":"fb258eb7-420"},{"uid":"fb258eb7-425"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-441"},{"uid":"fb258eb7-442"}],"importedBy":[{"uid":"fb258eb7-380"}]},"fb258eb7-378":{"id":"/node_modules/@stdlib/array-complex128/lib/from_array.js","moduleParts":{"index.js":"fb258eb7-379"},"imported":[{"uid":"fb258eb7-425"},{"uid":"fb258eb7-441"},{"uid":"fb258eb7-442"}],"importedBy":[{"uid":"fb258eb7-380"}]},"fb258eb7-380":{"id":"/node_modules/@stdlib/array-complex128/lib/main.js","moduleParts":{"index.js":"fb258eb7-381"},"imported":[{"uid":"fb258eb7-242"},{"uid":"fb258eb7-420"},{"uid":"fb258eb7-421"},{"uid":"fb258eb7-422"},{"uid":"fb258eb7-423"},{"uid":"fb258eb7-395"},{"uid":"fb258eb7-266"},{"uid":"fb258eb7-424"},{"uid":"fb258eb7-425"},{"uid":"fb258eb7-426"},{"uid":"fb258eb7-427"},{"uid":"fb258eb7-428"},{"uid":"fb258eb7-429"},{"uid":"fb258eb7-430"},{"uid":"fb258eb7-431"},{"uid":"fb258eb7-418"},{"uid":"fb258eb7-432"},{"uid":"fb258eb7-88"},{"uid":"fb258eb7-440"},{"uid":"fb258eb7-441"},{"uid":"fb258eb7-442"},{"uid":"fb258eb7-437"},{"uid":"fb258eb7-438"},{"uid":"fb258eb7-439"},{"uid":"fb258eb7-399"},{"uid":"fb258eb7-398"},{"uid":"fb258eb7-434"},{"uid":"fb258eb7-374"},{"uid":"fb258eb7-376"},{"uid":"fb258eb7-378"}],"importedBy":[{"uid":"fb258eb7-408"}]},"fb258eb7-382":{"id":"/node_modules/@stdlib/array-dtype/lib/ctors.js","moduleParts":{"index.js":"fb258eb7-383"},"imported":[{"uid":"fb258eb7-88"},{"uid":"fb258eb7-102"},{"uid":"fb258eb7-116"},{"uid":"fb258eb7-132"},{"uid":"fb258eb7-146"},{"uid":"fb258eb7-162"},{"uid":"fb258eb7-176"},{"uid":"fb258eb7-188"},{"uid":"fb258eb7-204"},{"uid":"fb258eb7-407"},{"uid":"fb258eb7-408"}],"importedBy":[{"uid":"fb258eb7-386"}]},"fb258eb7-384":{"id":"/node_modules/@stdlib/array-dtype/lib/dtypes.js","moduleParts":{"index.js":"fb258eb7-385"},"imported":[],"importedBy":[{"uid":"fb258eb7-386"}]},"fb258eb7-386":{"id":"/node_modules/@stdlib/array-dtype/lib/main.js","moduleParts":{"index.js":"fb258eb7-387"},"imported":[{"uid":"fb258eb7-403"},{"uid":"fb258eb7-395"},{"uid":"fb258eb7-404"},{"uid":"fb258eb7-76"},{"uid":"fb258eb7-382"},{"uid":"fb258eb7-384"}],"importedBy":[{"uid":"fb258eb7-400"}]},"fb258eb7-388":{"id":"/node_modules/@stdlib/array-base-resolve-getter/lib/main.js","moduleParts":{"index.js":"fb258eb7-389"},"imported":[{"uid":"fb258eb7-397"},{"uid":"fb258eb7-398"},{"uid":"fb258eb7-399"},{"uid":"fb258eb7-400"}],"importedBy":[{"uid":"fb258eb7-396"}]},"fb258eb7-390":{"id":"/lib/main.js","moduleParts":{"index.js":"fb258eb7-391"},"imported":[{"uid":"fb258eb7-394"},{"uid":"fb258eb7-395"},{"uid":"fb258eb7-396"}],"importedBy":[{"uid":"fb258eb7-392"}]},"fb258eb7-392":{"id":"/lib/index.js","moduleParts":{"index.js":"fb258eb7-393"},"imported":[{"uid":"fb258eb7-390"}],"importedBy":[],"isEntry":true},"fb258eb7-394":{"id":"/node_modules/@stdlib/error-tools-fmtprodmsg/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-0"}],"importedBy":[{"uid":"fb258eb7-390"}]},"fb258eb7-395":{"id":"/node_modules/@stdlib/assert-is-array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-20"}],"importedBy":[{"uid":"fb258eb7-390"},{"uid":"fb258eb7-386"},{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-60"},{"uid":"fb258eb7-254"}]},"fb258eb7-396":{"id":"/node_modules/@stdlib/array-base-resolve-getter/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-388"}],"importedBy":[{"uid":"fb258eb7-390"}]},"fb258eb7-397":{"id":"/node_modules/@stdlib/array-base-assert-is-accessor-array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-22"}],"importedBy":[{"uid":"fb258eb7-388"}]},"fb258eb7-398":{"id":"/node_modules/@stdlib/array-base-accessor-getter/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-24"}],"importedBy":[{"uid":"fb258eb7-388"},{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-399":{"id":"/node_modules/@stdlib/array-base-getter/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-26"}],"importedBy":[{"uid":"fb258eb7-388"},{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-400":{"id":"/node_modules/@stdlib/array-dtype/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-386"}],"importedBy":[{"uid":"fb258eb7-388"}]},"fb258eb7-401":{"id":"/node_modules/@stdlib/assert-has-tostringtag-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-4"}],"importedBy":[{"uid":"fb258eb7-18"},{"uid":"fb258eb7-262"},{"uid":"fb258eb7-214"},{"uid":"fb258eb7-278"}]},"fb258eb7-402":{"id":"/node_modules/@stdlib/assert-has-own-property/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-10"}],"importedBy":[{"uid":"fb258eb7-16"},{"uid":"fb258eb7-336"}]},"fb258eb7-403":{"id":"/node_modules/@stdlib/assert-is-buffer/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-66"}],"importedBy":[{"uid":"fb258eb7-386"},{"uid":"fb258eb7-74"}]},"fb258eb7-404":{"id":"/node_modules/@stdlib/utils-constructor-name/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-74"}],"importedBy":[{"uid":"fb258eb7-386"},{"uid":"fb258eb7-302"},{"uid":"fb258eb7-304"}]},"fb258eb7-405":{"id":"/node_modules/@stdlib/assert-has-symbol-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-2"}],"importedBy":[{"uid":"fb258eb7-4"}]},"fb258eb7-406":{"id":"/node_modules/@stdlib/symbol-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-12"}],"importedBy":[{"uid":"fb258eb7-14"},{"uid":"fb258eb7-336"}]},"fb258eb7-407":{"id":"/node_modules/@stdlib/array-complex64/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-362"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-408":{"id":"/node_modules/@stdlib/array-complex128/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-380"}],"importedBy":[{"uid":"fb258eb7-382"}]},"fb258eb7-409":{"id":"/node_modules/@stdlib/assert-has-float64array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-82"}],"importedBy":[{"uid":"fb258eb7-88"}]},"fb258eb7-410":{"id":"/node_modules/@stdlib/assert-has-float32array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-96"}],"importedBy":[{"uid":"fb258eb7-102"}]},"fb258eb7-411":{"id":"/node_modules/@stdlib/assert-has-uint32array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-110"}],"importedBy":[{"uid":"fb258eb7-116"}]},"fb258eb7-412":{"id":"/node_modules/@stdlib/assert-has-int32array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-126"}],"importedBy":[{"uid":"fb258eb7-132"}]},"fb258eb7-413":{"id":"/node_modules/@stdlib/assert-has-uint16array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-140"}],"importedBy":[{"uid":"fb258eb7-146"}]},"fb258eb7-414":{"id":"/node_modules/@stdlib/assert-has-int16array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-156"}],"importedBy":[{"uid":"fb258eb7-162"}]},"fb258eb7-415":{"id":"/node_modules/@stdlib/assert-has-uint8array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-170"}],"importedBy":[{"uid":"fb258eb7-176"}]},"fb258eb7-416":{"id":"/node_modules/@stdlib/assert-has-uint8clampedarray-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-182"}],"importedBy":[{"uid":"fb258eb7-188"}]},"fb258eb7-417":{"id":"/node_modules/@stdlib/assert-has-int8array-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-198"}],"importedBy":[{"uid":"fb258eb7-204"}]},"fb258eb7-418":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-property/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-58"}],"importedBy":[{"uid":"fb258eb7-64"},{"uid":"fb258eb7-72"},{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-242"},{"uid":"fb258eb7-266"},{"uid":"fb258eb7-346"},{"uid":"fb258eb7-368"},{"uid":"fb258eb7-234"},{"uid":"fb258eb7-218"},{"uid":"fb258eb7-314"},{"uid":"fb258eb7-326"},{"uid":"fb258eb7-282"}]},"fb258eb7-419":{"id":"/node_modules/@stdlib/assert-tools-array-function/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-60"}],"importedBy":[{"uid":"fb258eb7-64"}]},"fb258eb7-420":{"id":"/node_modules/@stdlib/assert-is-array-like-object/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-246"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-356"},{"uid":"fb258eb7-358"},{"uid":"fb258eb7-374"},{"uid":"fb258eb7-376"}]},"fb258eb7-421":{"id":"/node_modules/@stdlib/assert-is-collection/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-250"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-422":{"id":"/node_modules/@stdlib/assert-is-arraybuffer/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-252"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-423":{"id":"/node_modules/@stdlib/assert-is-object/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-254"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-424":{"id":"/node_modules/@stdlib/assert-is-function/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-308"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-425":{"id":"/node_modules/@stdlib/assert-is-complex-like/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-328"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-356"},{"uid":"fb258eb7-358"},{"uid":"fb258eb7-360"},{"uid":"fb258eb7-374"},{"uid":"fb258eb7-376"},{"uid":"fb258eb7-378"}]},"fb258eb7-426":{"id":"/node_modules/@stdlib/math-base-assert-is-even/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-330"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-427":{"id":"/node_modules/@stdlib/math-base-assert-is-integer/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-224"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-246"},{"uid":"fb258eb7-250"},{"uid":"fb258eb7-330"},{"uid":"fb258eb7-226"}]},"fb258eb7-428":{"id":"/node_modules/@stdlib/array-base-assert-is-complex64array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-332"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-429":{"id":"/node_modules/@stdlib/array-base-assert-is-complex128array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-334"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-430":{"id":"/node_modules/@stdlib/assert-has-iterator-symbol-support/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-336"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-338"}]},"fb258eb7-431":{"id":"/node_modules/@stdlib/symbol-iterator/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-338"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-432":{"id":"/node_modules/@stdlib/utils-define-nonenumerable-read-only-accessor/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-340"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-433":{"id":"/node_modules/@stdlib/complex-float32/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-346"}],"importedBy":[{"uid":"fb258eb7-362"}]},"fb258eb7-434":{"id":"/node_modules/@stdlib/string-format/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-52"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-356"},{"uid":"fb258eb7-358"},{"uid":"fb258eb7-374"},{"uid":"fb258eb7-376"},{"uid":"fb258eb7-60"},{"uid":"fb258eb7-346"},{"uid":"fb258eb7-368"},{"uid":"fb258eb7-54"},{"uid":"fb258eb7-314"},{"uid":"fb258eb7-326"},{"uid":"fb258eb7-294"}]},"fb258eb7-435":{"id":"/node_modules/@stdlib/complex-realf/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-348"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-356"},{"uid":"fb258eb7-358"},{"uid":"fb258eb7-360"}]},"fb258eb7-436":{"id":"/node_modules/@stdlib/complex-imagf/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-350"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-356"},{"uid":"fb258eb7-358"},{"uid":"fb258eb7-360"}]},"fb258eb7-437":{"id":"/node_modules/@stdlib/math-base-special-floor/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-222"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"},{"uid":"fb258eb7-224"}]},"fb258eb7-438":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex64/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-352"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-439":{"id":"/node_modules/@stdlib/strided-base-reinterpret-complex128/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-354"}],"importedBy":[{"uid":"fb258eb7-362"},{"uid":"fb258eb7-380"}]},"fb258eb7-440":{"id":"/node_modules/@stdlib/complex-float64/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-368"}],"importedBy":[{"uid":"fb258eb7-380"}]},"fb258eb7-441":{"id":"/node_modules/@stdlib/complex-real/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-370"}],"importedBy":[{"uid":"fb258eb7-380"},{"uid":"fb258eb7-374"},{"uid":"fb258eb7-376"},{"uid":"fb258eb7-378"}]},"fb258eb7-442":{"id":"/node_modules/@stdlib/complex-imag/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-372"}],"importedBy":[{"uid":"fb258eb7-380"},{"uid":"fb258eb7-374"},{"uid":"fb258eb7-376"},{"uid":"fb258eb7-378"}]},"fb258eb7-443":{"id":"/node_modules/@stdlib/assert-is-float64array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-78"}],"importedBy":[{"uid":"fb258eb7-82"}]},"fb258eb7-444":{"id":"/node_modules/@stdlib/assert-is-float32array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-90"}],"importedBy":[{"uid":"fb258eb7-96"}]},"fb258eb7-445":{"id":"/node_modules/@stdlib/assert-is-uint32array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-104"}],"importedBy":[{"uid":"fb258eb7-110"}]},"fb258eb7-446":{"id":"/node_modules/@stdlib/assert-is-int32array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-118"}],"importedBy":[{"uid":"fb258eb7-126"}]},"fb258eb7-447":{"id":"/node_modules/@stdlib/assert-is-uint16array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-134"}],"importedBy":[{"uid":"fb258eb7-140"}]},"fb258eb7-448":{"id":"/node_modules/@stdlib/assert-is-int16array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-148"}],"importedBy":[{"uid":"fb258eb7-156"}]},"fb258eb7-449":{"id":"/node_modules/@stdlib/assert-is-uint8array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-164"}],"importedBy":[{"uid":"fb258eb7-170"}]},"fb258eb7-450":{"id":"/node_modules/@stdlib/assert-is-uint8clampedarray/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-178"}],"importedBy":[{"uid":"fb258eb7-182"}]},"fb258eb7-451":{"id":"/node_modules/@stdlib/assert-is-int8array/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-190"}],"importedBy":[{"uid":"fb258eb7-198"}]},"fb258eb7-452":{"id":"/node_modules/@stdlib/complex-float64-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-314"}],"importedBy":[{"uid":"fb258eb7-328"}]},"fb258eb7-453":{"id":"/node_modules/@stdlib/complex-float32-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-326"}],"importedBy":[{"uid":"fb258eb7-328"}]},"fb258eb7-454":{"id":"/node_modules/@stdlib/string-base-format-interpolate/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-46"}],"importedBy":[{"uid":"fb258eb7-52"}]},"fb258eb7-455":{"id":"/node_modules/@stdlib/string-base-format-tokenize/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-48"}],"importedBy":[{"uid":"fb258eb7-52"}]},"fb258eb7-456":{"id":"/node_modules/@stdlib/number-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-208"}],"importedBy":[{"uid":"fb258eb7-214"},{"uid":"fb258eb7-220"},{"uid":"fb258eb7-210"}]},"fb258eb7-457":{"id":"/node_modules/@stdlib/utils-global/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-294"}],"importedBy":[{"uid":"fb258eb7-296"}]},"fb258eb7-458":{"id":"/node_modules/@stdlib/boolean-ctor/lib/index.js","moduleParts":{},"imported":[{"uid":"fb258eb7-272"}],"importedBy":[{"uid":"fb258eb7-278"}]}},"env":{"rollup":"4.11.0"},"options":{"gzip":false,"brotli":false,"sourcemap":false}}; + + const run = () => { + const width = window.innerWidth; + const height = window.innerHeight; + + const chartNode = document.querySelector("main"); + drawChart.default(chartNode, data, width, height); + }; + + window.addEventListener('resize', run); + + document.addEventListener('DOMContentLoaded', run); + /*-->*/ + </script> +</body> +</html> + diff --git a/test/dist/test.js b/test/dist/test.js deleted file mode 100644 index a8a9c60..0000000 --- a/test/dist/test.js +++ /dev/null @@ -1,33 +0,0 @@ -/** -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -'use strict'; - -// MODULES // - -var tape = require( 'tape' ); -var main = require( './../../dist' ); - - -// TESTS // - -tape( 'main export is defined', function test( t ) { - t.ok( true, __filename ); - t.strictEqual( main !== void 0, true, 'main export is defined' ); - t.end(); -}); diff --git a/test/test.js b/test/test.js deleted file mode 100644 index 33e9787..0000000 --- a/test/test.js +++ /dev/null @@ -1,182 +0,0 @@ -/** -* @license Apache-2.0 -* -* Copyright (c) 2023 The Stdlib Authors. -* -* Licensed under the Apache License, Version 2.0 (the "License"); -* you may not use this file except in compliance with the License. -* You may obtain a copy of the License at -* -* http://www.apache.org/licenses/LICENSE-2.0 -* -* Unless required by applicable law or agreed to in writing, software -* distributed under the License is distributed on an "AS IS" BASIS, -* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -* See the License for the specific language governing permissions and -* limitations under the License. -*/ - -'use strict'; - -// MODULES // - -var tape = require( 'tape' ); -var toAccessorArray = require( '@stdlib/array-base-to-accessor-array' ); -var Float64Array = require( '@stdlib/array-float64' ); -var groupEntries = require( './../lib' ); - - -// TESTS // - -tape( 'main export is a function', function test( t ) { - t.ok( true, __filename ); - t.strictEqual( typeof groupEntries, 'function', 'main export is a function' ); - t.end(); -}); - -tape( 'the function throws an error if provided a first and second argument which do not have the same length', function test( t ) { - t.throws( badValue, RangeError, 'throws an error' ); - t.end(); - - function badValue() { - groupEntries( [ 1, 2, 3 ], [ 0, 0 ] ); - } -}); - -tape( 'the function groups array element entries as arrays associated with distinct keys', function test( t ) { - var expected; - var out; - var x; - var g; - - x = [ 'beep', 'boop', 'foo', 'bar' ]; - g = [ 'b', 'b', 'f', 'b' ]; - - expected = { - 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], - 'f': [ [ 2, 'foo' ] ] - }; - out = groupEntries( x, g ); - - t.deepEqual( out, expected, 'returns expected value' ); - t.end(); -}); - -tape( 'the function groups array element entries as arrays associated with distinct keys (array, typed array)', function test( t ) { - var expected; - var out; - var x; - var g; - - x = [ 'beep', 'boop', 'foo', 'bar' ]; - g = new Float64Array( [ 1, 1, 2, 1 ] ); - - expected = { - '1': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], - '2': [ [ 2, 'foo' ] ] - }; - out = groupEntries( x, g ); - - t.deepEqual( out, expected, 'returns expected value' ); - t.end(); -}); - -tape( 'the function groups array element entries as arrays associated with distinct keys (typed arrays)', function test( t ) { - var expected; - var out; - var x; - var g; - - x = new Float64Array( [ 3.14, 4.2, -1.0, -10.2 ] ); - g = new Float64Array( [ 2, 2, 1, 1 ] ); - - expected = { - '1': [ [ 2, -1.0 ], [ 3, -10.2 ] ], - '2': [ [ 0, 3.14 ], [ 1, 4.2 ] ] - }; - out = groupEntries( x, g ); - - t.deepEqual( out, expected, 'returns expected value' ); - t.end(); -}); - -tape( 'the function groups array element entries as arrays associated with distinct keys (array-like objects)', function test( t ) { - var expected; - var out; - var x; - var g; - - x = { - 'length': 4, - '0': 'beep', - '1': 'boop', - '2': 'foo', - '3': 'bar' - }; - g = { - 'length': 4, - '0': 'be', - '1': 'bo', - '2': 'fo', - '3': 'ba' - }; - - expected = { - 'be': [ [ 0, 'beep' ] ], - 'bo': [ [ 1, 'boop' ] ], - 'fo': [ [ 2, 'foo' ] ], - 'ba': [ [ 3, 'bar' ] ] - }; - out = groupEntries( x, g ); - - t.deepEqual( out, expected, 'returns expected value' ); - t.end(); -}); - -tape( 'the function groups array element entries as arrays associated with distinct keys (accessor arrays)', function test( t ) { - var expected; - var out; - var x; - var g; - - x = toAccessorArray( [ 'beep', 'boop', 'foo', 'bar' ] ); - g = toAccessorArray( [ 'b', 'b', 'f', 'b' ] ); - - expected = { - 'b': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 3, 'bar' ] ], - 'f': [ [ 2, 'foo' ] ] - }; - out = groupEntries( x, g ); - - t.deepEqual( out, expected, 'returns expected value' ); - t.end(); -}); - -tape( 'the function groups array element entries as arrays associated with distinct keys (string serialization)', function test( t ) { - var expected; - var out; - var x; - var g; - - x = [ 'beep', 'boop', 'foo', 'bar' ]; - g = [ {}, {}, {}, {} ]; - - expected = { - '[object Object]': [ [ 0, 'beep' ], [ 1, 'boop' ], [ 2, 'foo' ], [ 3, 'bar' ] ] - }; - out = groupEntries( x, g ); - - t.deepEqual( out, expected, 'returns expected groups' ); - t.end(); -}); - -tape( 'the function returns an empty object if provided an empty array', function test( t ) { - var expected; - var actual; - - expected = {}; - actual = groupEntries( [], [] ); - - t.deepEqual( actual, expected, 'returns expected value' ); - t.end(); -});