Attempt to get arrows drawn from a mixin's declaration to its (~no-order (~mixin m)). Not enough, it still doesn't work.

This commit is contained in:
Georges Dupéron 2016-08-31 22:24:30 +02:00
parent 8ef335bcd4
commit c7fd8ed550
2 changed files with 8 additions and 4 deletions

View File

@ -1,11 +1,14 @@
#lang racket #lang racket
(require "no-order.rkt" (require "no-order.rkt"
(for-syntax syntax/parse)) (for-syntax syntax/parse
racket/syntax))
(provide ~mixin) (provide ~mixin)
(define-eh-mixin-expander ~mixin (define-eh-mixin-expander ~mixin
(syntax-parser (syntax-parser
[(_ (~var mixin (static eh-mixin-expander? "an eh-mixin expander"))) [(_ (~var mixin (static eh-mixin-expander? "an eh-mixin expander")))
#'(mixin)])) (with-disappeared-uses
(record-disappeared-uses #'mixin)
#'(mixin))]))

View File

@ -60,7 +60,8 @@
(parameterize ([eh-post-accumulate add-to-post!] (parameterize ([eh-post-accumulate add-to-post!]
[eh-post-group add-to-post-groups!] [eh-post-group add-to-post-groups!]
[clause-counter increment-counter]) [clause-counter increment-counter])
(inline-or (expand-all-eh-mixin-expanders #'(~or pat ...))))) ;(inline-or
(expand-all-eh-mixin-expanders #'(~or pat ...))))
(define post-group-bindings (define post-group-bindings
(for/list ([group (group-by car (for/list ([group (group-by car
post-groups-acc post-groups-acc
@ -75,7 +76,7 @@
#`[name (f . #,(map (λ (i) #`(attribute #,(third i))) #`[name (f . #,(map (λ (i) #`(attribute #,(third i)))
group))])) group))]))
#`(~delimit-cut #`(~delimit-cut
(~and (~seq (~or . #,alts) (... ...)) (~and (~seq #,alts (... ...)) ;;(~or . #,alts)
~! ~!
(~bind #,@post-group-bindings) (~bind #,@post-group-bindings)
#,@post-acc))))])))) #,@post-acc))))]))))