Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/brundonsmith/rust_lisp
/ functions
Functions
128 in github.com/brundonsmith/rust_lisp
⨍
Functions
128
◇
Types & classes
13
↓ 42 callers
Method
define
Define a new key in the current environment
src/model/env.rs:45
↓ 40 callers
Function
require_arg
Given a `Value` assumed to be a `Value::List()`, grab the item at `index` and err if there isn't one.
src/utils.rs:7
↓ 27 callers
Method
into_iter
(list: &'a List)
src/model/list.rs:50
↓ 26 callers
Function
eval_str
(source: &str)
tests/interpreter.rs:397
↓ 24 callers
Method
cdr
(&self)
src/model/list.rs:29
↓ 14 callers
Method
get
Walks up the environment hierarchy until it finds the symbol's value or runs out of environments.
src/model/env.rs:34
↓ 13 callers
Function
parse
Parse a string of Lisp code into a series of s-expressions. There are more than one expressions when the base string has more than one independent par
src/parser.rs:11
↓ 11 callers
Method
next
(&mut self)
src/model/list.rs:111
↓ 10 callers
Method
car
(&self)
src/model/list.rs:20
↓ 10 callers
Function
int_type_to_float_type
Convert whatever int type we're using to whatever float type we're using
src/model/value.rs:507
↓ 9 callers
Function
eval
Evaluate a single Lisp expression in the context of a given environment.
src/interpreter.rs:8
↓ 8 callers
Method
found_tail
(self, found_tail: bool)
src/interpreter.rs:398
↓ 7 callers
Function
consume
(code: &str, index: usize, s: &str)
src/parser.rs:306
↓ 6 callers
Function
default_env
Initialize an instance of `Env` with several core Lisp functions implemented in Rust. **Without this, you will only have access to the functions you i
src/default_environment.rs:18
↓ 5 callers
Function
consume_while
( code: &str, index: usize, mut pred: F, )
src/parser.rs:337
↓ 5 callers
Function
next_char_is_break
(code: &str, index: usize)
src/parser.rs:358
↓ 4 callers
Function
consume_whitespace_and_comments
(code: &str, index: usize)
src/parser.rs:321
↓ 4 callers
Function
eval_block_inner
( env: Rc<RefCell<Env>>, clauses: impl Iterator<Item = Value>, context: Context, )
src/interpreter.rs:21
↓ 4 callers
Function
parse_expression
(code: &str, index: usize)
src/parser.rs:82
↓ 3 callers
Function
call_function_or_macro
Calling a function is separated from the main `eval_inner()` function so that tail calls can be evaluated without just returning themselves as-is as a
src/interpreter.rs:331
↓ 3 callers
Function
eval_ast
(ast: Value)
tests/default_environment.rs:146
↓ 3 callers
Function
eval_inner
`found_tail` and `in_func` are used when locating the tail position for tail-call optimization. Candidates are not eligible if a) we aren't already in
src/interpreter.rs:57
↓ 3 callers
Method
len
(&self)
src/model/list.rs:123
↓ 3 callers
Function
value_to_argnames
(argnames: List)
src/interpreter.rs:311
↓ 2 callers
Method
cons
(&self, val: Value)
src/model/list.rs:39
↓ 2 callers
Function
is_symbolic
(c: char)
src/parser.rs:354
↓ 2 callers
Method
quoting
(self, quoting: bool)
src/interpreter.rs:414
↓ 1 callers
Method
display_recursive
(&self, output: &mut String, depth: i32)
src/model/env.rs:73
↓ 1 callers
Function
eval_block
Evaluate a series of s-expressions. Each expression is evaluated in order and the final one's return value is returned.
src/interpreter.rs:14
↓ 1 callers
Method
into_value
(self)
src/parser.rs:42
↓ 1 callers
Function
is_symbol_start
(c: char)
src/parser.rs:350
↓ 1 callers
Method
partial_cmp
(&self, other: &Value)
src/model/value.rs:358
↓ 1 callers
Method
set
Find the environment where this key is defined, and update its value. Returns an Err if the symbol has not been defined anywhere in the hierarchy.
src/model/env.rs:51
↓ 1 callers
Function
start_repl
🦀 I am all over this project! Starts a REPL prompt at stdin/stdout. **This will block the current thread.
src/lib.rs:20
Method
add
(self, other: &Value)
src/model/value.rs:384
Function
and_expressions
()
tests/interpreter.rs:332
Function
calling_empty_fun
()
tests/interpreter.rs:244
Function
closure
()
tests/interpreter.rs:257
Method
cmp
(&self, other: &Self)
src/model/value.rs:524
Function
defmacro
()
tests/interpreter.rs:299
Method
div
(self, other: &Value)
src/model/value.rs:481
Method
eq
(&self, other: &Self)
src/model/value.rs:326
Method
eq
(&self, other: &Self)
src/model/lambda.rs:16
Function
eval_add_list
()
tests/interpreter.rs:18
Function
eval_basic_expression
()
tests/interpreter.rs:11
Function
eval_fib
()
tests/interpreter.rs:159
Function
eval_let
()
tests/interpreter.rs:81
Function
eval_let_scope
()
tests/interpreter.rs:98
Function
eval_merge_sort
()
tests/interpreter.rs:177
Function
eval_mul_list_ints
()
tests/interpreter.rs:25
Function
eval_mul_list_mixed
()
tests/interpreter.rs:32
Function
eval_nil
()
tests/interpreter.rs:39
Function
eval_quote_1
()
tests/interpreter.rs:46
Function
eval_quote_2
()
tests/interpreter.rs:53
Function
eval_quote_tick_atom
()
tests/interpreter.rs:67
Function
eval_quote_tick_list
()
tests/interpreter.rs:60
Function
eval_quote_tick_symbol
()
tests/interpreter.rs:74
Function
eval_set_global
()
tests/interpreter.rs:116
Function
eval_set_local
()
tests/interpreter.rs:132
Function
eval_set_undefined
()
tests/interpreter.rs:149
Function
eval_str
(source: &str)
tests/little_lisper.rs:65
Method
extend
Create a new environment extending the given environment
src/model/env.rs:25
Function
filter
()
tests/default_environment.rs:70
Function
filter_list_of_lists
()
tests/default_environment.rs:93
Function
five
()
tests/little_lisper.rs:45
Method
fmt
(&self, formatter: &mut std::fmt::Formatter)
src/parser.rs:66
Method
fmt
(&self, f: &mut std::fmt::Formatter)
src/model/value.rs:266
Method
fmt
(&self, f: &mut std::fmt::Formatter<'_>)
src/model/symbol.rs:15
Method
fmt
(&self, formatter: &mut std::fmt::Formatter)
src/model/env.rs:98
Method
fmt
(&self, f: &mut std::fmt::Formatter<'_>)
src/model/lambda.rs:32
Method
fmt
(&self, formatter: &mut std::fmt::Formatter)
src/model/runtime_error.rs:10
Method
fmt
(&self, formatter: &mut std::fmt::Formatter)
src/model/list.rs:72
Function
four
()
tests/little_lisper.rs:37
Method
from
(b: bool)
src/model/value.rs:87
Method
from
(s: &str)
src/model/symbol.rs:9
Method
from_iter
(iter: I)
src/model/list.rs:133
Method
get_name
()
src/utils.rs:50
Method
hash
(&self, state: &mut H)
src/model/value.rs:533
Method
hash
(&self, state: &mut H)
src/model/lambda.rs:24
Method
hash
(&self, state: &mut H)
src/model/list.rs:65
Function
hash_map
()
tests/default_environment.rs:107
Function
lambda_err
()
tests/interpreter.rs:268
Function
main
()
src/main.rs:17
Function
map
()
tests/default_environment.rs:32
Function
map_list_of_lists
()
tests/default_environment.rs:84
Method
mul
(self, other: &Value)
src/model/value.rs:453
Function
native_closure
()
tests/interpreter.rs:367
Method
new
()
src/interpreter.rs:390
Method
new
Create a new, empty environment
src/model/env.rs:17
Function
nth
()
tests/default_environment.rs:22
Function
number_cast_comparisons
()
tests/default_environment.rs:122
Function
one
()
tests/little_lisper.rs:11
Function
or_expressions
()
tests/interpreter.rs:314
Function
parse_atom
(code: &str, index: usize)
src/parser.rs:122
Function
parse_atom
()
tests/parser.rs:40
Function
parse_basic_expression
()
tests/parser.rs:10
Function
parse_comma
(code: &str, index: usize)
src/parser.rs:157
Function
parse_false
(code: &str, index: usize)
src/parser.rs:184
Function
parse_incomplete_float
()
tests/parser.rs:103
Function
parse_list
(code: &str, index: usize)
src/parser.rs:94
next →
1–100 of 128, ranked by callers