@types/cwise-compiler
TypeScript icon, indicating that this package has built-in type declarations

1.1.6 • Public • Published

Installation

npm install --save @types/cwise-compiler

Summary

This package contains type definitions for cwise-compiler (https://github.com/scijs/cwise-compiler).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/cwise-compiler.

index.d.ts

import { CompiledRoutine } from "cwise-parser";
import { NdArray } from "ndarray";

declare namespace cwise_compiler {
    interface BlockIndice {
        blockIndices: number;
    }
    interface OffsetArg {
        offset: number[];
        array: number;
    }
    type ArgType = "array" | "offset" | "shape" | "scalar" | "index" | BlockIndice | OffsetArg;
    interface UserArgs {
        args: ArgType[];
        pre: CompiledRoutine;
        body: CompiledRoutine;
        post: CompiledRoutine;
        debug: boolean;
        funcName: string;
        blockSize: number;
        printCode?: boolean | undefined;
    }
    interface Procedure {
        argTypes: ArgType[];
        shimArgs: string[];
        arrayArgs: number[];
        arrayBlockIndices: number[];
        scalarArgs: number[];
        offsetArgs: OffsetArg[];
        offsetArgIndex: number[];
        indexArgs: number[];
        shapeArgs: number[];
        funcName: string;
        pre: CompiledRoutine;
        body: CompiledRoutine;
        post: CompiledRoutine;
        debug: boolean;
        blockSize?: number | undefined;
    }
}

declare function cwise_compiler(
    user_args: cwise_compiler.UserArgs,
): (a: NdArray, b: NdArray, ...args: NdArray[]) => NdArray;

export = cwise_compiler;

Additional Details

Credits

These definitions were written by taoqf.

/@types/cwise-compiler/

    Package Sidebar

    Install

    npm i @types/cwise-compiler

    Weekly Downloads

    294

    Version

    1.1.6

    License

    MIT

    Unpacked Size

    5.31 kB

    Total Files

    5

    Last publish

    Collaborators

    • types