Seol mar théacs é seo: The automatic detection of token structures and invariants using SAT checking