This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
It's a good job that Steve Hay is paying attention.
[perl5.git] / keywords.pl
CommitLineData
a0d0e21e
LW
1#!/usr/bin/perl
2
d34f9d2e 3require 'regen_lib.pl';
c240c76d 4safer_unlink ("keywords.h");
a0d0e21e 5open(KW, ">keywords.h") || die "Can't create keywords.h: $!\n";
9ca8eaf1 6binmode KW;
a0d0e21e
LW
7select KW;
8
d6376244
JH
9print <<EOM;
10/*
11 * keywords.h
12 *
e6906430
JH
13 * Copyright (C) 1994, 1995, 1996, 1997, 1999, 2000, 2001, 2002,
14 * by Larry Wall and others
d6376244
JH
15 *
16 * You may distribute under the terms of either the GNU General Public
17 * License or the Artistic License, as specified in the README file.
18 *
5b7ea690
JH
19 * !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
20 * This file is built by keywords.pl from its data. Any changes made here
21 * will be lost!
d6376244
JH
22 */
23EOM
24
a0d0e21e
LW
25# Read & print data.
26
27$keynum = 0;
28while (<DATA>) {
29 chop;
30 next unless $_;
31 next if /^#/;
32 ($keyword) = split;
33 print &tab(5, "#define KEY_$keyword"), $keynum++, "\n";
34}
35
c240c76d
JH
36close KW or die "Error closing keywords.h: $!";
37
a0d0e21e
LW
38###########################################################################
39sub tab {
40 local($l, $t) = @_;
41 $t .= "\t" x ($l - (length($t) + 1) / 8);
42 $t;
43}
44###########################################################################
45__END__
46
47NULL
a0d0e21e 48__FILE__
68dc0745 49__LINE__
50__PACKAGE__
e50aee73 51__DATA__
a0d0e21e
LW
52__END__
53AUTOLOAD
54BEGIN
55CORE
56DESTROY
57END
7d07dbc2 58INIT
7d30b5c4 59CHECK
a0d0e21e
LW
60abs
61accept
62alarm
63and
64atan2
65bind
66binmode
67bless
68caller
69chdir
70chmod
71chomp
72chop
73chown
74chr
75chroot
76close
77closedir
78cmp
79connect
80continue
81cos
82crypt
83dbmclose
84dbmopen
85defined
86delete
87die
88do
89dump
90each
91else
92elsif
93endgrent
94endhostent
95endnetent
96endprotoent
97endpwent
98endservent
99eof
100eq
101eval
102exec
103exists
104exit
105exp
106fcntl
107fileno
108flock
109for
110foreach
111fork
112format
113formline
114ge
115getc
116getgrent
117getgrgid
118getgrnam
119gethostbyaddr
120gethostbyname
121gethostent
122getlogin
123getnetbyaddr
124getnetbyname
125getnetent
126getpeername
127getpgrp
128getppid
129getpriority
130getprotobyname
131getprotobynumber
132getprotoent
133getpwent
134getpwnam
135getpwuid
136getservbyname
137getservbyport
138getservent
139getsockname
140getsockopt
141glob
142gmtime
143goto
144grep
145gt
146hex
147if
148index
149int
150ioctl
151join
152keys
153kill
154last
155lc
156lcfirst
157le
158length
159link
160listen
161local
162localtime
c0329465 163lock
a0d0e21e
LW
164log
165lstat
166lt
167m
168map
169mkdir
170msgctl
171msgget
172msgrcv
173msgsnd
174my
175ne
176next
177no
178not
179oct
180open
181opendir
182or
183ord
77ca0c92 184our
a0d0e21e
LW
185pack
186package
187pipe
188pop
189pos
190print
191printf
c07a80fd 192prototype
a0d0e21e
LW
193push
194q
195qq
8782bef2 196qr
a0d0e21e
LW
197quotemeta
198qw
199qx
200rand
201read
202readdir
203readline
204readlink
205readpipe
206recv
207redo
208ref
209rename
210require
211reset
212return
213reverse
214rewinddir
215rindex
216rmdir
217s
218scalar
219seek
220seekdir
221select
222semctl
223semget
224semop
225send
226setgrent
227sethostent
228setnetent
229setpgrp
230setpriority
231setprotoent
232setpwent
233setservent
234setsockopt
235shift
236shmctl
237shmget
238shmread
239shmwrite
240shutdown
241sin
242sleep
243socket
244socketpair
245sort
246splice
247split
248sprintf
249sqrt
250srand
251stat
252study
253sub
254substr
255symlink
256syscall
c07a80fd 257sysopen
a0d0e21e 258sysread
137443ea 259sysseek
a0d0e21e
LW
260system
261syswrite
262tell
263telldir
264tie
c07a80fd 265tied
a0d0e21e
LW
266time
267times
268tr
269truncate
270uc
271ucfirst
272umask
273undef
274unless
275unlink
276unpack
277unshift
278untie
279until
280use
281utime
282values
283vec
284wait
285waitpid
286wantarray
287warn
288while
289write
290x
291xor
292y