gsl-shell.git - gsl-shell

index : gsl-shell.git
gsl-shell
summary refs log tree commit diff
path: root/help.lua
diff options
context:
space:
mode:
authorFrancesco Abbate <francesco.bbt@gmail.com>2012年11月17日 23:48:45 +0100
committerFrancesco Abbate <francesco.bbt@gmail.com>2012年11月17日 23:48:45 +0100
commit054f7b34fe1e2a376ed35a45c78ed0d5d4393b66 (patch)
tree3ea000e3b86329961aed6a875836309f4dc4aca1 /help.lua
parentb98c33f92a95b37070ecedc5c370da94bda555c3 (diff)
downloadgsl-shell-054f7b34fe1e2a376ed35a45c78ed0d5d4393b66.tar.gz
Add support for help on objects
Diffstat (limited to 'help.lua')
-rw-r--r--help.lua 6
1 files changed, 5 insertions, 1 deletions
diff --git a/help.lua b/help.lua
index 3e03d17d..9346ccab 100644
--- a/help.lua
+++ b/help.lua
@@ -14,11 +14,15 @@ end
local function search_help(func)
for k, modname in ipairs(help_files) do
+ local mt = getmetatable(func)
local module = open_module(modname)
if module[func] then
local help_text = module[func]
return help_text
- end
+ elseif mt and module[mt] then
+ local help_text = module[mt]
+ return help_text
+ end
end
end
generated by cgit v1.2.3 (git 2.25.1) at 2025年09月17日 22:37:05 +0000

AltStyle によって変換されたページ (->オリジナル) /