uiua-lang / uiua

A stack-based array programming language
https://www.uiua.org
MIT License
1.62k stars 117 forks source link

uiua stand panicing #595

Closed BaerLKR closed 1 month ago

BaerLKR commented 1 month ago

When I try to produce an executable from a uiua script that works if I use uiua run the executable panics with this error when I run the executable. There is no error when using the uiua stand command. This is still the case in 0.13.0-rc.4

The application panicked (crashed).
Message:  called `Result::unwrap()` on an `Err` value: "expected value at line 1 column 1"
Location: src/stand.rs:37

Backtrace omitted.

Run with RUST_BACKTRACE=1 environment variable to display it.
Run with RUST_BACKTRACE=full to include source snippets.
Message:  called `Result::unwrap()` on an `Err` value: "expected value at line 1 column 1"
Location: src/stand.rs:37

Run with COLORBT_SHOW_HIDDEN=1 environment variable to disable frame filtering.
Run with RUST_BACKTRACE=full to include source snippets.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ BACKTRACE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
                              ⋮ 8 frames hidden ⋮                               
 9: uiua::stand::load_asm::h0f8342882d31ff20
    at <unknown source file>
10: core::ops::function::FnOnce::call_once::hf45363644200c835
    at <unknown source file>
11: once_cell::imp::OnceCell<T>::initialize::{{closure}}::h6643d8e8558c13bd
    at <unknown source file>
12: once_cell::imp::initialize_or_wait::h27460026aa9cc1c7
    at <unknown source file>
13: once_cell::imp::OnceCell<T>::initialize::h662518fd44e688e2
    at <unknown source file>
14: uiua::run::h6e7de726bcd574af
    at <unknown source file>
15: uiua::main::h4f035551eb08bd49
    at <unknown source file>
16: std::sys_common::backtrace::__rust_begin_short_backtrace::h4eedc513d912a2f7
    at <unknown source file>
17: std::rt::lang_start::{{closure}}::h715062c119f15df4
    at <unknown source file>
18: std::panicking::try::ha86251cf5daa9bea
    at <unknown source file>
19: std::rt::lang_start_internal::ha6a51778162f8d22
    at <unknown source file>
20: main
    at <unknown source file>
21: __libc_start_call_main
    at <unknown source file>
22: __libc_start_main@@GLIBC_2.34
    at <unknown source file>
23: _start
    at <unknown source file>
kaikalii commented 1 month ago

Can I see the code in question?

BaerLKR commented 1 month ago

i tried multiple scripts, they all came to the same result the one used here is

F ← ↯:
F [1 2 3 4]2_2
F [1 2 3] 1_3
F 1_2 1_1
kaikalii commented 1 month ago

Hmm, I am unable to reproduce. uiua stand; ./uiua.exe with that code runs correctly for me. Can you try with 0.13.0-rc.6?

BaerLKR commented 1 month ago

sorry I forgot to answer it seems to work fine in 0.13.0