Skip to content

Instantly share code, notes, and snippets.

@deque-blog
Created January 29, 2017 14:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deque-blog/6b23b36986bb21733cd5b27a018711a9 to your computer and use it in GitHub Desktop.
Save deque-blog/6b23b36986bb21733cd5b27a018711a9 to your computer and use it in GitHub Desktop.
expression partial_eval(env const& env, expression const& e)
{
return cata<expression>(
[&env](expression_r<expression> const& e) -> expression {
return optimize_alg(partial_eval_alg(env)(e).get());
},
e);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment