From 092472dab755645333186e1398f6b261ec6fa112 Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Thu, 18 Nov 1999 10:05:45 +0000 Subject: zsh-workers/8665 --- Completion/Core/compinit | 29 ----------------------------- 1 file changed, 29 deletions(-) (limited to 'Completion/Core/compinit') diff --git a/Completion/Core/compinit b/Completion/Core/compinit index c2a78e99a..2f69f26c9 100644 --- a/Completion/Core/compinit +++ b/Completion/Core/compinit @@ -497,35 +497,6 @@ compstyle ':correct' accept '2n' compstyle ':correct' prompt 'correct to:' compstyle '*' completer '_complete' -# Utility function to call a function if it exists. -# -# Usage: funcall [ ... ] -# -# If a function named is defined (or defined to be autoloaded), -# it is called. If is given not the string `-' or empty, it is -# taken as the name of a parameter and the return status of the function -# called is stored in this parameter. All other arguments are given -# to the function called. -# The return value of this function is zero if the function was -# called and non-zero otherwise. - -funcall() { - local _name _ret - - [[ "$1" != (|-) ]] && _name="$1" - - shift - - if (( $+functions[$1] )); then - "$@" - _ret="$?" - [[ -n "$_name" ]] && eval "${_name}=${_ret}" - compstate[restore]='' - return 0 - fi - return 1 -} - # Now we automatically make the definition files autoloaded. typeset -U _i_files -- cgit 1.4.1