Documentation Language: Swift

Function

concat(_:_:)

Concatenates two strings.

func concat(_ left: any EcoreValue, _ right: any EcoreValue) throws -> EString

Parameters

left

The first string

right

The second string

Return Value

The concatenated string

Discussion

The concat operation returns a new string that is the result of appending the second string to the first string.

Examples

let hello = "Hello" as EString
let world = " World" as EString
let greeting = try concat(hello, world)  // Result: "Hello World"