xref: /titanic_50/usr/src/cmd/csh/sh.tconst.c (revision 174bc6499d233e329ecd3d98a880a7b07df16bfa)
1 /*
2  * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
3  * Use is subject to license terms.
4  */
5 
6 /*	Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T	*/
7 /*	  All Rights Reserved  	*/
8 
9 /*
10  * Copyright (c) 1980 Regents of the University of California.
11  * All rights reserved. The Berkeley Software License Agreement
12  * specifies the terms and conditions for redistribution.
13  */
14 
15 #pragma ident	"%Z%%M%	%I%	%E% SMI"
16 
17 /*
18  * C shell
19  */
20 
21 /*
22  * These tchar constants used to be defined as
23  * character string constants.
24  */
25 
26 #include "sh.h"
27 
28 tchar S_[] = {0};
29 tchar S_0[]={'0', 0};
30 tchar S_1[]={'1', 0};
31 tchar S_AND[] = {'&', 0};	/* & */
32 tchar S_ANDAND[] = {'&', '&', 0};	/* && */
33 tchar S_AST[]={'*', 0};
34 tchar S_AT[] = { '@', 0 };
35 tchar S_BAR[] = {'|', 0};	/* | */
36 tchar S_BARBAR[] = {'|','|', 0};	/* || */
37 tchar S_BRABRA[] = {'{', '}', 0};	/* {} */
38 tchar S_BRAPPPBRA[] = {'{', ' ', '.', '.', '.', ' ', '}', 0};	/* { ... } */
39 tchar S_COLON[] = {':', 0}; /*:*/
40 tchar S_DASHl[] = {'-', 'l', 0};	/*-l */
41 tchar S_DELIM[] = {' ','\'','"','\t',';','&','<','>','(',')','|','`',0};
42 tchar S_DOT[] = {'.', 0};
43 tchar S_DOTDOTSLA[]={'.', '.', '/', 0};
44 tchar S_DOTSLA[]={'.', '/', 0};
45 tchar S_EQ[] = {'=', 0};	/*=*/
46 tchar S_EXAS[] = {'!', 0};       /* ! */
47 tchar S_HAT[] = {'^', 0};	/* ^ */
48 tchar S_HOME[] = {'H','O','M','E',0};/*HOME*/
49 tchar S_IOT[] = {'I', 'O', 'T', 0}; /*IOT*/
50 tchar S_LANG[]={'L', 'A', 'N', 'G', 0}; /*LANG*/
51 tchar S_LBRA[] = {'{', 0};	/* { */
52 tchar S_LBRASP[] = {'(', ' ', 0};	/*( */
53 tchar S_LC_ALL[]={'L', 'C', '_', 'A', 'L', 'L',  0}; /*LC_ALL*/
54 tchar S_LC_CTYPE[]={'L', 'C', '_', 'C', 'T', 'Y', 'P',  'E', 0}; /*LC_CTYPE*/
55 tchar S_LC_MESSAGES[]={'L', 'C', '_',
56 		   'M', 'E', 'S', 'S', 'A', 'G', 'E', 'S', 0}; /*LC_MESSAGES*/
57 tchar S_LESLES[]={'<', '<', 0};
58 tchar S_LPAR[] = {'(', 0};	/* ( */
59 tchar S_MINUS[] = {'-',0};/*"-"*/
60 tchar S_MINl[]={'-', 'l', 0};
61 tchar S_NDOThistory[] = {'~','/','.','h','i','s','t','o','r','y',0};
62 tchar S_OTHERSH[] = {'/','b','i','n','/','s','h',0};
63 tchar S_PARCENTMINUS[] = {'%', '-', 0}; /*%-*/
64 tchar S_PARCENTPARCENT[] = {'%', '%', 0}; /*%%*/
65 tchar S_PARCENTPLUS[] = {'%', '+', 0}; /*%+*/
66 tchar S_PARCENTSHARP[] = {'%', '#', 0}; /*%#*/
67 tchar S_PATH[] = {'P','A','T','H',0};/*"PATH"*/
68 tchar S_PERSENTSP[] = {'%',' ',0};
69 tchar S_PWD[]={'P', 'W', 'D', 0};
70 tchar S_Pjob[] = {'%','j','o','b', 0}; /*"%job"*/
71 tchar S_PjobAND[] = {'%','j','o','b',' ','&',0}; /*"%job &"*/
72 tchar S_QPPPQ[] = {'`', ' ', '.', '.', '.', ' ', '`', 0}; /*` ... `*/
73 tchar S_RBRA[] = {'}', 0};	/* } */
74 tchar S_RPAR[] = {')', 0}; /*)*/
75 tchar S_SEMICOLONSP[] = {';', ' ', 0};	/* | */
76 tchar S_SHARPSP[] = {'#',' ',0};
77 tchar S_SHELLPATH[] = {'/','b','i','n','/','c','s','h',0};
78 tchar S_SLADOTcshrc[] = {'/','.','c','s','h','r','c', 0};
79 tchar S_SLADOThistory[] = {'/','.','h','i','s','t','o','r','y', 0};
80 tchar S_SLADOTlogin[] = {'/','.','l','o','g','i','n', 0};
81 tchar S_SLADOTlogout[] = {'/','.','l','o','g','o','u','t', 0};
82 tchar S_SLASH[] = {'/', 0}; /* "/" */
83 tchar S_SP[] = {' ', 0};	/* */
84 tchar S_SPANDANDSP[] = {' ', '&', '&', ' ', 0};	/* && */
85 tchar S_SPBARBARSP[] = {' ', '|', '|', ' ', 0};	/* || */
86 tchar S_SPBARSP[] = {' ', '|', ' ', 0};	/* | */
87 tchar S_SPGTRGTRSP[] = {' ', '>', '>', ' ', 0};	/* >> */
88 tchar S_SPGTR[] = {' ', '>',0};	/* > */
89 tchar S_SPLESLESSP[] = {' ', '<', '<', ' ', 0};	/* << */
90 tchar S_SPLESSP[] = {' ', '<', ' ', 0};	/* < */
91 tchar S_SPPPP[] = {' ', '.', '.', '.', 0};	/* ... */
92 tchar S_SPRBRA[] = {' ', ')', 0};	/* )*/
93 tchar S_SUNW_VARLEN[] = {'S', 'U', 'N', 'W', '_',
94 	'V', 'A', 'R', 'L', 'E', 'N', 0};
95 tchar S_TERM[] = {'T','E','R','M',0};/*TERM*/
96 tchar S_TIL[] = {'~', 0};	/* ~ */
97 tchar S_TOPBIT[] = {(tchar)QUOTE, 0};	/* Was "\200".  A hack! */
98 tchar S_USAGEFORMAT[] = {'%','U','u',' ','%','S','s',' ','%','E',' ','%','P', ' ','%','X','+','%','D','k',' ','%','I','+','%','O','i','o',' ','%','F','p','f','+', '%','W','w',0};
99 tchar S_USER[] = {'U','S','E','R',0};/*USER*/
100 tchar S_alias[] = { 'a','l','i','a','s', 0 };
101 tchar S_alloc[] = { 'a','l','l','o','c', 0};
102 tchar S_aout[] = {'a','.','o','u','t',0};
103 tchar S_argv[]={'a', 'r', 'g', 'v', 0};
104 tchar S_bg[] = { 'b','g', 0};
105 tchar S_bin[] = {'/','b','i','n',0};
106 tchar S_break[] = { 'b','r','e','a','k', 0};
107 tchar S_breaksw[] = { 'b','r','e','a','k','s','w', 0};
108 tchar S_bye[] = { 'b','y','e', 0};
109 tchar S_case[] = { 'c','a','s','e', 0};
110 tchar S_cd[] = { 'c','d', 0};
111 tchar S_cdpath[]={'c', 'd', 'p', 'a', 't', 'h', 0};
112 tchar S_chdir[] = { 'c','h','d','i','r', 0};
113 tchar S_child[] = {'c', 'h', 'i', 'l', 'd', 0};	/*child */
114 tchar S_continue[] = { 'c','o','n','t','i','n','u','e', 0};
115 tchar S_coredumpsize[] = {'c','o','r','e','d','u','m','p','s','i','z','e',0};/*"coredumpsize"*/
116 tchar S_cputime[] = {'c','p','u','t','i','m','e',0};/*"cputime"*/
117 tchar S_csh[]={'c', 's', 'h', 0};
118 tchar S_cwd[]={'c', 'w', 'd', 0};
119 tchar S_datasize[] = {'d','a','t','a','s','i','z','e',0};/*"datasize"*/
120 tchar S_default[] =  { 'd','e','f','a','u','l','t', 0 };
121 tchar S_descriptors[] = {'d', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 's', 0};
122 tchar S_dirs[] =  { 'd','i','r','s', 0 };
123 tchar S_echo[] = {'e','c','h','o', 0};
124 tchar S_else[] =  { 'e','l','s','e', 0 };
125 tchar S_end[] =  { 'e','n','d', 0 };
126 tchar S_endif[] =  { 'e','n','d','i','f', 0 };
127 tchar S_endsw[] =  { 'e','n','d','s','w', 0 };
128 tchar S_erwxfdzo[] = {'e', 'r', 'w', 'x', 'f', 'd', 'z', 'o', 0}; /* erwxfdzo */
129 tchar S_eval[] =  { 'e','v','a','l', 0 };
130 tchar S_exec[] =  { 'e','x','e','c', 0 };
131 tchar S_exit[] =  { 'e','x','i','t', 0 };
132 tchar S_fg[] =  { 'f','g', 0 };
133 tchar S_fignore[] = {'f','i','g','n','o','r','e',0};
134 tchar S_filec[] = {'f','i','l','e','c',0};/*filec*/
135 tchar S_filesize[] = {'f','i','l','e','s','i','z','e',0};/*"filesize"*/
136 tchar S_foreach[] =  { 'f','o','r','e','a','c','h', 0 };
137 tchar S_gd[] =  { 'g','d', 0 };
138 tchar S_glob[] =  { 'g','l','o','b', 0 };
139 tchar S_goto[] =  { 'g','o','t','o', 0 };
140 tchar S_h[] = {'-','h',0};
141 tchar S_hardpaths[]={'h', 'a', 'r', 'd', 'p', 'a', 't', 'h', 's', 0};
142 tchar S_hashstat[] =  { 'h','a','s','h','s','t','a','t', 0 };
143 tchar S_histchars[] = {'h','i','s','t','c','h','a','r','s',0}; /*histchars*/
144 tchar S_history[] = {'h','i','s','t','o','r','y',0};
145 tchar S_home[]={'h', 'o', 'm', 'e', 0};
146 tchar S_hours[] = {'h','o','u','r','s',0};/*"hours"*/
147 tchar S_htrqxe[]={'h', 't', 'r', 'q', 'x', 'e', 0};
148 tchar S_if[] =  { 'i','f', 0 };
149 tchar S_ignoreeof[] = {'i','g','n','o','r','e','e','o','f',0};	/*"ignoreeof"*/
150 tchar S_jobs[] = {'j','o','b','s', 0};
151 tchar S_kbytes[] = {'k','b','y','t','e','s',0};/*"kbytes"*/
152 tchar S_kill[] =  { 'k','i','l','l', 0 };
153 tchar S_label[] =  { 'l','a','b','e','l', 0 };
154 tchar S_limit[] =  { 'l','i','m','i','t', 0 };
155 tchar S_login[] =  { 'l','o','g','i','n', 0 };
156 tchar S_logout[] =  { 'l','o','g','o','u','t', 0 };
157 tchar S_mail[] = {'m','a','i','l', 0};
158 tchar S_megabytes[] = {'m','e','g','a','b','y','t','e','s',0};/*"megabytes"*/
159 tchar S_memorysize[] = {'m','e','m','o','r','y','s','i','z','e',0};/*"memorysize"*/
160 tchar S_minutes[]={'m','i','n','u','t','e','s',0};/*"minutes"*/
161 tchar S_n[] = {'-','n',0};/*"-n"*/
162 tchar S_newgrp[] =  { 'n','e','w','g','r','p', 0 };
163 tchar S_nice[] =  { 'n','i','c','e', 0 };
164 tchar S_nobeep[] = {'n', 'o', 'b', 'e', 'e', 'p', 0};
165 tchar S_noclobber[] = {'n','o','c','l','o','b','b','e','r',0};/*noclobber*/
166 tchar S_noglob[] = {'n', 'o', 'g', 'l', 'o', 'b', 0}; /*noglob */
167 tchar S_nohup[] = {'n', 'o', 'h', 'u', 'p', 0};	/*nohup */
168 tchar S_nonomatch[] = {'n', 'o', 'n', 'o', 'm', 'a', 't', 'c', 'h', 0}; /*nonomatch */
169 tchar S_notify[] = {'n', 'o', 't', 'i', 'f', 'y', 0};	/*nofify */
170 tchar S_onintr[] =  { 'o','n','i','n','t','r', 0 };
171 tchar S_path[] = {'p','a','t','h', 0}; /*path*/
172 tchar S_popd[] =  { 'p','o','p','d', 0 };
173 tchar S_prompt[] = {'p','r','o','m','p','t', 0};
174 tchar S_pushd[] =  { 'p','u','s','h','d', 0 };
175 tchar S_rd[] =  { 'r','d', 0 };
176 tchar S_rehash[] =  { 'r','e','h','a','s','h', 0 };
177 tchar S_repeat[] =  { 'r','e','p','e','a','t', 0 };
178 tchar S_savehist[] = {'s','a','v','e','h','i','s','t', 0};
179 tchar S_seconds[] = {'s','e','c','o','n','d','s',0};/*"seconds"*/
180 tchar S_set[] =  { 's','e','t', 0 };
181 tchar S_setenv[] =  { 's','e','t','e','n','v', 0 };
182 tchar S_shell[] = {'s','h','e','l','l', 0};
183 tchar S_shift[] =  { 's','h','i','f','t', 0 };
184 tchar S_source[] = {'s','o','u','r','c','e',0};
185 tchar S_stacksize[] = {'s','t','a','c','k','s','i','z','e',0};/*"stacksize"*/
186 tchar S_status[]={'s', 't', 'a', 't', 'u', 's', 0};
187 tchar S_stop[] =  { 's','t','o','p', 0 };
188 tchar S_suspend[] =  { 's','u','s','p','e','n','d', 0 };
189 tchar S_switch[] =  { 's','w','i','t','c','h', 0 };
190 tchar S_term[] = {'t','e','r','m', 0};
191 tchar S_then[] = {'t','h','e','n',0}; /*"then"*/
192 tchar S_time[] = {'t', 'i', 'm', 'e', 0};	/*time*/
193 tchar S_umask[] =  { 'u','m','a','s','k', 0 };
194 tchar S_unalias[] =  { 'u','n','a','l','i','a','s', 0 };
195 tchar S_unhash[] =  { 'u','n','h','a','s','h', 0 };
196 tchar S_unlimit[] =  { 'u','n','l','i','m','i','t', 0 };
197 tchar S_unlimited[] = {'u','n','l','i','m','i','t','e','d',0};/*"unlimited"*/
198 tchar S_unset[] =  { 'u','n','s','e','t', 0 };
199 tchar S_unsetenv[] =  { 'u','n','s','e','t','e','n','v', 0 };
200 tchar S_user[] = {'u','s','e','r', 0};
201 tchar S_usrbin[] = {'/','u','s','r','/','b','i','n',0};
202 tchar S_usrucb[] = {'/','u','s','r','/','u','c','b',0};
203 tchar S_verbose[] = {'v','e','r','b','o','s','e', 0};
204 tchar S_wait[] =  { 'w','a','i','t', 0 };
205 tchar S_while[] =  { 'w','h','i','l','e', 0 };
206 /* Dummy search path for just absolute search when no path */
207 tchar *justabs[] =      { S_ /* "" */, 0 };
208