10 #ifndef STANDALONE_PARSER 33 #define fePutChar(c) fputc((unsigned char)(c),stdout) 41 #define INITIAL_PRINT_BUFFER 24*1024L 45 #define MAX_FILE_BUFFER 4*4096 85 PrintS(
"-- called from ? --\n");
87 Print(
"-- called from %s --\n",
s);
136 if (strcmp(fname,
"STDIN") == 0)
178 long l=strlen(
pi->procname);
179 if (
pi->libname!=
NULL)
l+=strlen(
pi->libname);
274 if (
p->prev==
NULL)
break;
298 if (
p->prev==
NULL)
break;
334 if (
p->prev==
NULL)
break;
425 char *ss=strrchr(anf,
'\n');
436 int mrc=
si_min(len_s,79)-1;
447 && (strncmp(anf,
";return();",10)!=0)
460 fwrite(anf,1,len_s,stdout);
465 while(fgetc(stdin)!=
'\n');
522 else if (c==
'}')
break;
543 const char *ss=strchr(anf,
'\n');
545 if (ss==
NULL) len=strlen(anf);
548 strncpy(
s,anf,len+2);
557 const char *ss=strchr(anf,
'\n');
559 if (ss==
NULL) len=strlen(anf);
562 strncpy(
s,anf,len+2);
658 Werror(
"premature end of file while reading %s",err);
667 #define STDIN_FILENO 0 676 p->files=freopen(
"/dev/tty",
"r",stdin);
const CanonicalForm int s
#define TRACE_SHOW_LINENO
char *(* fe_fgets_stdin)(const char *pr, char *s, int size)
static void feShowPrompt(void)
static int si_min(const int a, const int b)
size_t omSizeOfAddr(const void *addr)
BOOLEAN exitBuffer(feBufferTypes typ)
void sdb(Voice *currentVoice, const char *currLine, int len)
Voice * feInitStdin(Voice *pp)
static int fePrintEcho(char *anf, char *)
FILE * feFopen(const char *path, const char *mode, char *where, short useWerror, short path_only)
void PrintS(const char *s)
void myyoldbuffer(void *oldb)
void newBuffer(char *s, feBufferTypes t, procinfo *pi, int lineno)
BOOLEAN newFile(char *fname, FILE *f)
void omMarkAsStaticAddr(void *addr)
int feReadLine(char *b, int l)
void Werror(const char *fmt,...)
BOOLEAN contBuffer(feBufferTypes typ)