X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=vms%2Fvms_yfix.pl;h=fbeb0390c318921889180db7bf3ad39fe946db92;hb=19d75edaf35287dfc8bc9b6f13bb73a2ca28b226;hp=9f29c80825c1ee30989770949e64a2b3920840b1;hpb=71be2cbc73608e37e1a2ab7e459a02111137d1b0;p=p5sagit%2Fp5-mst-13.2.git diff --git a/vms/vms_yfix.pl b/vms/vms_yfix.pl index 9f29c80..fbeb039 100644 --- a/vms/vms_yfix.pl +++ b/vms/vms_yfix.pl @@ -6,7 +6,7 @@ # If it finds that the input files are already patches for VMS, # it just copies the input to the output. # -# Revised 20-Dec-1996 by Charles Bailey bailey@genetics.upenn.edu +# Revised 20-Dec-1996 by Charles Bailey bailey@newman.upenn.edu $VERSION = '1.11'; @@ -23,6 +23,15 @@ while () { # "y.tab.c" is illegal as a VMS filename; DECC 5.2/VAX preprocessor # doesn't like this. if ( s/^#line\s+(\d+)\s+"y.tab.c"/#line $1 "y_tab.c"/ ) { 1; } + elsif (/char \*getenv/) { + # accomodate old VAXC's macro susbstitution pecularities + $_ = "# ifndef getenv\n$_# endif\n"; + } + elsif ( /getenv\("YYDEBUG"\)/ ) { + # Reset the "error" status if an optional lookup fails + while (not /^\s+\}/) { print COUT; $_ = ; } + $_ .= "\telse SETERRNO(0,SS\$_NORMAL);\n"; + } else { # add the dEXT tag to definitions of global vars, so we'll insert # a globaldef when perly.c is compiled