summaryrefslogtreecommitdiff
path: root/x2p
diff options
context:
space:
mode:
Diffstat (limited to 'x2p')
-rw-r--r--x2p/a2p.h7
-rw-r--r--x2p/walk.c13
2 files changed, 12 insertions, 8 deletions
diff --git a/x2p/a2p.h b/x2p/a2p.h
index eede53d27f..b7bc1f19c9 100644
--- a/x2p/a2p.h
+++ b/x2p/a2p.h
@@ -1,6 +1,9 @@
-/* $Header: a2p.h,v 1.0.1.1 88/01/26 09:52:30 root Exp $
+/* $Header: a2p.h,v 1.0.1.2 88/02/01 17:33:40 root Exp $
*
* $Log: a2p.h,v $
+ * Revision 1.0.1.2 88/02/01 17:33:40 root
+ * patch12: forgot to fix #define YYDEBUG; bug in a2p.
+ *
* Revision 1.0.1.1 88/01/26 09:52:30 root
* patch 5: a2p didn't use config.h.
*
@@ -226,7 +229,7 @@ EXT int expectterm INIT(TRUE);
#ifdef DEBUGGING
EXT int debug INIT(0);
EXT int dlevel INIT(0);
-#define YYDEBUG;
+#define YYDEBUG 1
extern int yydebug;
#endif
diff --git a/x2p/walk.c b/x2p/walk.c
index e745510b1d..e81a9fd8de 100644
--- a/x2p/walk.c
+++ b/x2p/walk.c
@@ -1,6 +1,9 @@
-/* $Header: walk.c,v 1.0.1.1 88/01/28 11:07:56 root Exp $
+/* $Header: walk.c,v 1.0.1.2 88/02/01 17:34:05 root Exp $
*
* $Log: walk.c,v $
+ * Revision 1.0.1.2 88/02/01 17:34:05 root
+ * patch12: made a2p take advantage of new awk-compatible split in perl.
+ *
* Revision 1.0.1.1 88/01/28 11:07:56 root
* patch8: changed some misleading comments.
*
@@ -71,7 +74,7 @@ int *numericptr;
str_cat(str,"';\t\t# field separator from -F switch\n");
}
else if (saw_FS && !const_FS) {
- str_cat(str,"$FS = '[ \\t\\n]+';\t\t# set field separator\n");
+ str_cat(str,"$FS = ' ';\t\t# set field separator\n");
}
if (saw_OFS) {
str_cat(str,"$, = ' ';\t\t# set output field separator\n");
@@ -361,8 +364,6 @@ sub Pick {\n\
str_scat(str,fstr=walk(1,level,ops[node+3].ival,&numarg));
str_free(fstr);
numeric |= numarg;
- if (strEQ(str->str_ptr,"$FS = '\240'"))
- str_set(str,"$FS = '[\240\\n\\t]+'");
break;
case OADD:
str = walk(1,level,ops[node+1].ival,&numarg);
@@ -511,7 +512,7 @@ sub Pick {\n\
else if (saw_FS)
str_cat(str,"$FS");
else
- str_cat(str,"/[ \\t\\n]+/");
+ str_cat(str,"' '");
str_cat(str,", ");
str_scat(str,fstr=walk(1,level,ops[node+1].ival,&numarg));
str_free(fstr);
@@ -1095,7 +1096,7 @@ int level;
else if (saw_FS)
str_cat(str," = split($FS);\n");
else
- str_cat(str," = split;\n");
+ str_cat(str," = split(' ');\n");
tab(str,level);
}