• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
      • Kestrel-books
      • X86isa
      • Axe
      • Execloader
        • Elf-reader
        • Mach-o-reader
        • Merge-first-split-bytes
        • Split-bytes
        • Take-till-zero
        • Charlist->bytes
        • Merge-bytes
        • Bytes->charlist
        • String->bytes
        • Bytes->string
      • Math
      • Testing-utilities
    • Execloader

    Bytes->string

    Convert a list of bytes to a string.

    Signature
    (bytes->string bytes) → str
    Arguments
    bytes — Guard (byte-listp bytes).
    Returns
    str — Type (stringp str), given the guard.

    Definitions and Theorems

    Function: bytes->string

    (defun bytes->string (bytes)
      (declare (xargs :guard (byte-listp bytes)))
      (let ((__function__ 'bytes->string))
        (declare (ignorable __function__))
        (coerce (bytes->charlist bytes)
                'string)))

    Theorem: stringp-of-bytes->string

    (defthm stringp-of-bytes->string
      (implies (and (byte-listp bytes))
               (b* ((str (bytes->string bytes)))
                 (stringp str)))
      :rule-classes :rewrite)