a few changes enclosed:
* documented deps * mild string escaping * corrected a misbehavior in sym
This commit is contained in:
parent
d7864ee628
commit
5afc2cc4a1
4 changed files with 22 additions and 14 deletions
11
src/sym.rs
11
src/sym.rs
|
|
@ -132,9 +132,6 @@ impl SymTable {
|
|||
// but we dont want to increment it
|
||||
symbol.__generation -= 1;
|
||||
self.insert(name.to_string(), symbol.clone());
|
||||
|
||||
let cond_args: &Seg;
|
||||
let outer_scope_seg_holder: Seg;
|
||||
if let ValueType::VarForm(ref val) = symbol.value {
|
||||
match **val {
|
||||
Ctr::Lambda(ref l) if call_func => {
|
||||
|
|
@ -147,13 +144,11 @@ impl SymTable {
|
|||
_ => return Ok(val.clone()),
|
||||
}
|
||||
} else if call_func {
|
||||
cond_args = args
|
||||
symbol.call(args, self)
|
||||
} else {
|
||||
outer_scope_seg_holder = Seg::new();
|
||||
cond_args = &outer_scope_seg_holder;
|
||||
// its a function but call_func is off
|
||||
Ok(Box::new(Ctr::Symbol(name.to_string())))
|
||||
}
|
||||
|
||||
symbol.call(cond_args, self)
|
||||
}
|
||||
|
||||
pub fn is_function_type(&self, name: &String) -> Option<bool> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue