This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Re: -Os for Darwin why?
[perl5.git] / keywords.pl
index acdf807..c804620 100755 (executable)
@@ -1,9 +1,25 @@
 #!/usr/bin/perl
 
-unlink "keywords.h";
+require 'regen.pl';
+safer_unlink ("keywords.h");
 open(KW, ">keywords.h") || die "Can't create keywords.h: $!\n";
 select KW;
 
+print <<EOM;
+/*
+ *    keywords.h
+ *
+ *    Copyright (c) 1997-2002, Larry Wall
+ *
+ *    You may distribute under the terms of either the GNU General Public
+ *    License or the Artistic License, as specified in the README file.
+ *
+ * !!!!!!!   DO NOT EDIT THIS FILE   !!!!!!!
+ *  This file is built by keywords.pl from its data.  Any changes made here
+ *  will be lost!
+ */
+EOM
+
 # Read & print data.
 
 $keynum = 0;
@@ -15,6 +31,8 @@ while (<DATA>) {
     print &tab(5, "#define KEY_$keyword"), $keynum++, "\n";
 }
 
+close KW or die "Error closing keywords.h: $!";
+
 ###########################################################################
 sub tab {
     local($l, $t) = @_;
@@ -35,14 +53,8 @@ BEGIN
 CORE
 DESTROY
 END
-EQ
-GE
-GT
 INIT
-LE
-LT
-NE
-STOP
+CHECK
 abs
 accept
 alarm
@@ -84,6 +96,7 @@ endpwent
 endservent
 eof
 eq
+err
 eval
 exec
 exists