1f2d37758SMatthew Dillon /* 2db555d9aSPeter Avalos * $OpenBSD: extern.h,v 1.6 2006/03/18 20:44:43 otto Exp $ 3f2d37758SMatthew Dillon */ 4f2d37758SMatthew Dillon 5f2d37758SMatthew Dillon /* 6f2d37758SMatthew Dillon * Copyright (c) 2003, Otto Moerbeek <otto@drijf.net> 7f2d37758SMatthew Dillon * 8f2d37758SMatthew Dillon * Permission to use, copy, modify, and distribute this software for any 9f2d37758SMatthew Dillon * purpose with or without fee is hereby granted, provided that the above 10f2d37758SMatthew Dillon * copyright notice and this permission notice appear in all copies. 11f2d37758SMatthew Dillon * 12f2d37758SMatthew Dillon * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 13f2d37758SMatthew Dillon * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 14f2d37758SMatthew Dillon * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 15f2d37758SMatthew Dillon * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 16f2d37758SMatthew Dillon * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 17f2d37758SMatthew Dillon * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 18f2d37758SMatthew Dillon * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 19f2d37758SMatthew Dillon */ 20f2d37758SMatthew Dillon 21cb7e3b3cSJoris Giovannangeli #include <stdbool.h> 22f2d37758SMatthew Dillon #include <stdio.h> 23f2d37758SMatthew Dillon 24f2d37758SMatthew Dillon struct lvalue { 25f2d37758SMatthew Dillon ssize_t load; 26f2d37758SMatthew Dillon ssize_t store; 27f2d37758SMatthew Dillon }; 28f2d37758SMatthew Dillon 29cb7e3b3cSJoris Giovannangeli struct termios; 30cb7e3b3cSJoris Giovannangeli 31f2d37758SMatthew Dillon int yylex(void); 32f2d37758SMatthew Dillon void yyerror(char *); 33*6d08986dSSascha Wildner void fatal(const char *) __dead2; 34f2d37758SMatthew Dillon void abort_line(int); 35cb7e3b3cSJoris Giovannangeli int gettty(struct termios *); 36cb7e3b3cSJoris Giovannangeli void tstpcont(int); 37cb7e3b3cSJoris Giovannangeli unsigned char bc_eof(EditLine *, int); 38f2d37758SMatthew Dillon 39f2d37758SMatthew Dillon extern int lineno; 40f2d37758SMatthew Dillon extern char *yytext; 41f2d37758SMatthew Dillon extern FILE *yyin; 42b6d9cda5SSascha Wildner extern int fileindex; 43b6d9cda5SSascha Wildner extern int sargc; 44b6d9cda5SSascha Wildner extern char **sargv; 45b6d9cda5SSascha Wildner extern char *filename; 46b6d9cda5SSascha Wildner extern char *cmdexpr; 47cb7e3b3cSJoris Giovannangeli extern struct termios ttysaved; 48ac3cc18cSSascha Wildner extern bool interactive; 49ac3cc18cSSascha Wildner extern EditLine *el; 50ac3cc18cSSascha Wildner extern History *hist; 51ac3cc18cSSascha Wildner extern HistEvent he; 52