Skip to content

Commit

Permalink
imports: Fix relative module path hash-table key
Browse files Browse the repository at this point in the history
Using ->str was wrong; it fails for relative module paths
like (submod (lib "scribble/blueboxes.rkt") #%contract-defs).

The resulting error could be confusingly attributed to user code, for
example with racket-xp-mode reporting a error in our own
scribble.rkt, with a locus in ->str in imports.rkt.
  • Loading branch information
greghendershott committed Sep 29, 2024
1 parent 10a5f7c commit 325c14d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion racket/imports.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
(->* (syntax?) hash?)
(define ht (make-hash))
(define (update! rmp f)
(hash-update! ht (->str rmp) f (set)))
(hash-update! ht (~a (syntax->datum rmp)) f (set)))
(define (add! rmp v)
(update! rmp (λ (s) (set-add s (->str v)))))
(define (remove! rmp v)
Expand Down

0 comments on commit 325c14d

Please sign in to comment.