diff options
Diffstat (limited to 'php/step8_macros.php')
| -rw-r--r-- | php/step8_macros.php | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/php/step8_macros.php b/php/step8_macros.php index 20e0f6a..28014cd 100644 --- a/php/step8_macros.php +++ b/php/step8_macros.php @@ -158,13 +158,10 @@ _ref('eval', function($ast) { _ref('slurp', function($f) { return file_get_contents($f); }); -_ref('slurp-do', function($f) { - return "(do " . file_get_contents($f) . ")"; -}); // Defined using the language itself rep("(def! not (fn* (a) (if a false true)))"); -rep("(def! load-file (fn* (f) (eval (read-string (slurp-do f)))))"); +rep("(def! load-file (fn* (f) (eval (read-string (str \"(do \" (slurp f) \")\")))))"); if (count($argv) > 1) { for ($i=1; $i < count($argv); $i++) { |
