Skip to content

Instantly share code, notes, and snippets.

@pschanely
Created November 13, 2025 18:41
Show Gist options
  • Select an option

  • Save pschanely/9609f93b6177da9a3d815957d2568f6e to your computer and use it in GitHub Desktop.

Select an option

Save pschanely/9609f93b6177da9a3d815957d2568f6e to your computer and use it in GitHub Desktop.
Shared via CrossHair Playground
import re
from crosshair import NoTracing
from crosshair.statespace import context_statespace
_TWO_DIGITS_REGEX = re.compile("[1-9][0-9]")
def top(ipstr: str) -> bool:
"""
This is an example of dumping the solver state after running some python
code.
post: True
"""
if _TWO_DIGITS_REGEX.fullmatch(ipstr):
x = 42
with NoTracing():
print("=== new iteration ===")
print(context_statespace().solver.sexpr())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment