1. Cat's Eye Technologies
  2. Pixley

Commits

Cat's Eye Technologies  committed 0c10694

Fix same env bug as in mignon. Hooray, haney supports the tower!

  • Participants
  • Parent commits 7eeaccf
  • Branches default

Comments (0)

Files changed (2)

File impl/haney/Pixley.lhs

View file
 > eval env (Cons fun actuals) =
 >     case eval env fun of
 >         Lambda closedEnv formals body ->
->             eval (bindArgs closedEnv formals actuals) body
+>             eval (bindArgs env closedEnv formals actuals) body
 >         Macro closedEnv body ->
 >             let
 >                 env' = Map.insert "arg" actuals closedEnv
 > bind (Cons (Symbol sym) (Cons sexpr Null)) env =
 >     Map.insert sym (eval env sexpr) env
 
-> bindArgs env Null Null =
->     env
-> bindArgs env (Cons (Symbol sym) formals) (Cons actual actuals) =
->     Map.insert sym (eval env actual) (bindArgs env formals actuals)
+> bindArgs env closedEnv Null Null =
+>     closedEnv
+> bindArgs env closedEnv (Cons (Symbol sym) formals) (Cons actual actuals) =
+>     Map.insert sym (eval env actual) (bindArgs env closedEnv formals actuals)
 
 > consFromEnvList [] =
 >     Null

File test.sh

View file
 falderal test config.markdown src/tests.markdown
 
 
-echo "Testing Pixley programs on [${PIXLEY_IMPL}] (directly)..."
+echo "Testing Pixley programs on [${PIXLEY_IMPL}] (via scheme-adapter.sh)..."
 cat >config.markdown <<EOF
     -> Functionality "Interpret Pixley Program" is implemented by shell command
-    -> "impl/${PIXLEY_IMPL}/${PIXLEY_IMPL} '%(test-file)'"
+    -> "SCHEME_IMPL=${PIXLEY_IMPL} script/scheme-adapter.sh /dev/null %(test-file)"
 EOF
 falderal test config.markdown src/tests.markdown
 
 
-#echo "Testing Pixley programs on [${PIXLEY_IMPL}] (directly)..."
-#cat >config.markdown <<EOF
-#    -> Functionality "Interpret Pixley Program" is implemented by shell command
-#    -> "impl/${PIXLEY_IMPL}/${PIXLEY_IMPL} '%(test-text)'"
-#EOF
-#falderal test config.markdown src/tests.markdown
-
-
 echo "Testing Pixley programs on [${PIXLEY_IMPL}] (via tower.sh)..."
 cat >config.markdown <<EOF
     -> Functionality "Interpret Pixley Program" is implemented by shell command