Rationalised use of #includes to be more standards-compliant.
authordtrg <none@none>
Thu, 20 Jul 2006 23:04:15 +0000 (23:04 +0000)
committerdtrg <none@none>
Thu, 20 Jul 2006 23:04:15 +0000 (23:04 +0000)
util/opt/alloc.c
util/opt/getline.c
util/opt/lookup.c
util/opt/main.c
util/opt/mktab.y
util/opt/util.c

index ea90d3d..af154f2 100644 (file)
@@ -2,6 +2,7 @@
 static char rcsid[] = "$Id$";
 #endif
 
+#include <stdlib.h>
 #include <stdio.h>
 #include "param.h"
 #include "types.h"
@@ -427,7 +428,6 @@ coreinit() {
 
 short *myalloc(size) register size; {
        register short *p,*q;
-       extern char *malloc();
 
        p = (short *)malloc(size);
        if (p == 0)
index b3333ea..c3ed1bb 100644 (file)
@@ -2,6 +2,7 @@
 static char rcsid[] = "$Id$";
 #endif
 
+#include <stdlib.h>
 #include <stdio.h>
 #include "param.h"
 #include "types.h"
index aca6da9..dbe3f42 100644 (file)
@@ -2,6 +2,8 @@
 static char rcsid[] = "$Id$";
 #endif
 
+#include <stdlib.h>
+#include <string.h>
 #include "param.h"
 #include "types.h"
 #include "tes.h"
index 723464b..2990b22 100644 (file)
@@ -2,6 +2,7 @@
 static char rcsid[] = "$Id$";
 #endif
 
+#include <stdlib.h>
 #include <stdio.h>
 #include "param.h"
 #include "types.h"
index 836a490..d7cec71 100644 (file)
@@ -3,7 +3,9 @@
 static char rcsid[] = "$Id$";
 #endif
 
+#include <stdlib.h>
 #include <stdio.h>
+#include <string.h>
 #include "param.h"
 #include "types.h"
 #include "pattern.h"
@@ -57,18 +59,18 @@ int rplCBO;
 %left OR1
 %left XOR1
 %left AND1
-%left CMPEQ,CMPNE
-%left CMPLT,CMPLE,CMPGT,CMPGE
-%left RSHIFT,LSHIFT
-%left ARPLUS,ARMINUS
-%left ARTIMES,ARDIVIDE,ARMOD
-%nonassoc NOT,COMP,UMINUS
+%left CMPEQ CMPNE
+%left CMPLT CMPLE CMPGT CMPGE
+%left RSHIFT LSHIFT
+%left ARPLUS ARMINUS
+%left ARTIMES ARDIVIDE ARMOD
+%nonassoc NOT COMP UMINUS
 %nonassoc '$'
 
-%token SFIT,UFIT,NOTREG,PSIZE,WSIZE,DEFINED,SAMESIGN,ROM,ROTATE,STRING
+%token SFIT UFIT NOTREG PSIZE WSIZE DEFINED SAMESIGN ROM ROTATE STRING
 %token <y_int> MNEM
 %token <y_int> NUMBER
-%type <y_int> expr,argno,optexpr
+%type <y_int> expr argno optexpr
 
 %start patternlist
 
index a050867..9cc650c 100644 (file)
@@ -2,6 +2,7 @@
 static char rcsid[] = "$Id$";
 #endif
 
+#include <stdlib.h>
 #include <stdio.h>
 #include "param.h"
 #include "types.h"