MCPcopy Create free account

hub / github.com/Canop/bet / functions

Functions53 in github.com/Canop/bet

↓ 33 callersFunctioncheck
(input: &str, expected: bool)
src/test_bool.rs:26
↓ 24 callersFunctioncheck
(input: &str, expected: bool)
src/test_bool_faillible.rs:28
↓ 7 callersMethodpush_operator
add an operator right of the expression The context will decide whether it's unary or binary
src/be_tree.rs:281
↓ 4 callersMethodpush_atom
add an atom in a left-to-right expression building
src/be_tree.rs:178
↓ 3 callersMethodclose_par
add a closing parenthesis to the expression
src/be_tree.rs:221
↓ 3 callersMethodis_none
(self)
src/child.rs:14
↓ 3 callersMethodis_some
(self)
src/child.rs:17
↓ 3 callersMethodopen_par
add an opening parenthesis to the expression
src/be_tree.rs:213
↓ 3 callersMethodpush
add one of the possible token: parenthesis, operator or atom
src/be_tree.rs:168
↓ 3 callersMethodstore_node
(&mut self, node: Node<Op>)
src/be_tree.rs:142
↓ 2 callersMethodadd_child
(&mut self, child: Child)
src/be_tree.rs:152
↓ 2 callersMethodeval
(self, a: bool, b: Option<bool>)
src/test_bool.rs:12
↓ 2 callersMethodeval_child
( &self, eval_atom: &EvalAtom, eval_op: &EvalOp, short_circuit: &ShortCircuit,
src/be_tree.rs:360
↓ 2 callersMethodeval_child_faillible
( &self, eval_atom: &EvalAtom, eval_op: &EvalOp, short_circuit: &ShortCircuit,
src/be_tree.rs:379
↓ 2 callersMethodeval_node
( &self, eval_atom: &EvalAtom, eval_op: &EvalOp, short_circuit: &ShortCircuit,
src/be_tree.rs:400
↓ 2 callersMethodeval_node_faillible
( &self, eval_atom: &EvalAtom, eval_op: &EvalOp, short_circuit: &ShortCircuit,
src/be_tree.rs:428
↓ 2 callersMethodprint_child
(&self, child: Child, indent: usize)
src/be_tree.rs:526
↓ 2 callersMethodprint_node
(&self, node_id: NodeId, indent: usize)
src/be_tree.rs:537
↓ 1 callersMethodadd_child_node
(&mut self, child_idx: usize)
src/be_tree.rs:161
↓ 1 callersMethodeval
(self, a: bool, b: Option<bool>)
src/test_bool_faillible.rs:14
↓ 1 callersMethodeval_faillible
( &self, eval_atom: EvalAtom, eval_op: EvalOp, short_circuit: ShortCircuit,
src/be_tree.rs:498
↓ 1 callersMethodis_full
a node is full when we can't add other childs
src/node.rs:26
↓ 1 callersMethodpush_binary_operator
(&mut self, operator: Op)
src/be_tree.rs:243
↓ 1 callersMethodpush_unary_operator
(&mut self, operator: Op)
src/be_tree.rs:231
↓ 1 callersMethodshort_circuit
tell whether we can skip evaluating the second operand
src/test_bool_faillible.rs:23
↓ 1 callersMethodshort_circuit
tell whether we can skip evaluating the second operand
src/test_bool.rs:21
↓ 1 callersMethodstore_atom
(&mut self, atom: Atom)
src/be_tree.rs:147
Methodaccept_atom
tell whether it would make sense to push an atom at this point (for example it makes no sense just after a closing parenthesis)
src/be_tree.rs:314
Methodaccept_binary_operator
tell whether it would make sense to push a binary operator at this point (for example it makes no sense just after another operator)
src/be_tree.rs:307
Methodaccept_closing_par
tell whether it would make sense to close a parenthesis at this point (for example it makes no sense just after an operator or if there are more closi
src/be_tree.rs:331
Methodaccept_opening_par
tell whether it would make sense to open a parenthesis at this point (for example it makes no sense just after a closing parenthesis)
src/be_tree.rs:322
Methodaccept_unary_operator
tell whether it would make sense to push a unary operator at this point (for example it makes no sense just after an atom)
src/be_tree.rs:299
Methodatom
(&self, atom_id: AtomId)
src/be_tree.rs:86
Methodatoms
take the atoms of the tree
src/be_tree.rs:115
Methodcurrent_atom
returns a reference to the last atom if it's the last pushed token. Return none in other cases (including when no atom has been pushed at all)
src/be_tree.rs:127
Methoddefault
()
src/be_tree.rs:43
Methodempty
()
src/node.rs:33
Methodeq
(&self, other: &Self)
src/be_tree.rs:61
Methodeval
( &self, eval_atom: EvalAtom, eval_op: EvalOp, short_circuit: ShortCircuit,
src/be_tree.rs:470
Methodget_openness
return the count of open parenthesis minus the one of closing parenthesis. Illegal closing parenthesis are ignored (hence why this count can be a usiz
src/be_tree.rs:138
Methodhead
(&self)
src/be_tree.rs:90
Methodis_atomic
tell whether the tree is exactly one atom
src/be_tree.rs:110
Methodis_empty
tells whether the expression is devoid of any atom
src/be_tree.rs:105
Functionissue_2
()
src/test_bool.rs:76
Methoditer_atoms
iterate on all atoms
src/be_tree.rs:120
Methodmutate_or_create_atom
if the last change was an atom pushed or modified, return a mutable reference to this atom. If not, push a new atom and return a mutable reference to
src/be_tree.rs:202
Methodnew
create an empty expression, ready to be completed
src/be_tree.rs:78
Methodnode
(&self, node_id: NodeId)
src/be_tree.rs:82
Methodprint_tree
(&self)
src/be_tree.rs:544
Methodsimplify
(&mut self)
src/be_tree.rs:512
Functiontest_bool
()
src/test_bool_faillible.rs:50
Functiontest_bool
()
src/test_bool.rs:48
Methodtry_map_atoms
(&self, f: F)
src/be_tree.rs:340