Skip to content

Recommend calling super in initialize #809

@headius

Description

@headius

Many users forget to call super from initialize, which can lead to tricky bugs if the superclass needs to initialize its own state.

Perhaps this should be in the style guide?

I'm not sure if it should be a hard failure, since classes that extend Object or BasicObject or a few other core types don't technically need to invoke super, but the safest pattern would be to always do so.

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