#pragma prototyped
#ifndef NOTSYM
#include <cdt.h>
#include "FEATURE/options"
#include "shnodes.h"
#include "shtable.h"
#include "lexstates.h"
struct shlex_t
{
Shell_t *sh;
struct argnod *arg;
struct ionod *heredoc;
int token;
int lastline;
int lasttok;
int digits;
char aliasok;
char assignok;
int inlineno;
int firstline;
int comsub;
#if SHOPT_KIA
Sfio_t *kiafile;
Sfio_t *kiatmp;
unsigned long script;
unsigned long fscript;
unsigned long current;
unsigned long unknown;
off_t kiabegin;
char *scriptname;
Dt_t *entity_tree;
#endif
};
#define NL '\n'
#define NOTSYM '!'
#define SYMRES 0400
#define DOSYM (SYMRES|01)
#define FISYM (SYMRES|02)
#define ELIFSYM (SYMRES|03)
#define ELSESYM (SYMRES|04)
#define INSYM (SYMRES|05)
#define THENSYM (SYMRES|06)
#define DONESYM (SYMRES|07)
#define ESACSYM (SYMRES|010)
#define IFSYM (SYMRES|011)
#define FORSYM (SYMRES|012)
#define WHILESYM (SYMRES|013)
#define UNTILSYM (SYMRES|014)
#define CASESYM (SYMRES|015)
#define FUNCTSYM (SYMRES|016)
#define SELECTSYM (SYMRES|017)
#define TIMESYM (SYMRES|020)
#define NSPACESYM (SYMRES|021)
#define SYMREP 01000
#define BREAKCASESYM (SYMREP|';')
#define ANDFSYM (SYMREP|'&')
#define ORFSYM (SYMREP|'|')
#define IOAPPSYM (SYMREP|'>')
#define IODOCSYM (SYMREP|'<')
#define EXPRSYM (SYMREP|'(')
#define BTESTSYM (SYMREP|'[')
#define ETESTSYM (SYMREP|']')
#define SYMMASK 0170000
#define SYMPIPE 010000
#define SYMLPAR 020000
#define SYMAMP 040000
#define SYMGT 0100000
#define SYMSEMI 0110000
#define SYMSHARP 0120000
#define IOSEEKSYM (SYMSHARP|'<')
#define IOMOV0SYM (SYMAMP|'<')
#define IOMOV1SYM (SYMAMP|'>')
#define FALLTHRUSYM (SYMAMP|';')
#define COOPSYM (SYMAMP|'|')
#define IORDWRSYM (SYMGT|'<')
#define IOCLOBSYM (SYMPIPE|'>')
#define IPROCSYM (SYMLPAR|'<')
#define OPROCSYM (SYMLPAR|'>')
#define EOFSYM 04000
#define TESTUNOP 04001
#define TESTBINOP 04002
#define LABLSYM 04003
#define IOVNAME 04004
#define SH_EMPTY 04
#define SH_NOIO 010
#define SH_ASSIGN 020
#define SH_FUNDEF 040
#define SH_ARRAY 0100
#define SH_SEMI 0200
#define SH_COMPASSIGN 010
typedef struct _shlex_
{
struct shlex_t _shlex;
#ifdef _SHLEX_PRIVATE
_SHLEX_PRIVATE
#endif
} Lex_t;
#define shlex (((Lex_t*)(sh.lex_context))->_shlex)
extern const char e_unexpected[];
extern const char e_unmatched[];
extern const char e_endoffile[];
extern const char e_newline[];
#define LBRACE '{'
#define RBRACE '}'
#define LPAREN '('
#define RPAREN ')'
#define LBRACT '['
#define RBRACT ']'
extern int sh_lex();
extern Lex_t *sh_lexopen(Lex_t*, Shell_t*, int);
extern void sh_lexskip(int,int,int);
extern void sh_syntax(void);
#endif