2015-12-12 22:08:44 +01:00
|
|
|
/*-
|
2016-07-25 22:43:54 +02:00
|
|
|
* Copyright (c) 2009, 2011, 2012, 2016
|
2015-12-12 22:08:44 +01:00
|
|
|
* mirabilos <m@mirbsd.org>
|
|
|
|
*
|
|
|
|
* Provided that these terms and disclaimer and all copyright notices
|
|
|
|
* are retained or reproduced in an accompanying document, permission
|
|
|
|
* is granted to deal in this work without restriction, including un-
|
|
|
|
* limited rights to use, publicly perform, distribute, sell, modify,
|
|
|
|
* merge, give away, or sublicence.
|
|
|
|
*
|
|
|
|
* This work is provided "AS IS" and WITHOUT WARRANTY of any kind, to
|
|
|
|
* the utmost extent permitted by applicable law, neither express nor
|
|
|
|
* implied; without malicious intent or gross negligence. In no event
|
|
|
|
* may a licensor, author or contributor be held liable for indirect,
|
|
|
|
* direct, other damage, loss, or other issues arising in any way out
|
|
|
|
* of dealing in the work, even if advised of the possibility of such
|
|
|
|
* damage or existence of a defect, except proven that it results out
|
|
|
|
* of said person's immediate fault when using the work as intended.
|
|
|
|
*/
|
|
|
|
|
2009-09-26 05:40:03 +02:00
|
|
|
#if defined(VARSPEC_DEFNS)
|
2016-11-12 00:31:39 +01:00
|
|
|
__RCSID("$MirOS: src/bin/mksh/var_spec.h,v 1.10 2016/11/11 23:31:39 tg Exp $");
|
2009-09-26 05:40:03 +02:00
|
|
|
#define FN(name) /* nothing */
|
|
|
|
#elif defined(VARSPEC_ENUMS)
|
|
|
|
#define FN(name) V_##name,
|
|
|
|
#define F0(name) V_##name = 0,
|
|
|
|
#elif defined(VARSPEC_ITEMS)
|
|
|
|
#define F0(name) /* nothing */
|
|
|
|
#define FN(name) #name,
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef F0
|
|
|
|
#define F0 FN
|
|
|
|
#endif
|
|
|
|
|
2011-06-05 21:58:21 +02:00
|
|
|
/* NOTE: F0 are skipped for the ITEMS array, only FN generate names */
|
|
|
|
|
2009-09-26 05:40:03 +02:00
|
|
|
/* 0 is always V_NONE */
|
|
|
|
F0(NONE)
|
|
|
|
|
|
|
|
/* 1 and up are special variables */
|
2012-11-20 18:42:32 +01:00
|
|
|
FN(BASHPID)
|
2016-11-12 00:31:39 +01:00
|
|
|
#ifdef __OS2__
|
|
|
|
FN(BEGINLIBPATH)
|
|
|
|
#endif
|
2009-09-26 05:40:03 +02:00
|
|
|
FN(COLUMNS)
|
2016-11-12 00:31:39 +01:00
|
|
|
#ifdef __OS2__
|
|
|
|
FN(ENDLIBPATH)
|
|
|
|
#endif
|
2012-11-30 17:45:25 +01:00
|
|
|
FN(EPOCHREALTIME)
|
2009-09-26 05:40:03 +02:00
|
|
|
#if HAVE_PERSISTENT_HISTORY
|
|
|
|
FN(HISTFILE)
|
|
|
|
#endif
|
|
|
|
FN(HISTSIZE)
|
|
|
|
FN(IFS)
|
2016-11-12 00:31:39 +01:00
|
|
|
#ifdef __OS2__
|
|
|
|
FN(LIBPATHSTRICT)
|
|
|
|
#endif
|
2009-09-26 05:40:03 +02:00
|
|
|
FN(LINENO)
|
|
|
|
FN(LINES)
|
|
|
|
FN(OPTIND)
|
|
|
|
FN(PATH)
|
|
|
|
FN(RANDOM)
|
|
|
|
FN(SECONDS)
|
2016-07-25 23:02:13 +02:00
|
|
|
#ifndef MKSH_NO_CMDLINE_EDITING
|
2016-07-25 22:43:54 +02:00
|
|
|
FN(TERM)
|
2016-07-25 23:02:13 +02:00
|
|
|
#endif
|
2009-09-26 05:40:03 +02:00
|
|
|
FN(TMOUT)
|
|
|
|
FN(TMPDIR)
|
|
|
|
|
|
|
|
#undef FN
|
|
|
|
#undef F0
|
|
|
|
#undef VARSPEC_DEFNS
|
|
|
|
#undef VARSPEC_ENUMS
|
|
|
|
#undef VARSPEC_ITEMS
|