• Top
    • Documentation
    • Books
    • Recursion-and-induction
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
      • Theories
      • Rule-classes
      • Proof-builder
      • Hons-and-memoization
      • Events
      • History
      • Parallelism
      • Programming
        • Defun
        • Declare
        • System-utilities
        • Stobj
        • State
          • World
          • Io
          • Wormhole
          • Programming-with-state
            • Cbd
            • Error-triple
            • Last-prover-steps
            • @
            • State-global-let*
            • Assign
            • Read-run-time
            • F-put-global
            • Canonical-pathname
            • Unsound-eval
            • Er-progn
            • Setenv$
            • With-live-state
            • Read-ACL2-oracle
            • Getenv$
            • F-get-global
              • Pprogn
              • Get-real-time
              • Get-cpu-time
              • Makunbound-global
              • F-boundp-global
            • W
            • Set-state-ok
            • Random$
          • Memoize
          • Mbe
          • Io
          • Apply$
          • Defpkg
          • Mutual-recursion
          • Loop$
          • Programming-with-state
            • Cbd
            • Error-triple
            • Last-prover-steps
            • @
            • State-global-let*
            • Assign
            • Read-run-time
            • F-put-global
            • Canonical-pathname
            • Unsound-eval
            • Er-progn
            • Setenv$
            • With-live-state
            • Read-ACL2-oracle
            • Getenv$
            • F-get-global
              • Pprogn
              • Get-real-time
              • Get-cpu-time
              • Makunbound-global
              • F-boundp-global
            • Arrays
            • Characters
            • Time$
            • Loop$-primer
            • Fast-alists
            • Defmacro
            • Defconst
            • Evaluation
            • Guard
            • Equality-variants
            • Compilation
            • Hons
            • ACL2-built-ins
            • Developers-guide
            • System-attachments
            • Advanced-features
            • Set-check-invariant-risk
            • Numbers
            • Irrelevant-formals
            • Efficiency
            • Introduction-to-programming-in-ACL2-for-those-who-know-lisp
            • Redefining-programs
            • Lists
            • Invariant-risk
            • Errors
            • Defabbrev
            • Conses
            • Alists
            • Set-register-invariant-risk
            • Strings
            • Program-wrapper
            • Get-internal-time
            • Basics
            • Packages
            • Defmacro-untouchable
            • Primitive
            • <<
            • Revert-world
            • Set-duplicate-keys-action
            • Unmemoize
            • Symbols
            • Def-list-constructor
            • Easy-simplify-term
            • Defiteration
            • Defopen
            • Sleep
          • Start-here
          • Real
          • Debugging
          • Miscellaneous
          • Output-controls
          • Macros
          • Interfacing-tools
        • Interfacing-tools
        • Hardware-verification
        • Software-verification
        • Testing-utilities
        • Math
      • Programming-with-state
      • ACL2-built-ins

      F-get-global

      Get the value of a global variable in state

      Examples:
      (+ (f-get-global 'y state) 1)
      (f-put-global 'a
                    (aset1 'ascii-map-array
                           (f-get-global 'a state)
                           66
                           'Upper-case-B)
                    state)
      
      General Form:
      (f-get-global 'symbol state)

      where symbol is any symbol to which you have assigned a global value.

      The macro @ is closely related to f-get-global: (@ var) macroexpands to (f-get-global 'var state).

      The macro f-put-global makes it convenient to set the value of a symbol. The :ubt operation has no effect on the global-table of state. Thus, you may use these globals to hang onto useful data structures even though you may undo back past where you computed and saved them.