blob: c7c99e7b1467c36a4e57de7b39231502cedc053b [file] [log] [blame]
Jari Aalto726f6381996-08-26 18:22:31 +00001/* common.h -- extern declarations for functions defined in common.c. */
2
3/* Copyright (C) 1993 Free Software Foundation, Inc.
4
5 This file is part of GNU Bash, the Bourne Again SHell.
6
7 Bash is free software; you can redistribute it and/or modify it under
8 the terms of the GNU General Public License as published by the Free
9 Software Foundation; either version 2, or (at your option) any later
10 version.
11
12 Bash is distributed in the hope that it will be useful, but WITHOUT ANY
13 WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15 for more details.
16
17 You should have received a copy of the GNU General Public License along
18 with Bash; see the file COPYING. If not, write to the Free Software
19 Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
20
21#if !defined (__COMMON_H)
22# define __COMMON_H
23
24#define ISOPTION(s, c) (s[0] == '-' && !s[2] && s[1] == c)
25
26extern void builtin_error ();
27extern void bad_option ();
28
29extern int get_numeric_arg ();
30
31extern void remember_args ();
32
33extern void no_args ();
34
35extern int read_octal ();
36
37extern char *find_hashed_filename ();
38extern void remove_hashed_filename ();
39extern void remember_filename ();
40
41extern void push_context (), pop_context ();
42extern void push_dollar_vars (), pop_dollar_vars ();
43extern void dispose_saved_dollar_vars ();
44extern int dollar_vars_changed ();
45extern void set_dollar_vars_unchanged (), set_dollar_vars_changed ();
46
47/* Keeps track of the current working directory. */
48extern char *the_current_working_directory;
49extern char *get_working_directory ();
50extern void set_working_directory ();
51
52#if defined (JOB_CONTROL)
53extern int get_job_spec ();
54#endif
55
56extern int parse_and_execute ();
57extern void parse_and_execute_cleanup ();
58
59extern void initialize_shell_builtins ();
60
61/* It's OK to declare a function as returning a Function * without
62 providing a definition of what a `Function' is. */
63extern Function *find_shell_builtin ();
64extern Function *builtin_address ();
65
66extern char *single_quote ();
67extern char *double_quote ();
68
69#endif /* !__COMMON_H */