Skip to content

Unused code "c.__instances" #42

@Krunklehorn

Description

@Krunklehorn

Every class is created with a weak table __instances (two underscores) that goes completely unused. Is this code dead? Perhaps it has been included for support with other libraries?

On a related note, shouldn't classes keep weak references to their own instances? It seems like the idea was there, and it could certainly make retrieving lists of a class's instances faster than having to constantly filter them out from the global record through the instances() function.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions