summaryrefslogtreecommitdiffstats
path: root/contrib/perl5/regcomp.pl
diff options
context:
space:
mode:
authormarkm <markm@FreeBSD.org>2000-06-25 11:04:01 +0000
committermarkm <markm@FreeBSD.org>2000-06-25 11:04:01 +0000
commit2618fad5bbb2d0182eb31ed805c41b543c513940 (patch)
tree52ba93338b13aefd02a0055304a9eccfa0e049f5 /contrib/perl5/regcomp.pl
parent77644ee620b6a79cf8c538abaf7cd301a875528d (diff)
downloadFreeBSD-src-2618fad5bbb2d0182eb31ed805c41b543c513940.zip
FreeBSD-src-2618fad5bbb2d0182eb31ed805c41b543c513940.tar.gz
Vendor import of Perl 5.006
Diffstat (limited to 'contrib/perl5/regcomp.pl')
-rw-r--r--contrib/perl5/regcomp.pl29
1 files changed, 25 insertions, 4 deletions
diff --git a/contrib/perl5/regcomp.pl b/contrib/perl5/regcomp.pl
index cfe59ad..d7d0733 100644
--- a/contrib/perl5/regcomp.pl
+++ b/contrib/perl5/regcomp.pl
@@ -21,7 +21,7 @@ open OUT, ">$tmp_h";
print OUT <<EOP;
/* !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
- This file is built by regcomp.pl from regcomp.sym.
+ This file is built by regcomp.pl from regcomp.sym.
Any changes made here will be lost!
*/
@@ -39,9 +39,9 @@ EOP
print OUT <<EOP;
#ifndef DOINIT
-EXTCONST U8 regkind[];
+EXTCONST U8 PL_regkind[];
#else
-EXTCONST U8 regkind[] = {
+EXTCONST U8 PL_regkind[] = {
EOP
$ind = 0;
@@ -79,7 +79,7 @@ EOP
$ind = 0;
while (++$ind <= $tot) {
$size = $longj[$ind] || 0;
-
+
print OUT <<EOP;
$size, /* $name[$ind] */
EOP
@@ -87,6 +87,27 @@ EOP
print OUT <<EOP;
};
+
+#ifdef DEBUGGING
+const static char * const reg_name[] = {
+EOP
+
+$ind = 0;
+while (++$ind <= $tot) {
+ $hind = sprintf "%#4x", $ind-1;
+ $size = $longj[$ind] || 0;
+
+ print OUT <<EOP;
+ "$name[$ind]", /* $hind */
+EOP
+}
+
+print OUT <<EOP;
+};
+
+const static int reg_num = $tot;
+
+#endif /* DEBUGGING */
#endif /* REG_COMP_C */
EOP
OpenPOWER on IntegriCloud