Skip to content

ifaces in std and core duplicate code and docs #2143

Closed
@jamorton

Description

@jamorton

In many of the core and std libraries, the iface usage is flaky and ends up duplicating a lot of code.
Many ifaces only implement some small arbitrary subset of the full set of functions, for example in str and vec. It makes code look awkward when you have something like str::replace(foo, "x", "y").split_char('z').

Additionally, all of the docs are duplicated for the iface functions and most of them are just inlines of calling something on self.

Can all of the code be moved to just use iface impls instead of regular functions? Or something else?

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-cleanupCategory: PRs that clean code up or issues documenting cleanup.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions