diff options
author | Aki <nthirtyone@gmail.com> | 2017-07-26 03:10:41 +0200 |
---|---|---|
committer | Aki <nthirtyone@gmail.com> | 2017-07-26 03:10:41 +0200 |
commit | 0866dec8387a5ce6d5a547338147beda932114dc (patch) | |
tree | 02ff6ba2f3d4179230fee679cd8238ac1cc14fd7 /test.lua | |
parent | eacf0f60c0752616407fbca6cd9d8ca9757ce624 (diff) | |
download | object-0866dec8387a5ce6d5a547338147beda932114dc.zip object-0866dec8387a5ce6d5a547338147beda932114dc.tar.gz object-0866dec8387a5ce6d5a547338147beda932114dc.tar.bz2 |
Usage of self.__super is discouraged
Diffstat (limited to 'test.lua')
-rw-r--r-- | test.lua | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -21,7 +21,7 @@ function Child:new (a) self.a = a end function GrandChild:new (b, a) - self.__super.new(self, a) + GrandChild.__super.new(self, a) self.b = b end @@ -75,7 +75,7 @@ function Meta:new (x, y) self.y = y end function Meta.__add (self, op) - return self.__class(self.x + op.x, self.y + op.y) + return Meta(self.x + op.x, self.y + op.y) end local x = 5 |