Recovered from cvs revision 2007-08-24 13:17:00

This commit is contained in:
2007-08-25 01:06:00 +00:00
parent a2c56938e7
commit 24b4d82eea
5 changed files with 328 additions and 18 deletions

View File

@ -0,0 +1,34 @@
#
# generrcode-net.awk
#
# aseawk -f generrcode-net.awk awk.h
#
BEGIN {
collect=0;
tab3="\t\t";
tab4="\t\t\t";
}
/^[[:space:]]*enum[[:space:]]+ase_awk_errnum_t[[:space:]]*$/ {
collect=1;
print tab3 "// generated by generrcode-net.awk";
print tab3 "enum class ERROR: int";
print tab3 "{";
}
collect && /^[[:space:]]*};[[:space:]]*$/ {
print tab3 "};";
print tab3 "// end of enum class ERROR";
print "";
collect=0;
}
collect && /^[[:space:]]*ASE_AWK_E[[:alnum:]]+/ {
split ($1, flds, ",");
name=flds[1];
x = substr (name,10,length(name)-9);
print tab4 x " = ASE::Awk::ERR_" x ",";
}