Skip to content

Convert constructors to new conventions #3853

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
brson opened this issue Oct 24, 2012 · 9 comments
Closed

Convert constructors to new conventions #3853

brson opened this issue Oct 24, 2012 · 9 comments
Labels
C-cleanup Category: PRs that clean code up or issues documenting cleanup.

Comments

@brson
Copy link
Contributor

brson commented Oct 24, 2012

The new convention is as so:

struct Kitty {
}

impl Kitty {
    static fn new() -> Kitty { ... }
    static fn new_with_claws(claws: &[Claw]) -> Kitty { ... }
}

Still requires a snapshot before this can happen.

@bstrie
Copy link
Contributor

bstrie commented Oct 25, 2012

Let me know when the snapshot happens and I can start helping out with this. Death to capitalized functions!

@sanxiyn
Copy link
Member

sanxiyn commented Feb 14, 2013

Snapshot happened, right?

@bstrie
Copy link
Contributor

bstrie commented Feb 14, 2013

It appears so, but nobody ever reminded me!

@brson
Copy link
Contributor Author

brson commented Mar 9, 2013

There are still some offenders. SharedChan is the one i notice all the time.

@catamorphism
Copy link
Contributor

Still needs to be done. Maybe a lint pass for capitalized function names would help identify places that need to change.

@catamorphism
Copy link
Contributor

Visiting for triage.

@catamorphism
Copy link
Contributor

Revisiting for triage. I'm not sure if this is complete, but implementing that lint pass I suggested would still be cool.

@catamorphism
Copy link
Contributor

Not high priority, but Path still needs to be fixed

@catamorphism
Copy link
Contributor

Actually, closing, and people should file bugs on the specific remaining ones.

RalfJung pushed a commit to RalfJung/rust that referenced this issue Aug 30, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
C-cleanup Category: PRs that clean code up or issues documenting cleanup.
Projects
None yet
Development

No branches or pull requests

4 participants