• Top
    • Documentation
    • Books
    • Recursion-and-induction
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
      • Io
      • Defttag
      • Sys-call
      • Save-exec
      • Quicklisp
      • Oslib
      • Std/io
      • Bridge
      • Clex
        • Example-lexer
          • Token-p
          • Lex-punctuation
          • Lex-id/keyword
          • Lex-string
          • Lex-comment
          • Lex-whitespace
          • Lex1
          • Lex-main
          • Lex*
          • Tokenlist-p
            • Tokenlist-p-basics
          • Idtail-char-p
          • Letter-char-p
          • Whitespace-char-p
          • Number-char-p
          • Tokentype-p
          • Lex*-exec
          • Newline-string
        • Sin
        • Matching-functions
        • Def-sin-progress
      • Tshell
      • Unsound-eval
      • Hacker
      • Startup-banner
      • Command-line
    • Hardware-verification
    • Software-verification
    • Testing-utilities
    • Math
  • Example-lexer

Tokenlist-p

(tokenlist-p x) recognizes lists where every element satisfies token-p.

Signature
(tokenlist-p x) → std::bool

This is an ordinary deflist. It is "loose" in that it does not care whether x is nil-terminated.

Definitions and Theorems

Function: tokenlist-p

(defun tokenlist-p (x)
       (declare (xargs :guard t))
       (let ((__function__ 'tokenlist-p))
            (declare (ignorable __function__))
            (if (consp x)
                (and (token-p (car x))
                     (tokenlist-p (cdr x)))
                t)))

Subtopics

Tokenlist-p-basics
Basic theorems about tokenlist-p, generated by deflist.