Skip to content

Missing setter convention described in RFC344 #279

@duskmoon314

Description

@duskmoon314

In RFC344, setter is described as:

* A method `set_foo(&self, val: T)` for setting the field. (The `val` argument
  here may take `&T` or some other type, depending on the context.)

This was once added in commit a29a841

However, the current guideline only describes C-GETTER and does not describe how the setter should be named. Given that there are many results when searching for set_ in the std, I assume this is still the naming convention of the setter. search results

Should we add a description, or is this not suggested, and some API should be adjusted?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions