/// /// import type { AnalyticConstruct } from "../../../analysis/predicates"; import { ExpressionASTNode } from "../../../ast/ast_expressions"; import { ExpressionOutlet } from "../../../view/constructs/ExpressionOutlets"; import { ConstructOutlet } from "../../../view/constructs/ConstructOutlet"; import { ConstructDescription, ExpressionContext, SemanticContext } from "../../compilation/contexts"; import { FunctionEntity } from "../../compilation/entities"; import { AtomicType, CompleteObjectType, ExpressionType, FunctionType, Type } from "../../compilation/types"; import { CPPObject } from "../../runtime/objects"; import { Value } from "../../runtime/Value"; import { CPPConstruct, SuccessfullyCompiled } from "../CPPConstruct"; import { PotentialFullExpression } from "../PotentialFullExpression"; import { CompiledTemporaryDeallocator } from "../TemporaryDeallocator"; import { AnalyticExpression } from "./expressions"; import { StringLiteralExpression } from "./StringLiteralExpression"; export declare type ValueCategory = "prvalue" | "lvalue"; export declare abstract class Expression extends PotentialFullExpression { readonly t_analytic: AnalyticExpression; abstract readonly type?: ExpressionType; abstract readonly valueCategory?: ValueCategory; readonly conversionLength: number; readonly foo?: string; protected constructor(context: ExpressionContext, ast: ASTType | undefined); abstract createDefaultOutlet(this: CompiledExpression, element: JQuery, parent?: ConstructOutlet): ExpressionOutlet; isWellTyped(): this is TypedExpression; isPrvalue(this: TypedExpression): this is TypedExpression; isLvalue(this: TypedExpression): this is TypedExpression; isStringLiteralExpression(): this is StringLiteralExpression; isTailChild(child: CPPConstruct): { isTail: boolean; }; abstract describeEvalResult(depth: number): ConstructDescription; analytic(): AnalyticExpression; isSemanticallyEquivalent_impl(other: AnalyticConstruct, ec: SemanticContext): boolean; } export interface t_TypedExpression { readonly _t_isTyped: never; } export interface TypedExpression extends Expression { readonly type: T; readonly valueCategory: V; } export interface CompiledExpression extends TypedExpression, SuccessfullyCompiled { readonly temporaryDeallocator?: CompiledTemporaryDeallocator; } export declare type SpecificCompiledExpression = V extends ValueCategory ? CompiledExpression : never; export interface WellTyped { readonly type: T; readonly valueCategory: V; } export declare type SpecificTypedExpression = TypedExpression; export declare function allWellTyped(expressions: Expression[]): expressions is TypedExpression[]; export declare function allWellTyped(expressions: readonly Expression[]): expressions is readonly TypedExpression[]; export declare function allObjectTyped(expressions: Expression[]): expressions is TypedExpression[]; export declare function allObjectTyped(expressions: readonly Expression[]): expressions is readonly TypedExpression[]; export declare type VCResultTypes = T extends FunctionType ? (V extends "prvalue" ? never : V extends "xvalue" ? never : FunctionEntity) : T extends AtomicType ? (V extends "prvalue" ? Value : V extends "xvalue" ? CPPObject : CPPObject) : T extends CompleteObjectType ? (V extends "prvalue" ? (AtomicType extends T ? Value | CPPObject : CPPObject) : V extends "xvalue" ? CPPObject : CPPObject) : (V extends "prvalue" ? Value | CPPObject : V extends "xvalue" ? CPPObject : CPPObject);