SplitScript reference / Set / new

Set.new

Function

Set.new<U>() -> Set<U> where U: Equatable

Creates an empty set.

The returned value retains its contents until explicitly mutated or the script instance is unloaded.

Effects: allocates

Runtime behavior: available everywhere; synchronous

Examples

Create a room set

let visited = Set.new<String>()