Navigation
API > API/Runtime > API/Runtime/VerseCompiler > API/Runtime/VerseCompiler/uLang
Classes
| Type | Name | Description | |
|---|---|---|---|
| CAliasType | Encodes a type alias as a non-normal CTypeBase. | ||
| CArrayType | A parametric type of arrays with a specific element type: []t where t:type | ||
| CAstCompilationUnit | A group of packages that must be compiled as a unit (= a strongly connected component (SCC) in the dependency graph) | ||
| CAstNode | Abstract base class for AST nodes. | ||
| CAstPackage | Represents a package in the AST. | ||
| CAstPackageRef | Encapsulates a reference to an AST/IR package | ||
| CAstProject | Represents a project in the AST. | ||
| CAttributable | Base class for everything that can have attributes attached to it (classes, expressions, etc.) | ||
| CClass | Class defining a class instance / object [Might break off CStructType to differentiate stack based types.] | ||
| CClassDefinition | |||
| CCompatConstraintRoot | Serves as an alternate root scope for definitions in packages that define compatibility constraints. | ||
| CControlScope | Represents a function body or a nested scope within a function body. | ||
| CDataDefinition | Joining structure, making data-members attributable. | ||
| CDefinition | The base class of scoped definitions. | ||
| CEnumeration | Enumeration type @jira SOL-1013 : Make enums derive from Class? | ||
| CEnumerator | Description for a single enumerator | ||
| CExprArchetypeInstantiation | Represents an initializer-list style construction for certain object types; i.e.: Type{expr1, id=expr2, ...} | ||
| CExprArrayTypeFormer | |||
| CExprArrow | Create a function type from a parameter and return type. | ||
| CExprAssignment | Assignment expr1 = expr2, expr1 := expr2, expr1 += expr2, etc. | ||
| CExprBinaryArithmetic | |||
| CExprBinaryOp | Base class of binary operators. | ||
| CExprBranch | Branch concurrency primitive - branch {Coro()} One async expression started and next expression executed immediately while the started expression continues independently until completion or the surrounding context (such as a coroutine) completes in which case it aborts early. | ||
| CExprBreak | Control flow early exitloop: if (IsEarlyExit[]): break DoLoopStuff() | ||
| CExprChar | Character literal - 'H' '' '{0c00}' '{0u1f600}' | ||
| CExprClassDefinition | Represents a class definition in the AST. | ||
| CExprCodeBlock | Code block - {expr1; expr2}_ or do {expr1; expr2}_ Can have zero or more subexpressions |
||
| CExprComparison | Comparison operators. | ||
| CExprCompoundBase | Base for expressions that have an array of subexpressions Subclasses: CExprMakeArray, CExprMakeMap, CExprMakeTuple, CExprCodeBlock, CExprConcurrentBlockBase | ||
| CExprConcurrentBlockBase | Block based concurrency primitives - sync{}, rush{} or race{} Can have two or more async subexpressions - 0 or 1 is a warning or error. | ||
| CExprConcurrentIteratedBase | Iteration based concurrency primitives - sync(item:collection){}, rush(item:collection){} or race(item:collection){} | ||
| CExprDataDefinition | Represents a data definition in the AST. | ||
| CExprDefer | Defer macro - defer {Expr1; Expr2} Defers expressions until end of current scope. | ||
| CExprDefinition | Represents all definitions (and assignments) supported by Verse. | ||
| CExprEnumDefinition | Represents an enum definition in the AST. | ||
| CExprEnumerationType | Enum identifier @jira SOL-1013 : Shouldn't this inherit from CExprIdentifierClass? | ||
| CExprEnumLiteral | Enumerator - #GlobalEnum.enumeration, #.enumeration, MyType#Confirm.yes, #Confirm.yes, #.yes, MyType@set_size#size.medium, #size.medium, #.medium, #position.upper, #.upper | ||
| CExprError | Error expression - "~er~" produced when an expression couldn't be analyzed due to an error. | ||
| CExpressionBase | Abstract base class for AST expressions. | ||
| CExprExternal | Note - if these subclasses of CExpressionBase become more sophisticated they should probably be moved to their own files. | ||
| CExprFunctionDefinition | Represents a function definition in the AST. | ||
| CExprFunctionLiteral | Function literal - a=>b or function(a){b} | ||
| CExprGeneratorTypeFormer | |||
| CExprIdentifierBase | The base class of identifiers expressions. | ||
| CExprIdentifierBuiltInMacro | Represents a name of a a compiler built-in macro; e.g. option, array. | ||
| CExprIdentifierClass | Type identifier - MyType | ||
| CExprIdentifierData | Local or class identifier - temp, arg, captured | ||
| CExprIdentifierFunction | Access to instance function members | ||
| CExprIdentifierModule | Module identifier | ||
| CExprIdentifierModuleAlias | Module alias identifier | ||
| CExprIdentifierOverloadedFunction | An overloaded function identifier that hasn't been resolved to a specific overload. | ||
| CExprIdentifierTypeAlias | Access to a type alias | ||
| CExprIdentifierTypeVariable | Access to a type variable | ||
| CExprIdentifierUnresolved | An unresolved type identifier that is produced by desugaring, and consumed by analysis. | ||
| CExprIf | Conditional with failable tests- if (test[]) {clause1}, if (test[]) {clause1} else {else_clause} | ||
| CExprImport | Represents a import declaration in the AST. | ||
| CExprInterfaceDefinition | Represents a interface definition in the AST. | ||
| CExprInterfaceType | Interface identifier @jira SOL-1013 : Shouldn't this inherit from CExprIdentifierClass? | ||
| CExprInvocation | Routine call - expr1.call(expr2, expr3) | ||
| CExprInvokeType | Invoke a type as a function on a value - type(expr) or type[expr]. | ||
| CExprIteration | Note that CExprSyncIterated, CExprRushIterated and CExprRaceIterated are subclasses. | ||
| CExprIterationPairDefinition | Represents a map pair definition in the AST: (Key=>Value):Map | ||
| CExprLet | |||
| CExprLocal | Represents the `(local:) qualifier_. | ||
| CExprLogic | Logic literal - true/false | ||
| CExprLogicalNot | Logical not operator | ||
| CExprLoop | Loop flow/concurrency primitive/macro - loop {Expr1; Expr2} Loops one or more expressions. | ||
| CExprMacroCall | A macro call of the form m1{}, m2(){}, or more generally m(){}keyword_1{}keyword_2{}...keyword_N{} | ||
| CExprMakeArray | Create an array value Can have zero or more subexpressions | ||
| CExprMakeMap | Create a map value Can have zero or more subexpressions | ||
| CExprMakeNamed | Represents a named value / default value placeholder in the AST. | ||
| CExprMakeOption | Box an option value | ||
| CExprMakeRange | Create a range value | ||
| CExprMakeTuple | Create a tuple value | ||
| CExprMapTypeFormer | |||
| CExprModuleDefinition | Represents a module definition in the AST. | ||
| CExprNewPointer | Create a new pointer from an initial value. | ||
| CExprNumber | Integer literal - 42, 0, -123, 123_456_789, 0x12fe, 0b101010 | ||
| CExprOptionTypeFormer | |||
| CExprPath | Path literal - /unrealengine.com/UnrealEngine | ||
| CExprPathPlusSymbol | Expression that evaluates to the path of the current scope, plus a given symbol, semantic analysis replaces this node with a CExprString | ||
| CExprPlaceholder | Placeholder expression - "~ph~" produced by placeholder nodes in the Vst. | ||
| CExprPointerToReference | Read the value of a variable. | ||
| CExprProfileBlock | Represents a profile block macro invocation in the AST. | ||
| CExprQueryValue | Query the value of a boolean or option value. | ||
| CExprRace | Race concurrency primitive - race {coro1() _coro2()} 2+ Async expressions run concurrently and next expression executed when _fastest/first expression completed and all other expressions are aborted. | ||
| CExprRaceIterated | Iterated Race (collection form) concurrency primitive - race(item:collection) {_coro1() _coro2()} | ||
| CExprReferenceToValue | Evaluates the value of an expression yielding a reference type. | ||
| CExprReturn | Return statement - return expr | ||
| CExprRush | Rush concurrency primitive - rush {coro1() _coro2()} 2+ Async expressions run concurrently and next expression executed when _fastest/first expression completed and all other expressions continue independently until each is fully completed. | ||
| CExprRushIterated | Iterated Rush (collection form) concurrency primitive - rush(item:collection) {_coro1() _coro2()} | ||
| CExprScopedAccessLevelDefinition | Represents both named and anonymous scoped access level definitions in the AST. | ||
| CExprSelf | Access to the instance the current function is being invoked on. | ||
| CExprSet | Evaluate operand to an l-expression. | ||
| CExprShortCircuitAnd | Short-circuit evaluation of a Boolean and | ||
| CExprShortCircuitOr | Short-circuit evaluation of a Boolean or | ||
| CExprSnippet | Represents a snippet in the AST. | ||
| CExprSpawn | Spawn concurrency primitive - spawn {Coro()} [future: spawn {Expr1; Expr2}] Async expression treated as a closure/lambda with next expression executed immediately while the started async expression continues independently. | ||
| CExprString | String literal - "Hello, world!", "Line 1\nLine2" | ||
| CExprSubBlockBase | Expressions with a sub-block - branch, spawn, loop, defer | ||
| CExprSubtype | |||
| CExprSync | Sync concurrency primitive - sync {coro1() _coro2()} 2+ Async expressions run concurrently and next expression executed when _all expressions completed. | ||
| CExprSyncIterated | Iterated Sync (collection form) concurrency primitive - sync(item:collection) {_coro1() _coro2()} | ||
| CExprTupleElement | Tuple element access `TupleExpr(Idx)_ | ||
| CExprTupleType | Get or create a tuple tuple based on `tuple(type1, type2, ...)_ | ||
| CExprType | Type expression - type{ |
||
| CExprTypeAliasDefinition | Represents a type alias definition in the AST. | ||
| CExprTypeFormer | Base class for all expressions that form a type out of input type(s) | ||
| CExprUnaryArithmetic | |||
| CExprUnaryOp | Base class of unary operators. | ||
| CExprUnaryTypeFormer | |||
| CExprUsing | Represents a using declaration in the AST. | ||
| CExprVar | |||
| CExprWhere | |||
| CFloatType | The float type is a special form of CFloatType where _MaxInclusive is NaN. | ||
| CFlowType | |||
| CFunction | Function scope, signature and body. | ||
| CFunctionType | |||
| CGeneratorType | A parametric type of generators with a specific element type: generator(t) where t:type | ||
| CGlobalType | Global type: used for various kinds of types of which there are one per program: false, unit, void, any. | ||
| CInstantiatedClass | |||
| CInstantiatedInterface | |||
| CInstantiatedType | Type representing an instantiation of some underlying type. | ||
| CInterface | A interface: a named set of function signatures that can be implemented for other types. | ||
| CIntrinsicSymbols | Container structure for the various pre-defined, intrinsic symbols. | ||
| CIntType | |||
| CInvariantValueType | |||
| CIrArrayAdd | Add an item to an array The array itself is not included in the node, instead the result destination in the code generator is used. | ||
| CIrArrayUnsafeCall | |||
| CIrConvertFromDynamic | Converts a value to a dynamically typed value. Only present in the IR, not the AST. | ||
| CIrConvertToDynamic | Converts a value to a dynamically typed value. Only present in the IR, not the AST. | ||
| CIrFor | Bounded iteration | ||
| CIrForBody | Wraps the innermost body of CIrFor It wraps the code not inside the failure context of CIrFor. | ||
| CIrMapAdd | |||
| CLogicalScope | A scope that can contain definitions | ||
| CMapType | A parametric type of maps with specific key and value types: [t]u where t&u:type | ||
| CMemberDefinitions | Represents members of a class/interface/module/snippet definition node | ||
| CModule | Semantically represents a module | ||
| CModuleAlias | An imported module: Alias := import(...) | ||
| CModulePart | Semantically represents a partial module aka a module definition either via vmodule file or module macro Always is directly parented to a CModule | ||
| CNamedType | |||
| CNominalType | Class defining instance and class objects. | ||
| CNormalType | A normal type: a head normal form of types where the head is not a parametric type instantiation. | ||
| COptionType | Option type | ||
| CPointerType | Represents a pointer to mutable inner type. | ||
| CReferenceType | Represents a reference to (possibly mutable) inner type. | ||
| CScope | A nested scope - program, module or class | ||
| CScopedAccessLevelDefinition | AccessLevelDefinition type HACK! This is convoluted, but attributes need to be CClass types because the semantic attribute processing demands it right now HACK! CClass expects its associated definition to be a CClassDefinition type, so our CScopedAccessLevelDefinition also needs to be a CClassDefinition type HACK! Ordinarily, we could just use CClassDefinition directly without this extra child type, except the CClassDefinition linkage to the AST demands HACK! that the CExpr* type be CExprClassDefinition even though it ultimately relaxes to CExpressionBase. | ||
| CSemanticProgram | Stores whole parsed semantic hierarchy/infrastructure | ||
| CSnippet | Semantically represents a snippet | ||
| CTupleType | |||
| CTypeAlias | Maps a name to a type | ||
| CTypeBase | Base class for all types. | ||
| CTypeScope | The implicit scope of a type. | ||
| CTypeType | |||
| CTypeVariable | |||
| CUnknownType | An unknown type - can optionally contain a list of possibly valid types | ||
| CValueType | Abstract type that has an additional sub-type representing a value (ex: List) | ||
| SAccessibilityScope | |||
| SAccessLevel | Mostly a wrapper around SAccessLevel::EKind with the addition of an optional list of modules for the 'scoped' access level. | ||
| SAstNodeTypeInfo | |||
| SAstVisitor | Abstract base for applying some operation / iterating through AST structures. | ||
| SAttribute | |||
| SClassVarAccessorFunctions | |||
| SDecompositionMapping | |||
| SDigestScope | |||
| SEffectDescriptor | |||
| SEffectInfo | |||
| SEffectSet | |||
| SEffectSetBase | |||
| SInstantiatedTypeVariable | |||
| SQualifier | Information about a given qualifier. | ||
| SResolvedDefinition | Stores a resolved definition and the context that it was resolved from | ||
| SSignature | Type signature / parameter interface for routines/invokables | ||
| STypeVariableSubstitution | |||
| TAsNullableTraitsOf | |||
| TAstFunctionVisitor | CAstNode Implementations. | ||
| TAstNodeRef | Reference to a pair of AST and IR nodes | ||
| TFilteredDefinitionRange | Filters a range of definitions to only include definitions of the kind corresponding to FilterClass. |
Constants
| Name | Description |
|---|---|
| uLang::DefaultVarAccessLevelKind |
Typedefs
| Name | Description |
|---|---|
| CAnyType | |
| CAstNodeRef | |
| CChar32Type | |
| CChar8Type | |
| CComparableType | |
| CFalseType | |
| CLogicType | |
| CPathType | |
| CPersistableType | |
| CRangeType | |
| CRationalType | |
| CTrueType | |
| CVoidType | |
| SemanticRevision | For storing revisions of functions, classes etc. |
| SmallDefinitionArray | |
| SResolvedDefinitionArray | An array of resolved definitions and their associated contexts |
| VisitStampType | Used to mark scopes already visited during a search. |
Enums
| Type | Name | Description | |
|---|---|---|---|
| uLang::EAstNodeType | This is used to differentiate between different types of AST nodes when it is only known that an instance is of type CAstNode, but not the specific subclass. | ||
| uLang::EComparability | Characterizes whether a type is comparable and hashable, just comparable, or incomparable. | ||
| uLang::EEffect | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::EExtensionFieldAccessorKind | No longer used, but good ideas enum class EFunctionStringFlag : uint16t { / Name part - omitted or one of: Name = 1<<0, // Prepend name of function Qualified = 1<<1, // Prepends the scope `(/MyModule:) and then the name of the function/ Type signature part - omitted or one of: SigSimple = 1<<2, // Include just parentheses () SigTyped = 1<<3, // Include parentheses (), any parameter names and types and result type (param1 : Type1, param2 : Type2) : ResultType SigDefaults = 1<<4, // Include parentheses (), any parameter names, types and defaults and result type (param1 : Type1, param2 : Type2 = default2 ) : ResultType/ Body - omitted or one of: BodyIndicator = 1<<5, // {...} for uLang body and empty for atomic C++ body Body = 1<<6, // full uLang body or empty for atomic C++ body/ Spacing - omitted (canonical with multi-line) or: Inline = 1<<7, // try to have everything on one line/ Masks Default_ = Qualified|SigDefaults|Body, // MyClass@function(param1 : Type1, param2 : Type2 = default2 ) : ResultType { } DefaultUnnamed_ = SigDefaults|Body, // (param1 : Type1, param2 : Type2 = default2 ) : ResultType { } DefaultIdent_ = Qualified|SigSimple, // MyClass@function()Named_ = Name|Qualified, Signature_ = SigSimple|SigTyped|SigDefaults, Body_ = BodyIndicator|Body, Unimplemented_ = SigTyped|SigDefaults|Body }; Distinguishes extension field accessor functions from other functions. | ||
| uLang::EFunctionStringFlag | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::EInvokeTime | Indicates whether an expression should return immediately - such as functions, after a duration (including immediately) such as coroutines or either. | ||
| uLang::EMacroClauseTag | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::EMemberOrigin | Specifies whether to find only member definitions originating in the current type, or inherited, or either. | ||
| uLang::EStructOrClass | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::ETypeKind | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::ETypePolarity | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::ETypeSyntaxPrecedence | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::EVstMappingType | Copyright Epic Games, Inc. All Rights Reserved. | ||
| uLang::SemanticTypeUtils::EIsEditable | Returns whether a type can be used with @editable. |
Functions
| Type | Name | Description | |
|---|---|---|---|
| Traits::TResult | uLang::AsNullable
(
TIn Expr |
||
| TIterator | uLang::FindAttributeHack
(
TIterator First, |
||
| ETypePolarity | uLang::FlipPolarity
(
ETypePolarity Polarity |
||
| bool | uLang::HasAllTags
(
EMacroClauseTag A, |
||
| bool | |||
| const char * | uLang::InvokeTimeAsCString
(
EInvokeTime InvokeTime |
||
| const char * | |||
| const char * | |||
| EMacroClauseTag | |||
| SEffectSet | uLang::operator|
(
const EEffect Lhs, |
||
| bool | uLang::SemanticTypeUtils::AreDomainsDistinct
(
const CTypeBase* DomainType1, |
Determine whether there two types are distinct; i.e. that there are no values that are members of both types. | |
| const CTypeBase & | uLang::SemanticTypeUtils::AsNegative
(
const CTypeBase&, |
||
| const CTypeBase & | uLang::SemanticTypeUtils::AsPolarity
(
const CTypeBase&, |
||
| const CTypeBase & | uLang::SemanticTypeUtils::AsPositive
(
const CTypeBase&, |
||
| const CClass * | uLang::SemanticTypeUtils::AsSingleClass
(
const CNormalType& NegativeType, |
||
| const CInterface * | uLang::SemanticTypeUtils::AsSingleInterface
(
const CNormalType& NegativeType, |
||
| const CTupleType & | uLang::SemanticTypeUtils::Canonicalize
(
const CTupleType& |
||
| const CFunctionType & | |||
| const CTypeBase & | uLang::SemanticTypeUtils::Canonicalize
(
const CTypeBase& |
Replace all types with equivalent representations with a single canonical type - the type used when emitting code. | |
| bool | uLang::SemanticTypeUtils::Constrain
(
const CTypeBase* PositiveType1, |
Constrain PositiveType1_ to be a subtype of NegativeType2_ |
|
| void | uLang::SemanticTypeUtils::ForEachDataType
(
const CTypeBase*, |
Apply a function to each immediately possibly contained value's type. | |
| void | uLang::SemanticTypeUtils::ForEachDataTypeRecursive
(
const CTypeBase*, |
`ForEachDataType_, but recursive, and depth-first, top-down, including the immediately passed type. | |
| const CFunctionType * | |||
| TArray< STypeVariableSubstitution > | uLang::SemanticTypeUtils::Instantiate
(
const TArray< const CTypeVariable* >& TypeVariables |
||
| bool | uLang::SemanticTypeUtils::IsAttributeType
(
const CTypeBase* Type |
||
| const char * | uLang::SemanticTypeUtils::IsEditableToCMessage
(
EIsEditable IsEditable |
||
| EIsEditable | uLang::SemanticTypeUtils::IsEditableType
(
const uLang::CTypeBase* Type, |
||
| bool | uLang::SemanticTypeUtils::IsEquivalent
(
const CTypeBase* PositiveType1, |
Determine if PositiveType1_ is equivalent to PositiveType2_ |
|
| bool | uLang::SemanticTypeUtils::IsStringType
(
const CNormalType& NormalType |
Returns whether the type is string, i.e. []char8. | |
| bool | uLang::SemanticTypeUtils::IsSubtype
(
const CTypeBase* PositiveType1, |
Determine if PositiveType1_ is a subtype of PositiveType2_ |
|
| bool | uLang::SemanticTypeUtils::IsUnknownType
(
const CTypeBase* Type |
||
| const CTypeBase * | uLang::SemanticTypeUtils::Join
(
const CTypeBase* Type1, |
Compute the join of Type1 and Type2: the "least" type that contains all values contained by either Type1 or Type2. | |
| bool | uLang::SemanticTypeUtils::Matches
(
const CTypeBase* PositiveType1, |
Determine if argument PositiveType1_ is a match for parameter NegativeType2_ |
|
| const CTypeBase * | uLang::SemanticTypeUtils::Meet
(
const CTypeBase* Type1, |
Compute the meet of Type1 and Type2: the "greatest" type that contains only values contained by both Type1 and Type2. | |
| const CTypeBase & | |||
| const CTypeBase & | |||
| const CTypeBase & | |||
| const CTypeBase * | uLang::SemanticTypeUtils::Substitute
(
const CTypeBase&, |
||
| void | uLang::SemanticTypeUtils::VisitAllDefinitions
(
const CTypeBase* Type, |
Variables
| Type | Name | Description | |
|---|---|---|---|
| SEffectSet | Allocates | ||
| SEffectSet | ClassDefault | Contextual defaults. | |
| SEffectSet | Computes | ||
| SEffectSet | Converges | Singular effects. | |
| SEffectSet | Decides | ||
| SEffectSet | FunctionDefault | ||
| SEffectSet | ModuleDefault | ||
| SEffectSet | NoRollback | ||
| SEffectSet | Reads | ||
| SEffectSet | Suspends | ||
| SEffectSet | Transacts | Aggregate effects. | |
| SEffectSet | VariesDeprecated | ||
| SEffectSet | Writes |