The runtime of the callcc version builds on code by R. Kent Dybvig, Simon L. Peyton Jones, and Amr Sabry, as presented in: Dyvbig, R. K., Jones, S. P., & Sabry, A. (2007). A monadic framework for delimited continuations. Journal of Functional Programming, 17(6), 687-730. The regular expression implementation is by Dorai Sitaram and obtained from: