Instantiate map explicitly since it now infers less.
This commit is contained in:
parent
68d0930e88
commit
d19c82d152
37
proxy.rkt
37
proxy.rkt
|
@ -323,24 +323,25 @@
|
|||
(transition: w : QHState (send-message (answered-question q ans)))]
|
||||
[(partial-answer base cnames)
|
||||
(transition: (expanding-cnames q base (length cnames)) : QHState
|
||||
(map (lambda: ([cname : DomainName])
|
||||
;; TODO: record chains of CNAMEs to avoid pathologically-long chains
|
||||
(define cname-q (cname-question cname q))
|
||||
(list (send-message cname-q)
|
||||
(endpoint: (expanding-cnames q acc remaining) : QHState
|
||||
#:subscriber (answered-question-pattern cname-q (wild))
|
||||
#:let-name subscription-id
|
||||
[(answered-question (== cname-q) ans)
|
||||
(let ()
|
||||
(define new-acc (if ans (merge-answers acc ans) acc))
|
||||
(define new-remaining (- remaining 1))
|
||||
(define new-w (expanding-cnames q new-acc new-remaining))
|
||||
(transition: new-w : QHState
|
||||
(delete-endpoint subscription-id)
|
||||
(if (zero? new-remaining)
|
||||
(send-message (answered-question q new-acc))
|
||||
'())))])))
|
||||
cnames))])]))
|
||||
((inst map (ActionTree QHState) DomainName)
|
||||
(lambda: ([cname : DomainName])
|
||||
;; TODO: record chains of CNAMEs to avoid pathologically-long chains
|
||||
(define cname-q (cname-question cname q))
|
||||
(list (send-message cname-q)
|
||||
(endpoint: (expanding-cnames q acc remaining) : QHState
|
||||
#:subscriber (answered-question-pattern cname-q (wild))
|
||||
#:let-name subscription-id
|
||||
[(answered-question (== cname-q) ans)
|
||||
(let ()
|
||||
(define new-acc (if ans (merge-answers acc ans) acc))
|
||||
(define new-remaining (- remaining 1))
|
||||
(define new-w (expanding-cnames q new-acc new-remaining))
|
||||
(transition: new-w : QHState
|
||||
(delete-endpoint subscription-id)
|
||||
(if (zero? new-remaining)
|
||||
(send-message (answered-question q new-acc))
|
||||
'())))])))
|
||||
cnames))])]))
|
||||
|
||||
(require "test-rrs.rkt")
|
||||
(require racket/file)
|
||||
|
|
Loading…
Reference in New Issue