mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-01 15:51:12 +00:00
remove Expr::FunctionPointer
This commit is contained in:
parent
3739f41cac
commit
16fe609464
5 changed files with 4 additions and 61 deletions
|
@ -103,8 +103,7 @@ pub fn occuring_variables_expr(expr: &Expr<'_>, result: &mut MutSet<Symbol>) {
|
|||
use Expr::*;
|
||||
|
||||
match expr {
|
||||
FunctionPointer(symbol, _)
|
||||
| AccessAtIndex {
|
||||
AccessAtIndex {
|
||||
structure: symbol, ..
|
||||
} => {
|
||||
result.insert(*symbol);
|
||||
|
@ -556,11 +555,7 @@ impl<'a> Context<'a> {
|
|||
arguments,
|
||||
}) => self.visit_call(z, call_type, arguments, l, b, b_live_vars),
|
||||
|
||||
EmptyArray
|
||||
| FunctionPointer(_, _)
|
||||
| Literal(_)
|
||||
| Reset(_)
|
||||
| RuntimeErrorFunction(_) => {
|
||||
EmptyArray | Literal(_) | Reset(_) | RuntimeErrorFunction(_) => {
|
||||
// EmptyArray is always stack-allocated
|
||||
// function pointers are persistent
|
||||
self.arena.alloc(Stmt::Let(z, v, l, b))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue