147
147
#define Tick ((char) 0x91)
148
148
#define Inang ((char) 0x92)
149
149
#define Outang ((char) 0x93)
150
#define Quest ((char) 0x94)
151
#define Tilde ((char) 0x95)
152
#define Qtick ((char) 0x96)
153
#define Comma ((char) 0x97)
150
#define OutangProc ((char) 0x94)
151
#define Quest ((char) 0x95)
152
#define Tilde ((char) 0x96)
153
#define Qtick ((char) 0x97)
154
#define Comma ((char) 0x98)
155
156
* Null arguments: placeholders for single and double quotes
156
157
* and backslashes.
158
#define Snull ((char) 0x98)
159
#define Dnull ((char) 0x99)
160
#define Bnull ((char) 0x9a)
159
#define Snull ((char) 0x99)
160
#define Dnull ((char) 0x9a)
161
#define Bnull ((char) 0x9b)
162
163
* Backslash which will be returned to "\" instead of being stripped
163
164
* when we turn the string into a printable format.
165
#define Bnullkeep ((char) 0x9b)
166
#define Bnullkeep ((char) 0x9c)
167
168
* Null argument that does not correspond to any character.
168
169
* This should be last as it does not appear in ztokens and
169
170
* is used to initialise the IMETA type in inittyptab().
171
#define Nularg ((char) 0x9c)
172
#define Nularg ((char) 0x9d)
174
175
* Take care to update the use of IMETA appropriately when adding
381
382
typedef struct cmdnam *Cmdnam;
382
383
typedef struct complist *Complist;
383
384
typedef struct conddef *Conddef;
385
typedef struct dirsav *Dirsav;
384
386
typedef struct features *Features;
385
387
typedef struct feature_enables *Feature_enables;
386
388
typedef struct funcstack *Funcstack;
1066
1068
char *filename; /* Name of file located in */
1067
1069
zlong lineno; /* line number in above file */
1068
1070
Eprog funcdef; /* function definition */
1071
int emulation; /* sticky emulation for function */
1071
1074
/* Shell function context types. */
1115
1118
#define WRAPDEF(func) \
1116
1119
{ NULL, 0, func, NULL }
1122
* User-defined hook arrays
1125
/* Name appended to function name to get hook array */
1126
#define HOOK_SUFFIX "_functions"
1127
/* Length of that including NUL byte */
1128
#define HOOK_SUFFIX_LEN 11
1118
1130
/* node in builtin command hash table (builtintab) */
1789
1801
#define EMULATE_SH (1<<3) /* Bourne shell */
1790
1802
#define EMULATE_ZSH (1<<4) /* `native' mode */
1804
/* Test for a shell emulation. Use this rather than emulation directly. */
1805
#define EMULATION(X) (emulation & (X))
1807
/* Return only base shell emulation field. */
1808
#define SHELL_EMULATION() (emulation & ((1<<5)-1))
1810
/* Additional flags */
1812
#define EMULATE_FULLY (1<<5) /* "emulate -R" in effect */
1814
* Higher bits are used in options.c, record lowest unused bit...
1816
#define EMULATE_UNUSED (1<<6)
1792
1818
/* option indices */