mirror of
https://gitea.com/SweetSea-ButImNotSweet/tromi_mobile.git
synced 2025-01-08 17:33:09 +08:00
Trimming some unnecessary empty lines in classic library
This commit is contained in:
@@ -11,11 +11,9 @@
|
|||||||
local Object = {}
|
local Object = {}
|
||||||
Object.__index = Object
|
Object.__index = Object
|
||||||
|
|
||||||
|
|
||||||
function Object:new()
|
function Object:new()
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
function Object:extend()
|
function Object:extend()
|
||||||
local cls = {}
|
local cls = {}
|
||||||
for k, v in pairs(self) do
|
for k, v in pairs(self) do
|
||||||
@@ -29,7 +27,6 @@ function Object:extend()
|
|||||||
return cls
|
return cls
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
function Object:implement(...)
|
function Object:implement(...)
|
||||||
for _, cls in pairs({...}) do
|
for _, cls in pairs({...}) do
|
||||||
for k, v in pairs(cls) do
|
for k, v in pairs(cls) do
|
||||||
@@ -40,7 +37,6 @@ function Object:implement(...)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
function Object:is(T)
|
function Object:is(T)
|
||||||
local mt = getmetatable(self)
|
local mt = getmetatable(self)
|
||||||
while mt do
|
while mt do
|
||||||
@@ -52,17 +48,14 @@ function Object:is(T)
|
|||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
function Object:__tostring()
|
function Object:__tostring()
|
||||||
return "Object"
|
return "Object"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
function Object:__call(...)
|
function Object:__call(...)
|
||||||
local obj = setmetatable({}, self)
|
local obj = setmetatable({}, self)
|
||||||
obj:new(...)
|
obj:new(...)
|
||||||
return obj
|
return obj
|
||||||
end
|
end
|
||||||
|
|
||||||
|
return Object
|
||||||
return Object
|
|
||||||
Reference in New Issue
Block a user