*** empty log message ***
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* $Id: awk.c,v 1.78 2006-08-28 14:30:08 bacon Exp $
|
||||
* $Id: awk.c,v 1.79 2006-08-30 07:15:14 bacon Exp $
|
||||
*/
|
||||
|
||||
#include <xp/awk/awk.h>
|
||||
@ -567,7 +567,8 @@ static int __main (int argc, xp_char_t* argv[])
|
||||
return -1;
|
||||
}
|
||||
|
||||
opt = XP_AWK_EXPLICIT | XP_AWK_UNIQUE | XP_AWK_DBLSLASHES |
|
||||
opt = XP_AWK_EXPLICIT | XP_AWK_UNIQUE | XP_AWK_HASHSIGN |
|
||||
/*XP_AWK_DBLSLASHES |*/
|
||||
XP_AWK_SHADING | XP_AWK_IMPLICIT | XP_AWK_SHIFT |
|
||||
XP_AWK_EXTIO | XP_AWK_BLOCKLESS | XP_AWK_STRINDEXONE;
|
||||
|
||||
|
@ -19,7 +19,8 @@ int xp_main (int argc, const xp_char_t* argv[])
|
||||
//ptn = XP_T("^he.llo(jo(in|kk)s|com)+h*e{1,40}abc|[^abc][de-f]|^he.llo(jo(in|kk)s|com)+h*e{1,40}abc|[^abc][de-f]");
|
||||
//ptn = XP_T("^he.llo(jo(in|kk)s|com)+h*e{1,40}abc|[^abc][de-f]");
|
||||
//ptn = XP_T("^he.llo(jo(in|kk)s|com)|[^x[:space:][:alpha:]j][^abc][de-f]|^he.llo(jo(in|kk)s|com)|[^x[:space:][:alpha:]j][^abc][de-f]");
|
||||
ptn = XP_T("^.{0,2}.z[^[:space:]]+(abc|zzz){1,2}khg");
|
||||
//ptn = XP_T("^.{0,2}.z[^[:space:]]+(abc|zzz){1,2}khg");
|
||||
ptn = XP_T("");
|
||||
|
||||
rex = xp_awk_buildrex (ptn, xp_strlen(ptn), &errnum);
|
||||
if (rex == XP_NULL)
|
||||
@ -28,6 +29,7 @@ int xp_main (int argc, const xp_char_t* argv[])
|
||||
return -1;
|
||||
}
|
||||
|
||||
xp_printf (XP_T("isemptyrex => %d\n"), xp_awk_isemptyrex (rex));
|
||||
xp_printf (XP_T("NA: %u\n"), (unsigned int)XP_AWK_REX_NA(rex));
|
||||
xp_printf (XP_T("LEN: %u\n"), (unsigned int)XP_AWK_REX_LEN(rex));
|
||||
xp_awk_printrex (rex);
|
||||
|
@ -1,2 +1,2 @@
|
||||
BEGIN { /*RS = "Asia";*/ /*RS=746;*/ RS=/USA/; }
|
||||
{ print "RECORD: ", $0; }
|
||||
BEGIN { /*RS = "Asia";*/ /*RS=746;*/ /*RS="";*/ RS=/USA/; }
|
||||
{ print NR, " ", $0; }
|
||||
|
@ -5,7 +5,7 @@ BEGIN {
|
||||
delete NF;
|
||||
print "NF[1]=", NF[1];
|
||||
|
||||
NF[1] = 20; // this line should not be allowed
|
||||
NF[1] = 20; # this line should not be allowed
|
||||
print "AWK IMPLEMENTATION ERROR: hey... NF[1] = 20 has succeeded in the BEGIN block. your interpreter must be wrong";
|
||||
print "NF[1]=", NF[1];
|
||||
}
|
||||
|
Reference in New Issue
Block a user