Clear out some compiler warnings
This commit is contained in:
parent
b38c4b3298
commit
3344f6827d
@ -68,10 +68,6 @@ impl BinOp {
|
|||||||
let s = token_kind_to_sigil(op_tok)?;
|
let s = token_kind_to_sigil(op_tok)?;
|
||||||
Some(binop_precedences(s))
|
Some(binop_precedences(s))
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn get_precedence(&self) -> i32 {
|
|
||||||
binop_precedences(&self.sigil)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fn token_kind_to_sigil<'a>(tok: &'a TokenKind) -> Option<&'a str> {
|
fn token_kind_to_sigil<'a>(tok: &'a TokenKind) -> Option<&'a str> {
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
use std::cell::RefCell;
|
use std::cell::RefCell;
|
||||||
use std::rc::Rc;
|
use std::rc::Rc;
|
||||||
|
|
||||||
use crate::source_map::SourceMap;
|
|
||||||
use crate::symbol_table::SymbolTable;
|
use crate::symbol_table::SymbolTable;
|
||||||
use crate::scope_resolution::ScopeResolver;
|
use crate::scope_resolution::ScopeResolver;
|
||||||
use crate::reduced_ast::reduce;
|
use crate::reduced_ast::reduce;
|
||||||
|
@ -11,7 +11,6 @@ ComputationRequest, ComputationResponse,
|
|||||||
LangMetaRequest, LangMetaResponse, GlobalOutputStats,
|
LangMetaRequest, LangMetaResponse, GlobalOutputStats,
|
||||||
DebugResponse, DebugAsk};
|
DebugResponse, DebugAsk};
|
||||||
use crate::{ast, reduced_ast, tokenizing, parsing, eval, typechecking, symbol_table, source_map};
|
use crate::{ast, reduced_ast, tokenizing, parsing, eval, typechecking, symbol_table, source_map};
|
||||||
use source_map::SourceMap;
|
|
||||||
|
|
||||||
pub type SymbolTableHandle = Rc<RefCell<symbol_table::SymbolTable>>;
|
pub type SymbolTableHandle = Rc<RefCell<symbol_table::SymbolTable>>;
|
||||||
pub type SourceMapHandle = Rc<RefCell<source_map::SourceMap>>;
|
pub type SourceMapHandle = Rc<RefCell<source_map::SourceMap>>;
|
||||||
|
@ -4,7 +4,6 @@ use std::rc::Rc;
|
|||||||
|
|
||||||
use super::*;
|
use super::*;
|
||||||
use crate::util::quick_ast;
|
use crate::util::quick_ast;
|
||||||
use crate::source_map;
|
|
||||||
|
|
||||||
fn add_symbols_from_source(src: &str) -> (SymbolTable, Result<(), String>) {
|
fn add_symbols_from_source(src: &str) -> (SymbolTable, Result<(), String>) {
|
||||||
let (ast, source_map) = quick_ast(src);
|
let (ast, source_map) = quick_ast(src);
|
||||||
|
@ -14,6 +14,7 @@ pub struct TypeData {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl TypeData {
|
impl TypeData {
|
||||||
|
#[allow(dead_code)]
|
||||||
pub fn new() -> TypeData {
|
pub fn new() -> TypeData {
|
||||||
TypeData { ty: None }
|
TypeData { ty: None }
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user