summaryrefslogtreecommitdiff
path: root/input.h
diff options
context:
space:
mode:
authorToby Goodwin <LibreSoftwareDesign@gmail.com>2012-10-01 20:46:40 +0100
committerToby Goodwin <toby@paccrat.org>2015-05-16 21:23:24 +0100
commitc8a77b86b4f8c91314222a8e12e6e37cf182ee10 (patch)
tree770041514630af2c076e5115b3543b7f5ced1d24 /input.h
parent27c900d6ae9cd0dcf4bc97bc9b8c1882e40ccfa8 (diff)
initial commit
Diffstat (limited to 'input.h')
-rw-r--r--input.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/input.h b/input.h
new file mode 100644
index 0000000..87db27b
--- /dev/null
+++ b/input.h
@@ -0,0 +1,35 @@
+/* initialize the input stack */
+extern void initinput(void);
+
+/* push an input onto the stack */
+extern void pushfd(int);
+/* the Boolean argument affects line number reporting */
+extern void pushstring(char **, bool);
+
+/* pop the stack */
+extern void popinput(void);
+
+/* get / unget the next character */
+extern int gchar(void);
+extern void ugchar(int);
+
+/* $TERM or $TERMCAP has changed */
+extern void termchange(void);
+
+/* parse a function from the environment */
+extern Node *parseline(char *);
+
+/* main parsing loop; Boolean says whether to exec also */
+extern Node *doit(bool);
+
+/* error recovery: skip to the next newline */
+extern void skiptonl(void);
+
+/* prepare for next line of input */
+extern void nextline(void);
+
+/* close all file descriptors on the stack */
+extern void closefds(void);
+
+/* the last character read */
+extern int lastchar;