js-slang
Version:
Javascript-based implementations of Source, written in Typescript
29 lines (28 loc) • 1.4 kB
TypeScript
import { ArrowFunctionExpression, Comment, SourceLocation } from 'estree';
import { StepperBaseNode } from '../../interface';
import { StepperExpression, StepperPattern } from '..';
export declare class StepperArrowFunctionExpression implements ArrowFunctionExpression, StepperBaseNode {
type: 'ArrowFunctionExpression';
params: StepperPattern[];
body: StepperExpression;
expression: boolean;
generator: boolean;
async: boolean;
name?: string;
leadingComments?: Comment[];
trailingComments?: Comment[];
loc?: SourceLocation | null;
range?: [number, number];
constructor(params: StepperPattern[], body: StepperExpression, name?: string, expression?: boolean, generator?: boolean, async?: boolean, leadingComments?: Comment[], trailingComments?: Comment[], loc?: SourceLocation | null, range?: [number, number]);
static create(node: ArrowFunctionExpression): StepperArrowFunctionExpression;
isContractible(): boolean;
isOneStepPossible(): boolean;
contract(): StepperExpression;
oneStep(): StepperExpression;
assignName(name: string): StepperArrowFunctionExpression;
scanAllDeclarationNames(): string[];
substitute(id: StepperPattern, value: StepperExpression, upperBoundName?: string[]): StepperExpression;
freeNames(): string[];
allNames(): string[];
rename(before: string, after: string): StepperExpression;
}