#define ASS_NOEXPAND 0x0080 /* don't expand associative array subscripts */
#define ASS_NOEVAL 0x0100 /* don't evaluate value as expression */
#define ASS_NOLONGJMP 0x0200 /* don't longjmp on fatal assignment error */
#define ASS_NOEXPAND 0x0080 /* don't expand associative array subscripts */
#define ASS_NOEVAL 0x0100 /* don't evaluate value as expression */
#define ASS_NOLONGJMP 0x0200 /* don't longjmp on fatal assignment error */
/* Flags for the string extraction functions. */
#define SX_NOALLOC 0x0001 /* just skip; don't return substring */
/* Flags for the string extraction functions. */
#define SX_NOALLOC 0x0001 /* just skip; don't return substring */
/* Remove backslashes which are quoting backquotes from STRING. Modifies
STRING, and returns a pointer to it. */
/* Remove backslashes which are quoting backquotes from STRING. Modifies
STRING, and returns a pointer to it. */
/* Extract the $( construct in STRING, and return a new string.
Start extracting at (SINDEX) as if we had just seen "$(".
Make (SINDEX) get the position just after the matching ")".
XFLAGS is additional flags to pass to other extraction functions, */
/* Extract the $( construct in STRING, and return a new string.
Start extracting at (SINDEX) as if we had just seen "$(".
Make (SINDEX) get the position just after the matching ")".
XFLAGS is additional flags to pass to other extraction functions, */
/* Extract the $[ construct in STRING, and return a new string.
Start extracting at (SINDEX) as if we had just seen "$[".
Make (SINDEX) get the position just after the matching "]". */
/* Extract the $[ construct in STRING, and return a new string.
Start extracting at (SINDEX) as if we had just seen "$[".
Make (SINDEX) get the position just after the matching "]". */
#if defined (PROCESS_SUBSTITUTION)
/* Extract the <( or >( construct in STRING, and return a new string.
Start extracting at (SINDEX) as if we had just seen "<(".
Make (SINDEX) get the position just after the matching ")". */
#if defined (PROCESS_SUBSTITUTION)
/* Extract the <( or >( construct in STRING, and return a new string.
Start extracting at (SINDEX) as if we had just seen "<(".
Make (SINDEX) get the position just after the matching ")". */
-extern char *extract_process_subst __P((char *, char *, int *, int));
+extern char *extract_process_subst PARAMS((char *, char *, int *, int));
#endif /* PROCESS_SUBSTITUTION */
/* Extract the name of the variable to bind to from the assignment string. */
#endif /* PROCESS_SUBSTITUTION */
/* Extract the name of the variable to bind to from the assignment string. */
/* Return a single string of all the words present in LIST, separating
each word with a space. */
/* Return a single string of all the words present in LIST, separating
each word with a space. */
the various subtleties of using the first character of $IFS as the
separator. Calls string_list_dollar_at, string_list_dollar_star, and
string_list as appropriate. */
the various subtleties of using the first character of $IFS as the
separator. Calls string_list_dollar_at, string_list_dollar_star, and
string_list as appropriate. */
-extern char *string_list_pos_params __P((int, WORD_LIST *, int));
+extern char *string_list_pos_params PARAMS((int, WORD_LIST *, int, int));
-extern char *ifs_firstchar __P((int *));
-extern char *get_word_from_string __P((char **, char *, char **));
-extern char *strip_trailing_ifs_whitespace __P((char *, char *, int));
+extern char *ifs_firstchar PARAMS((int *));
+extern char *get_word_from_string PARAMS((char **, char *, char **));
+extern char *strip_trailing_ifs_whitespace PARAMS((char *, char *, int));
/* Given STRING, an assignment string, get the value of the right side
of the `=', and bind it to the left side. If EXPAND is true, then
perform tilde expansion, parameter expansion, command substitution,
and arithmetic expansion on the right-hand side. Do not perform word
splitting on the result of expansion. */
/* Given STRING, an assignment string, get the value of the right side
of the `=', and bind it to the left side. If EXPAND is true, then
perform tilde expansion, parameter expansion, command substitution,
and arithmetic expansion on the right-hand side. Do not perform word
splitting on the result of expansion. */
-extern int do_assignment __P((char *));
-extern int do_assignment_no_expand __P((char *));
-extern int do_word_assignment __P((WORD_DESC *, int));
+extern int do_assignment PARAMS((char *));
+extern int do_assignment_no_expand PARAMS((char *));
+extern int do_word_assignment PARAMS((WORD_DESC *, int));
/* Append SOURCE to TARGET at INDEX. SIZE is the current amount
of space allocated to TARGET. SOURCE can be NULL, in which
case nothing happens. Gets rid of SOURCE by free ()ing it.
Returns TARGET in case the location has changed. */
/* Append SOURCE to TARGET at INDEX. SIZE is the current amount
of space allocated to TARGET. SOURCE can be NULL, in which
case nothing happens. Gets rid of SOURCE by free ()ing it.
Returns TARGET in case the location has changed. */
-extern char *sub_append_string __P((char *, char *, int *, size_t *));
+extern char *sub_append_string PARAMS((char *, char *, int *, size_t *));
/* Append the textual representation of NUMBER to TARGET.
INDEX and SIZE are as in SUB_APPEND_STRING. */
/* Append the textual representation of NUMBER to TARGET.
INDEX and SIZE are as in SUB_APPEND_STRING. */
-extern char *sub_append_number __P((intmax_t, char *, int *, int *));
+extern char *sub_append_number PARAMS((intmax_t, char *, int *, int *));
/* Make a single large string out of the dollar digit variables,
and the rest_of_args. If DOLLAR_STAR is 1, then obey the special
case of "$*" with respect to IFS. */
/* Make a single large string out of the dollar digit variables,
and the rest_of_args. If DOLLAR_STAR is 1, then obey the special
case of "$*" with respect to IFS. */
/* Expand STRING by performing parameter expansion, command substitution,
and arithmetic expansion. Dequote the resulting WORD_LIST before
returning it, but do not perform word splitting. The call to
remove_quoted_nulls () is made here because word splitting normally
takes care of quote removal. */
/* Expand STRING by performing parameter expansion, command substitution,
and arithmetic expansion. Dequote the resulting WORD_LIST before
returning it, but do not perform word splitting. The call to
remove_quoted_nulls () is made here because word splitting normally
takes care of quote removal. */
/* Expand STRING just as if you were expanding a word. This also returns
a list of words. Note that filename globbing is *NOT* done for word
or string expansion, just when the shell is expanding a command. This
does parameter expansion, command substitution, arithmetic expansion,
and word splitting. Dequote the resultant WORD_LIST before returning. */
/* Expand STRING just as if you were expanding a word. This also returns
a list of words. Note that filename globbing is *NOT* done for word
or string expansion, just when the shell is expanding a command. This
does parameter expansion, command substitution, arithmetic expansion,
and word splitting. Dequote the resultant WORD_LIST before returning. */
/* Convenience functions that expand strings to strings, taking care of
converting the WORD_LIST * returned by the expand_string* functions
to a string and deallocating the WORD_LIST *. */
/* Convenience functions that expand strings to strings, taking care of
converting the WORD_LIST * returned by the expand_string* functions
to a string and deallocating the WORD_LIST *. */
-extern char *expand_string_to_string __P((char *, int));
-extern char *expand_string_unsplit_to_string __P((char *, int));
-extern char *expand_assignment_string_to_string __P((char *, int));
+extern char *expand_string_to_string PARAMS((char *, int));
+extern char *expand_string_unsplit_to_string PARAMS((char *, int));
+extern char *expand_assignment_string_to_string PARAMS((char *, int));
/* Expand WORD, performing word splitting on the result. This does
parameter expansion, command substitution, arithmetic expansion,
word splitting, and quote removal. */
/* Expand WORD, performing word splitting on the result. This does
parameter expansion, command substitution, arithmetic expansion,
word splitting, and quote removal. */
/* Expand WORD, but do not perform word splitting on the result. This
does parameter expansion, command substitution, arithmetic expansion,
and quote removal. */
/* Expand WORD, but do not perform word splitting on the result. This
does parameter expansion, command substitution, arithmetic expansion,
and quote removal. */
-extern WORD_LIST *expand_word_unsplit __P((WORD_DESC *, int));
-extern WORD_LIST *expand_word_leave_quoted __P((WORD_DESC *, int));
+extern WORD_LIST *expand_word_unsplit PARAMS((WORD_DESC *, int));
+extern WORD_LIST *expand_word_leave_quoted PARAMS((WORD_DESC *, int));
/* Perform quote removal on STRING. If QUOTED > 0, assume we are obeying the
backslash quoting rules for within double quotes. */
/* Perform quote removal on STRING. If QUOTED > 0, assume we are obeying the
backslash quoting rules for within double quotes. */
/* Perform quote removal on all words in LIST. If QUOTED is non-zero,
the members of the list are treated as if they are surrounded by
double quotes. Return a new list, or NULL if LIST is NULL. */
/* Perform quote removal on all words in LIST. If QUOTED is non-zero,
the members of the list are treated as if they are surrounded by
double quotes. Return a new list, or NULL if LIST is NULL. */
/* This splits a single word into a WORD LIST on $IFS, but only if the word
is not quoted. list_string () performs quote removal for us, even if we
don't do any splitting. */
/* This splits a single word into a WORD LIST on $IFS, but only if the word
is not quoted. list_string () performs quote removal for us, even if we
don't do any splitting. */
/* Take the list of words in LIST and do the various substitutions. Return
a new list of words which is the expanded list, and without things like
variable assignments. */
/* Take the list of words in LIST and do the various substitutions. Return
a new list of words which is the expanded list, and without things like
variable assignments. */
/* Perform the `normal shell expansions' on a WORD_LIST. These are
brace expansion, tilde expansion, parameter and variable substitution,
command substitution, arithmetic expansion, and word splitting. */
/* Perform the `normal shell expansions' on a WORD_LIST. These are
brace expansion, tilde expansion, parameter and variable substitution,
command substitution, arithmetic expansion, and word splitting. */
-extern WORD_DESC *command_substitute __P((char *, int, int));
-extern char *pat_subst __P((char *, char *, char *, int));
+extern WORD_DESC *command_substitute PARAMS((char *, int, int));
+extern char *pat_subst PARAMS((char *, char *, char *, int));
-extern int fifos_pending __P((void));
-extern int num_fifos __P((void));
-extern void unlink_fifo_list __P((void));
-extern void unlink_fifo __P((int));
+extern int fifos_pending PARAMS((void));
+extern int num_fifos PARAMS((void));
+extern void unlink_fifo_list PARAMS((void));
+extern void unlink_all_fifos PARAMS((void));
+extern void unlink_fifo PARAMS((int));
-extern void *copy_fifo_list __P((int *));
-extern void close_new_fifos __P((void *, int));
+extern void *copy_fifo_list PARAMS((int *));
+extern void close_new_fifos PARAMS((void *, int));
-extern int find_procsub_child __P((pid_t));
-extern void set_procsub_status __P((int, pid_t, int));
+extern int find_procsub_child PARAMS((pid_t));
+extern void set_procsub_status PARAMS((int, pid_t, int));
-extern char *remove_backslashes __P((char *));
-extern char *cond_expand_word __P((WORD_DESC *, int));
+extern char *remove_backslashes PARAMS((char *));
+extern char *cond_expand_word PARAMS((WORD_DESC *, int));
#define SD_HISTEXP 0x200 /* skip_to_delim during history expansion */
#define SD_ARITHEXP 0x400 /* skip_to_delim during arithmetic expansion */
#define SD_HISTEXP 0x200 /* skip_to_delim during history expansion */
#define SD_ARITHEXP 0x400 /* skip_to_delim during arithmetic expansion */
-extern int skip_to_delim __P((char *, int, char *, int));
+extern int skip_to_delim PARAMS((char *, int, char *, int));
-extern int skip_to_histexp __P((char *, int, char *, int));
+extern int skip_to_histexp PARAMS((char *, int, char *, int));
-extern int char_is_quoted __P((char *, int));
-extern int unclosed_pair __P((char *, int, char *));
-extern WORD_LIST *split_at_delims __P((char *, int, char *, int, int, int *, int *));
+extern int char_is_quoted PARAMS((char *, int));
+extern int unclosed_pair PARAMS((char *, int, char *));
+extern WORD_LIST *split_at_delims PARAMS((char *, int, char *, int, int, int *, int *));
/* Is the first character of STRING a quoted NULL character? */
#define QUOTED_NULL(string) ((string)[0] == CTLNUL && (string)[1] == '\0')
/* Is the first character of STRING a quoted NULL character? */
#define QUOTED_NULL(string) ((string)[0] == CTLNUL && (string)[1] == '\0')