From 7ef2e4dfd44dff81f66f5dc9465e4366f953f0b3 Mon Sep 17 00:00:00 2001 From: Daniel Kolesa Date: Fri, 3 Mar 2017 16:36:47 +0100 Subject: [PATCH] docgen: do not generate foreign classes' functions and events Only generate the classes' own funcs/events (and overridden). Let other classes generate their own stuff. This prevents some files from being generated multiple times, which more than halves generation time. --- src/scripts/elua/apps/gendoc.lua | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/scripts/elua/apps/gendoc.lua b/src/scripts/elua/apps/gendoc.lua index ebc6a04287..c1d3e568d8 100644 --- a/src/scripts/elua/apps/gendoc.lua +++ b/src/scripts/elua/apps/gendoc.lua @@ -769,10 +769,12 @@ local build_functable = function(f, title, tcl, tbl, newm) wt[#wt + 1] = lbuf:finish() nt[#nt + 1] = wt - if impl:is_prop_get() or impl:is_prop_set() then - build_property(impl, cl) - else - build_method(impl, cl) + if cl == tcl then + if impl:is_prop_get() or impl:is_prop_set() then + build_property(impl, cl) + else + build_method(impl, cl) + end end end local get_best_scope = function(f) @@ -917,7 +919,9 @@ local build_evtable = function(f, title, tcl, tbl, newm) wt[#wt + 1] = lbuf:finish() nt[#nt + 1] = wt - build_event(ev, cl) + if cl == tcl then + build_event(ev, cl) + end end table.sort(nt, function(v1, v2) return v1[1] < v2[1] end) for i, item in ipairs(nt) do