Skip to content

Static get/set accessors#424

Merged
tomblind merged 5 commits intomasterfrom
static-getters-setters
Feb 20, 2019
Merged

Static get/set accessors#424
tomblind merged 5 commits intomasterfrom
static-getters-setters

Conversation

@tomblind
Copy link
Copy Markdown
Collaborator

These actually broke with the class+prototype update. This adds support back for them in a similar way to standard get/set accessors. To make that work, class tables need to be given their own metatable to correctly forward things (but classes without static getters/setters are not affected).

There's a also a bit of cleanup in here:

  • ____getters and ____setters tables are no longer added to derived classes that don't have their own accessors
  • all tests have been modified to reference self in their getters/setters to ensure problems with self not propagating don't occur again

@tomblind tomblind merged commit 2d6a138 into master Feb 20, 2019
@tomblind tomblind deleted the static-getters-setters branch February 20, 2019 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants