Skip to content

Commit 32da8b7

Browse files
committed
fix(warn): 修复部分编译器警告.
1 parent aca65e4 commit 32da8b7

3 files changed

Lines changed: 1 addition & 4 deletions

File tree

src/compiler/ast/ssa_ir.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ impl Code {
5959

6060
pub fn alloc_value(
6161
&mut self,
62-
value: Operand,
6362
token: Token,
6463
type_: ValueGuessType,
6564
) -> DefaultKey {

src/compiler/parser/symbol_table.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
use crate::compiler::lexer::Token;
2-
use crate::compiler::parser::ParserError;
31
use smol_str::SmolStr;
42
use std::cmp::PartialEq;
53

src/compiler/semantic/varsemantic.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,6 @@ pub fn var_semantic(
2020
symbol_table.add_element(name.value().unwrap(), VALUE);
2121
let ret_m = expr_semantic(semantic, init_var)?;
2222
let opread = ret_m.clone();
23-
let key = code.alloc_value(ret_m.0, name, ret_m.1);
23+
let key = code.alloc_value(name, ret_m.1);
2424
Ok(StackLocal(key, opread.0))
2525
}

0 commit comments

Comments
 (0)