Formatting.

This commit is contained in:
Calvin Rose 2023-07-02 15:23:22 -05:00
parent e38663c457
commit 026c64fa01
2 changed files with 6 additions and 6 deletions

View File

@ -1174,11 +1174,11 @@ JanetTable *janet_core_env(JanetTable *replacements) {
"values."));
templatize_varop(env, JANET_FUN_MODULO, "mod", 0, 1, JOP_MODULO,
JDOC("(mod & xs)\n\n"
"Returns the result of applying the modulo operator on the first value of xs with each remaining value. "
"`(mod x 0)` is defined to be `x`."));
"Returns the result of applying the modulo operator on the first value of xs with each remaining value. "
"`(mod x 0)` is defined to be `x`."));
templatize_varop(env, JANET_FUN_REMAINDER, "%", 0, 1, JOP_REMAINDER,
JDOC("(% & xs)\n\n"
"Returns the remainder of dividing the first value of xs by each remaining value."));
"Returns the remainder of dividing the first value of xs by each remaining value."));
templatize_varop(env, JANET_FUN_BAND, "band", -1, -1, JOP_BAND,
JDOC("(band & xs)\n\n"
"Returns the bit-wise and of all values in xs. Each x in xs must be an integer."));

View File

@ -720,10 +720,10 @@ static JanetSignal run_vm(JanetFiber *fiber, Janet in) {
double x1 = janet_unwrap_number(op1);
double x2 = janet_unwrap_number(op2);
if (x2 == 0) {
stack[A] = janet_wrap_number(x1);
stack[A] = janet_wrap_number(x1);
} else {
double intres = x2 * floor(x1 / x2);
stack[A] = janet_wrap_number(x1 - intres);
double intres = x2 * floor(x1 / x2);
stack[A] = janet_wrap_number(x1 - intres);
}
vm_pcnext();
} else {