rustfmt on recent additions

Signed-off-by: Ava Hahn <ava@aidanis.online>
This commit is contained in:
Ava Hahn 2023-03-06 15:52:09 -08:00
parent f22d807b57
commit f8ab31e9aa
Signed by untrusted user who does not match committer: affine
GPG key ID: 3A4645B8CF806069
6 changed files with 12 additions and 9 deletions

View file

@ -17,7 +17,8 @@
use crate::segment::{Ctr, Seg};
use crate::sym::{SymTable, ValueType};
pub const AND_DOCSTRING: &str = "traverses a list of N arguments, all of which are expected to be boolean.
pub const AND_DOCSTRING: &str =
"traverses a list of N arguments, all of which are expected to be boolean.
starts with arg1 AND arg2, and then calculates prev_result AND next_arg.
returns final result.";
@ -40,7 +41,8 @@ pub fn and_callback(ast: &Seg, _syms: &mut SymTable) -> Result<Ctr, String> {
}
}
pub const OR_DOCSTRING: &str = "traverses a list of N arguments, all of which are expected to be boolean.
pub const OR_DOCSTRING: &str =
"traverses a list of N arguments, all of which are expected to be boolean.
starts with arg1 OR arg2, and then calculates prev_result OR next_arg.
returns final result.";
@ -89,7 +91,6 @@ pub const TOGGLE_DOCSTRING: &str = "switches a boolean symbol between true or fa
Takes a single argument (a symbol). Looks it up in the variable table.
Either sets the symbol to true if it is currently false, or vice versa.";
pub fn toggle_callback(ast: &Seg, syms: &mut SymTable) -> Result<Ctr, String> {
let var_name: String;
if let Ctr::Symbol(ref s) = *ast.car {