This makes it Scheme-accessible, removing duplication of code in output-lib.scm. It also caches the value.