Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Remove `__meta` field from class inheritance. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | import-luaoop |
| Files: | files | file ages | folders |
| SHA3-256: |
00e1805024b45c5c495d84cbc8e98001 |
| User & Date: | imagic 2024-10-05 22:19:07.746 |
Context
|
2024-10-06
| ||
| 15:00 | Import Luaoop as `xtype.class`. ... (check-in: 9efe067d01 user: imagic tags: trunk) | |
|
2024-10-05
| ||
| 22:19 | Remove `__meta` field from class inheritance. ... (Closed-Leaf check-in: 00e1805024 user: imagic tags: import-luaoop) | |
| 22:15 | Import and adapt the Luaoop documentation. ... (check-in: 71502bba7f user: imagic tags: import-luaoop) | |
Changes
Changes to src/xtype/class.lua.
| ︙ | ︙ | |||
31 32 33 34 35 36 37 |
local function class_build_inheritance(classdef)
local build = {}
for i=#classdef.xtype_stack,1,-1 do -- least specific, descending order
local base = classdef.xtype_stack[i]
if xtype.is(base, class) then
-- inherit base class fields
for k,v in pairs(base) do
| | | 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
local function class_build_inheritance(classdef)
local build = {}
for i=#classdef.xtype_stack,1,-1 do -- least specific, descending order
local base = classdef.xtype_stack[i]
if xtype.is(base, class) then
-- inherit base class fields
for k,v in pairs(base) do
if k ~= "__meta" and not k:find("^xtype_") then build[k] = v end
end
end
end
return build
end
-- Build/re-build the class (class and instance inheritance).
|
| ︙ | ︙ |