@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
51 lines • 1.7 kB
TypeScript
/**
* @typedef {import("@helios-lang/compiler-utils").Site} Site
* @typedef {import("@helios-lang/ir").SourceMappedStringI} SourceMappedStringI
* @typedef {import("../typecheck/index.js").EvalEntity} EvalEntity
* @typedef {import("../typecheck/index.js").Type} Type
* @typedef {import("../typecheck/index.js").Typed} Typed
*/
/**
* if-then-else expression
*/
export class IfElseExpr extends Expr {
/**
* @param {Site} site
* @param {Type | undefined} prevType
* @param {Type} newType
* @returns {Type}
*/
static reduceBranchType(site: Site, prevType: Type | undefined, newType: Type): Type;
/**
* @param {Site} site
* @param {Type | undefined} prevType
* @param {Typed} newValue
* @returns {Type | undefined} - never ErrorType
*/
static reduceBranchMultiType(site: Site, prevType: Type | undefined, newValue: Typed): Type | undefined;
/**
* @param {Site} site
* @param {Expr[]} conditions
* @param {Expr[]} branches
*/
constructor(site: Site, conditions: Expr[], branches: Expr[]);
/**
* @private
* @readonly
* @type {Expr[]}
*/
private readonly _conditions;
/**
* @private
* @readonly
* @type {Expr[]}
*/
private readonly _branches;
}
export type Site = import("@helios-lang/compiler-utils").Site;
export type SourceMappedStringI = import("@helios-lang/ir").SourceMappedStringI;
export type EvalEntity = import("../typecheck/index.js").EvalEntity;
export type Type = import("../typecheck/index.js").Type;
export type Typed = import("../typecheck/index.js").Typed;
import { Expr } from "./Expr.js";
//# sourceMappingURL=IfElseExpr.d.ts.map