Compare commits

..

No commits in common. "a534e241f97419d48c7d85c20e4ab0e030815cac" and "45d999d32e4a9b29f705bbfa212c2628ec36e3aa" have entirely different histories.

5 changed files with 5 additions and 11 deletions

View File

@ -920,7 +920,7 @@ fn get {
fn update {
"Takes a dict, key, and function, and returns a new dict with the key set to the result of applying the function to original value held at the key."
(d as :dict) -> d
(d as :dict, k as :keyword, updater as :fn) -> assoc (d, k, updater (get (d, k)))
(d as :dict, k as :keyword, updater as :fn) -> assoc (d, k, updater (get (k, d)))
}
fn keys {
@ -974,7 +974,7 @@ fn random {
}
(d as :dict) -> {
let key = do d > keys > random
get (d, key)
get (key, d)
}
& (s as :set) -> do s > list > random
}

View File

@ -403,7 +403,7 @@ function __wbg_get_imports() {
_assertBoolean(ret);
return ret;
};
imports.wbg.__wbindgen_closure_wrapper8189 = function() { return logError(function (arg0, arg1, arg2) {
imports.wbg.__wbindgen_closure_wrapper8169 = function() { return logError(function (arg0, arg1, arg2) {
const ret = makeMutClosure(arg0, arg1, 363, __wbg_adapter_20);
return ret;
}, arguments) };

Binary file not shown.

View File

@ -156,7 +156,7 @@ fn traceback(panic: &Panic) -> String {
fn frame_info(frame: &CallFrame) -> String {
let span = frame.chunk().spans[if frame.ip == 0 { 0 } else { frame.ip - 1 }];
let line_number = line_number(frame.chunk().src, span);
// console_log!("ip: {} | span: {span} | line: {line_number}", frame.ip);
console_log!("ip: {} | span: {span} | line: {line_number}", frame.ip);
let line = get_line(frame.chunk().src, line_number);
let line = line.trim_start();
let name = frame.function.as_fn().name();

View File

@ -40,13 +40,7 @@ impl LFn {
pub fn patterns(&self) -> Value {
match self {
LFn::Declared { .. } => unreachable!(),
LFn::Defined { patterns, .. } => Value::from_string(
patterns
.iter()
.map(|pattern| format!(" {pattern}"))
.collect::<Vec<_>>()
.join("\n"),
),
LFn::Defined { patterns, .. } => Value::from_string(patterns.join(" | ")),
}
}