Skip to content

Fill in array with same values #2462

@endragor

Description

@endragor

Sometimes you need to fill in the whole array with values different from type defaults. For example, you may have a bool array, and you'd like make it have all true values, instead of all false.
Seems like there is no built-in procedure to do that.

As a workaround, it's possible to use mapIt from sequtils, but it doesn't look straightforward.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions