Interface AbstractDomain<Concrete, Abstract, Top, Bot, Lift>

An abstract domain as complete lattice with a widening operator, narrowing operator, concretization function, and abstraction function.

interface AbstractDomain<
    Concrete,
    Abstract,
    Top = typeof Top,
    Bot = typeof Bottom,
    Lift extends Abstract | Top | Bot = Abstract | Top | Bot,
> {
    abstract(
        concrete: typeof Top | ReadonlySet<Concrete>,
    ): AbstractDomain<Concrete, Abstract, Top, Bot>;
    bottom(): Lattice<Abstract, Top, Bot, Bot>;
    concretize(limit?: number): typeof Top | ReadonlySet<Concrete>;
    equals(other: Lattice<Abstract, Top, Bot>): boolean;
    isBottom(): this is Lattice<Abstract, Top, Bot, Bot>;
    isTop(): this is Lattice<Abstract, Top, Bot, Top>;
    isValue(): this is Lattice<Abstract, Top, Bot, Abstract>;
    join(
        ...values: Lattice<Abstract, Top, Bot, Abstract | Top | Bot>[],
    ): Lattice<Abstract, Top, Bot>;
    leq(other: Lattice<Abstract, Top, Bot>): boolean;
    meet(
        ...values: Lattice<Abstract, Top, Bot, Abstract | Top | Bot>[],
    ): Lattice<Abstract, Top, Bot>;
    narrow(
        other: AbstractDomain<Concrete, Abstract, Top, Bot>,
    ): AbstractDomain<Concrete, Abstract, Top, Bot>;
    top(): Lattice<Abstract, Top, Bot, Top>;
    toString(): string;
    get value(): Lift;
    widen(
        other: AbstractDomain<Concrete, Abstract, Top, Bot>,
    ): AbstractDomain<Concrete, Abstract, Top, Bot>;
}

Type Parameters

  • Concrete

    Type of an concrete element of the concrete domain for the abstract domain

  • Abstract

    Type of an abstract element of the abstract domain representing possible elements (may exclude Top and Bot)

  • Top = typeof Top

    Type of the Top element of the abstract domain representing all possible elements (defaults to Top)

  • Bot = typeof Bottom

    Type of the Bottom element of the abstract domain representing no possible elements (defaults to Bottom)

  • Lift extends Abstract | Top | Bot = Abstract | Top | Bot

    Type of the abstract elements of the abstract domain (defaults to Abstract or Top or Bot)

Hierarchy (View Summary)

Implemented by

Hierarchy-Diagram

UML class diagram of AbstractDomain

Accessors

Methods

  • Maps the current abstract value into a set of possible concrete values as concretization function of the abstract domain. The result should be Top if the number of concrete values would reach the limit or the resulting set would have infinite many elements.

    Parameters

    • Optionallimit: number

    Returns typeof Top | ReadonlySet<Concrete>