release-1.10release-1.4release-1.5release-1.6release-1.7release-1.8release-1.9
Last change
on this file since 3f6555d was
d7cc50b,
checked in by Anders Kaseorg <andersk@mit.edu>, 15 years ago
|
Death to more RCS keywords.
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
|
-
Property mode set to
100755
|
File size:
573 bytes
|
Line | |
---|
1 | #! /usr/bin/perl |
---|
2 | |
---|
3 | foreach $file (@ARGV) { |
---|
4 | open(FILE, $file); |
---|
5 | |
---|
6 | print "/* -------------------------------- $file -------------------------------- */\n"; |
---|
7 | while (<FILE>) { |
---|
8 | if (/^\S/ |
---|
9 | && (/\{\s*$/ || /\)\s*$/) |
---|
10 | && !/\}/ |
---|
11 | && !/^\{/ |
---|
12 | && !/^#/ |
---|
13 | && !/^static/ |
---|
14 | && !/^system/ |
---|
15 | && !/^XS/ |
---|
16 | && !/\/\*/ |
---|
17 | && !/ZWRITEOPTIONS/ |
---|
18 | && !/owlfaim_priv/) |
---|
19 | { |
---|
20 | |
---|
21 | s/\s+\{/\;/; |
---|
22 | s/\)[ \t]*$/\)\;/; |
---|
23 | print "extern "; |
---|
24 | print; |
---|
25 | } elsif (/^#if/ || /^#else/ || /^#endif/) { |
---|
26 | print; |
---|
27 | } |
---|
28 | |
---|
29 | } |
---|
30 | close(FILE); |
---|
31 | print "\n"; |
---|
32 | } |
---|
33 | |
---|
34 | |
---|
Note: See
TracBrowser
for help on using the repository browser.