Initializerswift 6.0.1Swift

    init

    Creates a new, empty array.

    init()

    This is equivalent to initializing with an empty array literal. For example:

    var emptyArray = Array<Int>()
    print(emptyArray.isEmpty)
    // Prints "true"
    
    emptyArray = []
    print(emptyArray.isEmpty)
    // Prints "true"

    Other members in extension

    Typealiases

    Type members

    Instance members