Added USERLIB with prepend and set.
Added a q shortcut to quote get-doc and set-doc no longer conditionally evaluate args Fixed bug in let, documented potential performance improvements upped default history to 5k lines
This commit is contained in:
parent
a01df6b7b2
commit
1ee9ba55fb
7 changed files with 70 additions and 25 deletions
19
src/stl.rs
19
src/stl.rs
|
|
@ -481,6 +481,17 @@ pub fn static_stdlib(syms: &mut SymTable) -> Result<(), String> {
|
|||
},
|
||||
);
|
||||
|
||||
syms.insert(
|
||||
"q".to_string(),
|
||||
Symbol {
|
||||
name: String::from("quote"),
|
||||
args: Args::Lazy(1),
|
||||
conditional_branches: true,
|
||||
docs: decl::QUOTE_DOCSTRING.to_string(),
|
||||
value: ValueType::Internal(Rc::new(decl::quote_callback)),
|
||||
},
|
||||
);
|
||||
|
||||
syms.insert(
|
||||
"eval".to_string(),
|
||||
Symbol {
|
||||
|
|
@ -507,8 +518,8 @@ pub fn static_stdlib(syms: &mut SymTable) -> Result<(), String> {
|
|||
"get-doc".to_string(),
|
||||
Symbol {
|
||||
name: String::from("get-doc"),
|
||||
args: Args::Lazy(1),
|
||||
conditional_branches: true,
|
||||
args: Args::Strict(vec![Type::Symbol]),
|
||||
conditional_branches: false,
|
||||
docs: decl::GETDOC_DOCSTRING.to_string(),
|
||||
value: ValueType::Internal(Rc::new(decl::getdoc_callback)),
|
||||
}
|
||||
|
|
@ -518,8 +529,8 @@ pub fn static_stdlib(syms: &mut SymTable) -> Result<(), String> {
|
|||
"set-doc".to_string(),
|
||||
Symbol {
|
||||
name: String::from("get-doc"),
|
||||
args: Args::Lazy(2),
|
||||
conditional_branches: true,
|
||||
args: Args::Strict(vec![Type::Symbol, Type::String]),
|
||||
conditional_branches: false,
|
||||
docs: decl::SETDOC_DOCSTRING.to_string(),
|
||||
value: ValueType::Internal(Rc::new(decl::setdoc_callback)),
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue