summaryrefslogtreecommitdiff
path: root/Src/exec.c
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2007-05-29 14:16:02 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2007-05-29 14:16:02 +0000
commit29b7123647bc3b70911bbb2caf85238d22d160c8 (patch)
tree7385597437e723b4471a6bd1061a5a2fdd2b7017 /Src/exec.c
parent3fbbdf245b7367c4b34492b630450c004a43eed7 (diff)
downloadzsh-29b7123647bc3b70911bbb2caf85238d22d160c8.tar.gz
zsh-29b7123647bc3b70911bbb2caf85238d22d160c8.zip
23485: feature completion and autoloading
Diffstat (limited to 'Src/exec.c')
-rw-r--r--Src/exec.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/Src/exec.c b/Src/exec.c
index 751282127..ccba66bf8 100644
--- a/Src/exec.c
+++ b/Src/exec.c
@@ -2012,7 +2012,12 @@ execcmd(Estate state, int input, int output, int how, int last1)
/* autoload the builtin if necessary */
if (!((Builtin) hn)->handlerfunc) {
- (void)load_module(((Builtin) hn)->optstr, NULL);
+ /*
+ * Ensure the module is loaded and the
+ * feature corresponding to the builtin
+ * is enabled.
+ */
+ (void)ensurefeature(((Builtin) hn)->optstr, "b:", hn->nam);
hn = builtintab->getnode(builtintab, cmdarg);
}
assign = (hn && (hn->flags & BINF_MAGICEQUALS));
@@ -2229,7 +2234,7 @@ execcmd(Estate state, int input, int output, int how, int last1)
/* autoload the builtin if necessary */
if (!((Builtin) hn)->handlerfunc) {
- (void)load_module(((Builtin) hn)->optstr, NULL);
+ (void)ensurefeature(((Builtin) hn)->optstr, "b:", cmdarg);
hn = builtintab->getnode(builtintab, cmdarg);
}
break;