Method code for $root._get_method_info()

[Turn on line numbering]
arg anc, method;
var code, lines, dis_flag, meth_args, flags, first_comment;

code = anc.list_method(method);
lines = code.length();
if (lines > 5)
    code = code.subrange(1, 5);
flags = anc.method_flags(method);
if (code) {
    meth_args = regexp(code[1], "arg ([^;]);");
    if (meth_args) {
        meth_args = meth_args[1];
        code = code.delete(1);
    } else {
        meth_args = "";
    }
    if (code && (!code[1] || code[1][1] == "v"))
        code = code.delete(1);
    if (code && (!code[1] || code[1][1] == "v"))
        code = code.delete(1);
    first_comment = code ? code[1] + " " : " ";
    first_comment = first_comment[1] == "/" || first_comment[1] == "r" ? first_comment : "";
} else {
    meth_args = "";
    first_comment = "";
}
return [anc, method, meth_args, flags, lines, first_comment];

["// Created as a part of ColdCore, see: @help Credit"]

the Cold Dark