/***********************************************************************
* *
* This software is part of the ast package *
* Copyright (c) 1982-2011 AT&T Intellectual Property *
* and is licensed under the *
* Eclipse Public License, Version 1.0 *
* by AT&T Intellectual Property *
* *
* A copy of the License is available at *
* (with md5 checksum b35adb5213ca9657e911e9befb180842) *
* *
* Information and Software Systems Research *
* AT&T Research *
* Florham Park NJ *
* *
* David Korn <dgk@research.att.com> *
* *
***********************************************************************/
#pragma prototyped
/*
* David Korn
* AT&T Labs
*
* shell intermediate code reader
*
*/
#include "defs.h"
#include "shnodes.h"
#include "path.h"
#include "io.h"
#include <ccode.h>
{
Shnode_t *t;
return(t);
}
/*
* read in a shell tree
*/
{
register int type;
register Shnode_t *t=0;
if(l<0)
return(t);
type = l;
{
case TTIME:
case TPAR:
break;
case TCOM:
break;
case TSETIO:
case TFORK:
break;
case TIF:
break;
case TWH:
break;
case TLST:
case TAND:
case TORF:
case TFIL:
break;
case TARITH:
break;
case TFOR:
break;
case TSW:
else
break;
case TFUN:
{
break;
}
case TTST:
else
{
}
}
if(t)
return(t);
}
{
register long l;
{
if(!aptop)
else
if(--l > 0)
{
}
#if 0
{
/* replace international messages */
else
{
}
}
else
#endif
{
}
}
if(ap)
return(aptop);
}
{
register long l;
{
if(!ioptop)
else
{
else
{
}
}
else
}
if(iop)
return(ioptop);
}
{
char *cmdname=0;
{
}
if(cmdname)
{
char *cp;
{
*cp = 0;
*cp = '.';
}
}
else
}
{
register long l;
register char **argv;
{
}
return(dol);
}
{
register long l;
{
if(!regtop)
else
}
if(reg)
return(regtop);
}
{
register char *ptr;
if(l == 0)
return(NIL(char*));
if(--l > 0)
{
return(NIL(char*));
}
ptr[l] = 0;
return(ptr);
}