• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • ACL2
    • Macro-libraries
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
      • Sv
      • Fgl
      • Vwsim
      • Vl
        • Syntax
        • Loader
          • Preprocessor
          • Vl-loadconfig
            • Vl-loadconfig-p
            • Vl-loadconfig-fix
            • Make-vl-loadconfig
            • Vl-loadconfig-clean
              • Vl-clean-search-extensions-aux
              • Vl-clean-search-extension
                • Vl-clean-search-extensions
              • Vl-loadconfig-equiv
              • Change-vl-loadconfig
              • Vl-loadconfig->include-dirs
              • Vl-loadconfig->start-names
              • Vl-loadconfig->start-files
              • Vl-loadconfig->search-path
              • Vl-loadconfig->search-exts
              • Vl-loadconfig->plusargs
              • Vl-loadconfig->flush-tries
              • Vl-loadconfig->strictp
              • Vl-loadconfig->mintime
              • Vl-loadconfig->filemapp
              • Vl-loadconfig->edition
              • Vl-loadconfig->defines
              • Vl-loadconfig->debugp
            • Vl-loadstate
            • Lexer
            • Parser
            • Vl-load-merge-descriptions
            • Vl-find-basename/extension
            • Vl-load-file
            • Vl-loadresult
            • Scope-of-defines
            • Vl-find-file
            • Vl-flush-out-descriptions
            • Vl-description
            • Vl-read-file
            • Vl-includeskips-report-gather
            • Vl-load-main
            • Extended-characters
            • Vl-load
            • Vl-load-description
            • Vl-descriptions-left-to-load
            • Inject-warnings
            • Vl-preprocess-debug
            • Vl-write-preprocessor-debug-file
            • Vl-read-file-report-gather
            • Vl-load-descriptions
            • Vl-load-files
            • Translate-off
            • Vl-load-read-file-hook
            • Vl-read-file-report
            • Vl-loadstate-pad
            • Vl-load-summary
            • Vl-collect-modules-from-descriptions
            • Vl-loadstate->warnings
            • Vl-iskips-report
            • Vl-descriptionlist
          • Warnings
          • Getting-started
          • Utilities
          • Printer
          • Kit
          • Mlib
          • Transforms
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Vl-loadconfig-clean

    Vl-clean-search-extension

    Normalize search extensions so that they don't have leading dots.

    Signature
    (vl-clean-search-extension searchext) → new-searchext
    Arguments
    searchext — Guard (stringp searchext).
    Returns
    new-searchext — Type (stringp new-searchext).

    This is a DWIM feature so that we can just do the right thing regardless of whether you say the search extensions are, e.g., ".sv" or just "sv".

    Definitions and Theorems

    Function: vl-clean-search-extension

    (defun vl-clean-search-extension (searchext)
      (declare (xargs :guard (stringp searchext)))
      (let ((__function__ 'vl-clean-search-extension))
        (declare (ignorable __function__))
        (b* ((searchext (string-fix searchext))
             (len (length searchext))
             ((when (and (< 0 len)
                         (eql (char searchext 0) #\.)))
              (subseq searchext 1 nil)))
          searchext)))

    Theorem: stringp-of-vl-clean-search-extension

    (defthm stringp-of-vl-clean-search-extension
      (b* ((new-searchext (vl-clean-search-extension searchext)))
        (stringp new-searchext))
      :rule-classes :type-prescription)