Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
bksaiki committed Aug 26, 2024
1 parent 8f05291 commit 4e7ccd9
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/api/server.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@
(make-path job-id)))

(define (make-local-error-result herbie-result test job-id)
(define expr (prog->fpcore (test-input test)))
(define expr (prog->fpcore (test-input test) (test-context test)))
(define local-error (job-result-backend herbie-result))
;; TODO: potentially unsafe if resugaring changes the AST
(define tree
Expand Down
3 changes: 2 additions & 1 deletion src/platforms/runtime/libm.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@
(with-syntax ([op op]
[name name]
[cname cname]
[(var ...) (build-list (length itypes) (lambda (i) (string->symbol (format "x~a" i))))]
[(var ...) (build-list (length itypes)
(lambda (i) (string->symbol (format "x~a" i))))]
[(itype ...) itypes]
[(citype ...) (map repr->type itypes)]
[cotype (repr->type #'otype)])
Expand Down
5 changes: 4 additions & 1 deletion src/syntax/syntax.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,6 @@
[spec spec]
[core core]
[fl-expr fl-expr])
(eprintf "~a\n" #'(var ...))
#'(register-operator-impl! 'id
(context '(var ...)
(get-representation 'rtype)
Expand Down Expand Up @@ -427,6 +426,10 @@
(set! fl-expr #'expr)
(loop #'(rest ...))])]
[(#:fl) (oops! "expected value after keyword `#:fl`" stx)]
; deprecated
[(#:operator _ rest ...) (loop #'(rest ...))]
[(#:operator) (oops! "expected value after keyword `#:operator`" stx)]
; bad
[_ (oops! "bad syntax" fields)])))]
[_ (oops! "bad syntax")]))

Expand Down

0 comments on commit 4e7ccd9

Please sign in to comment.