Remove bogon that I would not have caught had I not proofread it.
Chris Pressey
3 years ago
235 | 235 | -- |
236 | 236 | -- Returns [bool, term] where bool indicates "has rewritten" |
237 | 237 | -- UNTESTED |
238 | --`var`, `app`, and `abs` construct terms, while `resolve` and `destruct` | |
239 | take them apart. Constructing terms is the easy part; it's taking them | |
240 | apart properly that's hard, and that's what `freevars` is there to help | |
241 | support. For more on this, see the [Discussion](#discussion) section | |
242 | below. | |
243 | ||
238 | -- | |
239 | let reduce = fun(t) -> | |
240 | if is_beta_reducible(t) then | |
241 | [true, beta(t)] | |
244 | 242 | else |
245 | 243 | destruct(t, |
246 | 244 | fun(n) -> [false, var(n)], |