nanolith
Version:
Multi-threading in no time with seamless TypeScript support.
11 lines (10 loc) • 353 B
TypeScript
import type { Mutex } from './mutex.js';
type Value = Uint32Array;
export type SharedUint32 = {
value: Value;
lock: Mutex;
};
export declare const create: () => SharedUint32;
export declare const getValue: (data: SharedUint32) => number;
export declare const setValue: (data: SharedUint32, callback: (int: number) => number) => void;
export {};