UNPKG

@helios-lang/compiler

Version:

Helios is a Domain Specific Language that compiles to Plutus-Core (i.e. Cardano on-chain validator scripts). Helios is a non-Haskell alternative to Plutus. With this library you can compile Helios scripts and build Cardano transactions, all you need to bu

77 lines 1.71 kB
/** * @import { Site, Word } from "@helios-lang/compiler-utils" */ /** * @typedef {{ * site: Site * isNamed(): boolean * isOptional(): boolean * eval(scope: Scope): ArgType * toString(): string * }} FuncArgTypeExprI */ /** * @implements {FuncArgTypeExprI} */ export class FuncArgTypeExpr implements FuncArgTypeExprI { /** * @param {Site} site * @param {Word | undefined} name * @param {Expr} typeExpr * @param {boolean} optional */ constructor(site: Site, name: Word | undefined, typeExpr: Expr, optional: boolean); /** * @readonly * @type {Site} */ readonly site: Site; /** * @private * @readonly * @type {Word | undefined} */ private readonly _name; /** * @private * @readonly * @type {Expr} */ private readonly _typeExpr; /** * @private * @readonly * @type {boolean} */ private readonly _optional; /** * @returns {boolean} */ isNamed(): boolean; /** * @returns {boolean} */ isOptional(): boolean; /** * @param {Scope} scope * @returns {ArgType} */ eval(scope: Scope): ArgType; /** * @returns {string} */ toString(): string; } export type FuncArgTypeExprI = { site: Site; isNamed(): boolean; isOptional(): boolean; eval(scope: Scope): ArgType; toString(): string; }; import type { Site } from "@helios-lang/compiler-utils"; import { Scope } from "../scopes/index.js"; import { ArgType } from "../typecheck/index.js"; import type { Word } from "@helios-lang/compiler-utils"; import { Expr } from "./Expr.js"; //# sourceMappingURL=FuncArgTypeExpr.d.ts.map