summaryrefslogtreecommitdiff
path: root/includes/spyc/php4/5to4.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/spyc/php4/5to4.php')
-rw-r--r--includes/spyc/php4/5to4.php16
1 files changed, 0 insertions, 16 deletions
diff --git a/includes/spyc/php4/5to4.php b/includes/spyc/php4/5to4.php
deleted file mode 100644
index 2789620..0000000
--- a/includes/spyc/php4/5to4.php
+++ /dev/null
@@ -1,16 +0,0 @@
-<?php
-
-php5to4 ("../spyc.php", 'spyc-latest.php4');
-
-function php5to4 ($src, $dest) {
- $code = file_get_contents ($src);
- $code = preg_replace ('#(public|private|protected)\s+\$#i', 'var \$', $code);
- $code = preg_replace ('#(public|private|protected)\s+static\s+\$#i', 'var \$', $code);
- $code = preg_replace ('#(public|private|protected)\s+function#i', 'function', $code);
- $code = preg_replace ('#(public|private|protected)\s+static\s+function#i', 'function', $code);
- $code = str_replace ('self::', '$this->', $code);
- $f = fopen ($dest, 'w');
- fwrite($f, $code);
- fclose ($f);
- print "Written to $dest.\n";
-} \ No newline at end of file