- [x] downgrade stage - [ ] resolve stage - [ ] dynamic attr resolution - [ ] import resolution - [ ] static path resolution - [ ] eval stage - [ ] dynamic path resolution - [ ] graph update - [ ] stack storage 依赖类型: 1. 强依赖 (x!) - builtins.toString x => x! - x + y => x! y! - { x = 1; ${sym} = 2; } => sym! 2. 弱依赖 a.k.a. thunk (x?) - builtins.seq x y => x! y? 3. 递归依赖 (x!!) - builtins.deepSeq x y => x!! y? e.g. - let a? = { inherit a?; }; in a! => a! - a! => { a = } - f: let x? = f! x?; in x! => f! x! - let ret? = (self: { x? = 1; y? = self.x! + 1; }) ret?; in ret.y! => ret! x! y! 工作流程: 1. string -> AST 2. AST -> HIR (alloc ExprId) 3. HIR -> LIR (resolve var, build graph) 4. LIR -> Value