zkincaid / duet

Duet: static analysis for unbounded concurrency
http://duet.cs.toronto.edu
MIT License
23 stars 17 forks source link

added type info to substitute. fixed bug in substitute_sym #23

Closed JakeSilverman closed 3 years ago

JakeSilverman commented 3 years ago

Previous discussion:

https://github.com/zkincaid/duet/pull/20#discussion_r550509824 https://github.com/zkincaid/duet/pull/20#discussion_r550578419

A function may have more free vars than it does parameters in the case that the user wants an uncaptured var to appear in the resulting term. For example, consider if the user wants to replace the term "f(x)" with the term "f(x + var 0)". I added tests to cover previous bug and to show desire for having free vars beyond # of parameters. Note this is also in line with current specification in .mli file.