File tree Expand file tree Collapse file tree 2 files changed +7
-10
lines changed Expand file tree Collapse file tree 2 files changed +7
-10
lines changed Original file line number Diff line number Diff line change 224224 ;; extracts the base expressions of a patch as a batchref
225225 (define (get-starting-expr altn)
226226 (match* ((alt-event altn) (alt-prevs altn))
227- [((list 'patch expr _ ) _ ) expr] ; here original Expr can be pulled as well
227+ [((list 'patch expr _ ) _ ) expr]
228228 [(_ (list prev)) (get-starting-expr prev)]
229229 [(_ _ ) (error 'get-starting-spec "unexpected: ~a " altn)]))
230230
Original file line number Diff line number Diff line change 7272
7373 ; run egg
7474 (define simplified
75- (map debatchref
76- (simplify- batch runner
77- (typed -egg-batch-extractor
78- ( if (*egraph-platform-cost*) platform-egg-cost-proc default-egg-cost-proc)
79- batch))))
75+ (debatchref (car (simplify-batch runner
76+ (typed-egg- batch-extractor ( if (*egraph-platform-cost*)
77+ platform -egg-cost-proc
78+ default-egg-cost-proc)
79+ batch) ))))
8080
8181 ; alternatives
8282 (define start-alt (make-alt expr))
83- (cons start-alt
84- (remove-duplicates (for/list ([expr simplified])
85- (alt expr `(simplify () ,runner #f #f ) (list start-alt) '() ))
86- alt-equal?)))
83+ (cons start-alt (list (alt simplified `(simplify () ,runner #f #f ) (list start-alt) '() ))))
8784
8885;; See https://pavpanchekha.com/blog/symmetric-expressions.html
8986(define (find-preprocessing init expr ctx)
You can’t perform that action at this time.
0 commit comments