I am trying to make R6RS Infix run under Sagittarius 0.5.3 on a x84_64-unknown-linux-gnu. The package includes .sagittarius.sls libraries. After package configuration, running "make srun" will run "sash" with a system environment that allows loading the uninstalled libraries with "(import (infix pratt))" and "(import (infix lalr)".
Basically the package works, only some tests (marked by comments in "tests/infix-test/tests.sls") do not work; for example:
(infix 'a eq? 'a)
Specifically, all the tests for which the parser (in the function "flatten") has to compare the identifiers QUOTE, QUASIQUOTE, etc from the input form with the same imported in the library environment fail; the failing code is:
(define (flatten stx synner) ;;Given a syntax object STX representing an input expression: decompose it into ;;a flat list of raw tokens and return the list holding the raw tokens in ;;reverse order. We expect the list to contain: atoms as defined by the ;;function ATOM?; identifiers; the characters open parenthesis, close ;;parenthesis and comma. ;; (syntax-case stx (begin quote quasiquote syntax quasisyntax unquote) (() '()) ((quote . ?stuff) stx) ((quasiquote . ?stuff) stx) ((syntax . ?stuff) stx) ((quasisyntax . ?stuff) stx) ((unquote . ?stuff) (append (flatten #'?stuff synner) (list #\,))) ((begin . ?stuff) stx)
these SYNTAX-CASE clauses fail to match the literal identifiers.