changed literally nothing
This commit is contained in:
parent
2639d09a15
commit
402d69a0a6
|
@ -28,10 +28,29 @@
|
|||
(values id-sym seq))
|
||||
|
||||
;; idk yet
|
||||
(define-for-syntax (kaitai:process defn)
|
||||
(define-for-syntax (kaitai:process-ty defn [given-id #f])
|
||||
(pretty-write defn)
|
||||
(define-values [id seq] (get-id-seq defn #f))
|
||||
(define-values [id seqs] (get-id-seq defn given-id))
|
||||
|
||||
(for ([(name subty) (in-hash (hash-ref defn "types" (hash)))])
|
||||
(kaitai:process-ty subty name))
|
||||
|
||||
(struct context [] #:transparent)
|
||||
|
||||
(for/fold ([ctx (context)]) ([seq (in-list seqs)])
|
||||
(printf "seq: ~a\n" seq)
|
||||
|
||||
;; each seq element has an implicit dependency on the last seq's end position
|
||||
;; (the first seq depends on the parent element's start position)
|
||||
;; additionally each seq has a length expression calculated from its type
|
||||
|
||||
ctx)
|
||||
|
||||
(void))
|
||||
|
||||
;; top level process
|
||||
(define-for-syntax (kaitai:process defn)
|
||||
(kaitai:process-ty defn)
|
||||
(void))
|
||||
|
||||
;; runtime lib
|
||||
|
|
Loading…
Reference in New Issue