From f26d1ba6b01a358c83f28219c7a01e546e84d2ee Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Wed, 11 Jan 2017 11:26:13 +0000 Subject: Add features associated with autoloading a function using an absolute path. -d defaults to normal fpath -r remembers the path without actually loading. May be combined with -d. -R does the same but it's an error if not found -X can now take a directory path: this is used to output not yet loaded functions that have an associated path. --- Src/hashtable.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Src/hashtable.c') diff --git a/Src/hashtable.c b/Src/hashtable.c index 7c3367568..2a8b58535 100644 --- a/Src/hashtable.c +++ b/Src/hashtable.c @@ -949,16 +949,20 @@ printshfuncnode(HashNode hn, int printflags) zoutputtab(stdout); } if (!t) { - char *fopt = "UtTkz"; + char *fopt = "UtTkzc"; int flgs[] = { PM_UNALIASED, PM_TAGGED, PM_TAGGED_LOCAL, - PM_KSHSTORED, PM_ZSHSTORED, 0 + PM_KSHSTORED, PM_ZSHSTORED, PM_CUR_FPATH, 0 }; int fl;; zputs("builtin autoload -X", stdout); for (fl=0;fopt[fl];fl++) if (f->node.flags & flgs[fl]) putchar(fopt[fl]); + if (f->filename) { + putchar(' '); + zputs(f->filename, stdout); + } } else { zputs(t, stdout); zsfree(t); -- cgit 1.4.1