• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
      • Abnf
        • Deftreeops
        • Defdefparse
        • Defgrammar
        • Tree-utilities
        • Notation
          • Syntax-abstraction
          • Semantics
          • Abstract-syntax
          • Core-rules
          • Concrete-syntax
            • Parse-grammar*
            • Core-rules
            • Concrete-syntax-validation
              • *grammar*
              • Concrete-syntax-rules
          • Grammar-parser
          • Meta-circular-validation
          • Parsing-primitives-defresult
          • Parsing-primitives-seq
          • Operations
          • Examples
          • Differences-with-paper
          • Constructor-utilities
          • Grammar-printer
          • Parsing-tools
        • Vwsim
        • Isar
        • Wp-gen
        • Dimacs-reader
        • Pfcs
        • Legacy-defrstobj
        • Proof-checker-array
        • Soft
        • C
        • Farray
        • Rp-rewriter
        • Instant-runoff-voting
        • Imp-language
        • Sidekick
        • Leftist-trees
        • Java
        • Taspi
        • Bitcoin
        • Riscv
        • Des
        • Ethereum
        • X86isa
        • Sha-2
        • Yul
        • Zcash
        • Proof-checker-itp13
        • Regex
        • ACL2-programming-language
        • Json
        • Jfkr
        • Equational
        • Cryptography
        • Poseidon
        • Where-do-i-place-my-book
        • Axe
        • Bigmems
        • Builtins
        • Execloader
        • Aleo
        • Solidity
        • Paco
        • Concurrent-programs
        • Bls12-377-curves
      • Debugging
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Concrete-syntax

    Concrete-syntax-validation

    Validation of the concrete syntax grammar.

    We show that rules of the grammar of the ABNF concrete syntax:

    • Are well-formed.
    • Are closed.
    • Generate only strings of ASCII codes.
    • Are the same (module ordering) as the resulting of plugging the core rules into the concrete syntax rules.

    These theorems are in a separate file so that the definition of the concrete syntax does not depend on the grammar operations, as also done for core-rules-validation and for concrete-syntax-rules-validation.

    Definitions and Theorems

    Theorem: rulelist-wfp-of-*grammar*

    (defthm rulelist-wfp-of-*grammar*
      (rulelist-wfp *grammar*))

    Theorem: rulelist-closedp-of-*grammar*

    (defthm rulelist-closedp-of-*grammar*
      (rulelist-closedp *grammar*))

    Theorem: ascii-only-*grammar*

    (defthm ascii-only-*grammar*
      (rulelist-in-termset-p *grammar* (integers-from-to 0 127)))

    Theorem: plugging-yields-*grammar*

    (defthm plugging-yields-*grammar*
      (set-equiv (plug-rules *concrete-syntax-rules* *core-rules*)
                 *grammar*))