==================
Directives only
==================

record Pair (A B : Set) : Set where
    constructor _,_
    inductive
    eta-equality

---

(source_file
    (record
        (record_name (qid))
        (typed_binding
            (atom (qid))
            (atom (qid))
            (expr (atom (SetN))))
        (expr (atom (SetN)))
        (record_declarations_block
            (record_constructor (id))
            (record_induction)
            (record_eta))))

==================
Directives with declarations I
==================

record Pair (A B : Set) : Set where
    constructor _,_
    inductive
    eta-equality
    instance
        a : b
    field
        fst : A
        snd : B

---

(source_file
    (record
        (record_name (qid))
        (typed_binding
            (atom (qid))
            (atom (qid))
            (expr (atom (SetN))))
        (expr (atom (SetN)))
        (record_declarations_block
            (record_constructor (id))
            (record_induction)
            (record_eta)
            (instance
                (function
                    (lhs (function_name (atom (qid))))
                    (rhs (expr (atom (qid))))))
            (fields
                (signature (field_name) (expr (atom (qid))))
                (signature (field_name) (expr (atom (qid))))))))

==================
Directives with declarations II
==================

record Pair (A B : Set) : Set where
    -- part of the directives
    instance
        constructor _,_
    -- NOT part of the directives
    instance
        a = b

---

(source_file
    (record
        (record_name (qid))
        (typed_binding
            (atom (qid))
            (atom (qid))
            (expr (atom (SetN))))
        (expr (atom (SetN)))
        (record_declarations_block
            (comment)
            (record_constructor_instance
              (record_constructor (id)))
            (comment)
            (instance
                (function
                    (lhs (atom (qid)))
                    (rhs (expr (atom (qid)))))))))
