Skip to content

Commit df6eb1b

Browse files
rfindlerrmculpepper
authored andcommitted
fix a bug in executable creation
The code used eq? to check to see if a given language was in an list of allowed-to-create-executables languages. But the language object was passing thru TR and so eq? didn't hold and thus the check was buggy. (cherry picked from commit 2d2b3be)
1 parent f640c2c commit df6eb1b

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

collects/drracket/private/language-configuration.rkt

+5-3
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,11 @@
8585
(define languages null)
8686

8787
(define languages-allowing-executable-creation '())
88-
(define (language-allows-executable-creation? lang)
89-
(and (memq lang languages-allowing-executable-creation)
90-
#t))
88+
(define (language-allows-executable-creation? candidate-lang)
89+
(define candidates-positions (send candidate-lang get-language-position))
90+
(for/or ([allowed-lang (in-list languages-allowing-executable-creation)])
91+
(equal? (send allowed-lang get-language-position)
92+
candidates-positions)))
9193

9294
;; add-language : (instanceof language%) -> void
9395
;; only allows addition on phase2

0 commit comments

Comments
 (0)