diff options
author | stefanf <stefanf@FreeBSD.org> | 2005-08-13 07:54:23 +0000 |
---|---|---|
committer | stefanf <stefanf@FreeBSD.org> | 2005-08-13 07:54:23 +0000 |
commit | f509d2ea20743f72d13b03c77c8c0872cec49304 (patch) | |
tree | c80db9f7e0ddd55d58581b169c3ddda22a56199f /bin | |
parent | d0e833a8a7c2047711efdf3ea08308aea8847f02 (diff) | |
download | FreeBSD-src-f509d2ea20743f72d13b03c77c8c0872cec49304.zip FreeBSD-src-f509d2ea20743f72d13b03c77c8c0872cec49304.tar.gz |
cvs -d stefanf@ncvs.FreeBSD.org:/home/ncvs
Diffstat (limited to 'bin')
-rw-r--r-- | bin/sh/arith.h | 4 | ||||
-rw-r--r-- | bin/sh/arith.y | 6 | ||||
-rw-r--r-- | bin/sh/arith_lex.l | 4 |
3 files changed, 9 insertions, 5 deletions
diff --git a/bin/sh/arith.h b/bin/sh/arith.h index 079f957..ed5773b 100644 --- a/bin/sh/arith.h +++ b/bin/sh/arith.h @@ -30,6 +30,8 @@ * $FreeBSD$ */ +extern char *arith_buf, *arith_startbuf; + int arith(char *); -int arith_assign(char *, arith_t); +void arith_lex_reset(void); int expcmd(int, char **); diff --git a/bin/sh/arith.y b/bin/sh/arith.y index a7b514d..391cc16 100644 --- a/bin/sh/arith.y +++ b/bin/sh/arith.y @@ -43,6 +43,7 @@ __FBSDID("$FreeBSD$"); #include <limits.h> #include <stdio.h> +#include "arith.h" #include "shell.h" #include "var.h" %} @@ -261,12 +262,11 @@ expr: #define lstrlen(var) (3 + (2 + CHAR_BIT * sizeof((var))) / 3) char *arith_buf, *arith_startbuf; -extern void arith_lex_reset(); int yylex(void); int yyparse(void); -int +static int arith_assign(char *name, arith_t value) { char *str; @@ -294,7 +294,7 @@ arith(char *s) return result; } -void +static void yyerror(char *s) { diff --git a/bin/sh/arith_lex.l b/bin/sh/arith_lex.l index 4e7b7fb..f0ed3d5 100644 --- a/bin/sh/arith_lex.l +++ b/bin/sh/arith_lex.l @@ -42,13 +42,15 @@ __FBSDID("$FreeBSD$"); #include <string.h> +#include "arith.h" #include "shell.h" #include "y.tab.h" #include "error.h" #include "memalloc.h" #include "var.h" -extern char *arith_buf, *arith_startbuf; +int yylex(void); + #undef YY_INPUT #define YY_INPUT(buf,result,max) \ result = (*buf = *arith_buf++) ? 1 : YY_NULL; |