Skip to content

Rename string::push_str to string::concat #20857

Closed
@sandeep-datta

Description

@sandeep-datta

Please consider renaming string::push_str() to string::concat(). Push_X() in the context of a collection means X will be added to the container as a single entity. Hence push_str() is meaningless for strings since a string can only contain characters (char != [char]).

If it is too late to rename then consider adding a method called concat() anyway.

Also consider renaming Vec::push_all() to Vec::concat() so that the name is consistent with String::concat().

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions