[Turn on line numbering]arg gen, def, fltr, match; var ancs, a, m, i, methods; if (!.has_flag('methods, sender())) throw(~perm, sender() + " cannot view methods on " + this()); if (def) ancs = [def]; else ancs = .(gen[1])(gen[2]) || [this()]; methods = #[]; for a in (ancs) { for m in (a.methods()) { if (tostr(m).(match)(fltr) != 0) { i = a.method_info(m); methods = methods.add_elem(i[5], [a, m, @i]); } } } return methods;
// Created as a part of ColdCore, see: @help Credit