Skip to content
This repository was archived by the owner on Nov 23, 2020. It is now read-only.
This repository was archived by the owner on Nov 23, 2020. It is now read-only.

Array Concatenation #18

@CodaFi

Description

@CodaFi

For the concat example, it would be trivial to create a loop and just copy the values onto the end of the first array, but there are some opportunities for a concat operator to be built into the language:

  1. ..= The dedicated concat operator for strings could be overloaded to work with arrays, as in:
var array1 = array(1, 2, 3);
array1 ..= array(1, 2, 3,);
  1. A concat() function built into the STL as in:
var array = concat(array1, array2);
  1. += could be overloaded as in:
var array1 = array(1, 2, 3);
array1 += array(1, 2, 3,);

All of which would need to be mirrored in the implementation with some kind of spn_array_concat(..);.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions