kdr-aus/ogma

[BUG]

Closed this issue · 0 comments

Current Behaviour

Compiler error:

┃>> open ##### | let {nth 0 get:Num ###} $start {last get:Num ###} $end                                                                                                             
┃Typing Error: Type resolution failed                                                                                                                                                                  ┃--> shell:62                                                                                                                                                                                          
┃ | open #### | let {nth 0 get:Num ###} $start {last get:Num ###} $end                                                                                                             
┃ |                                                               ^^^^^^^^^^^^^^^^^^ this node is only inferred                                                                                        ┃
┃--> <ogma>:46                                                                                                                                                                                         
┃ | def last Table (expr:Expr) { nth {len | - 1} $expr }                                                                                                                                               ┃ |                                               ^^^^ but this node is has stronger type garauntees                                                                                                   
┃--> help: this is an internal bug, please report it at <https://github.com/kdr-aus/ogma/issues>                                                                                                       
┃Please supply this BACKTRACE:                                                                                                                                                                         
┃   0: ogma::eng::comp::resolve_tg::<impl ogma::eng::Compiler>::resolve_tg                                                                                                                             
┃   1: ogma::eng::comp::<impl ogma::eng::Compiler>::compile                                                                                                                                            
┃   2: ogma::eng::comp::compile_with_seed_vars                                                                                                                                                         ┃   3: std::sys_common::backtrace::__rust_begin_short_backtrace                                                                                                                                        ┃   4: core::ops::function::FnOnce::call_once{{vtable.shim}}                                                                                                                                           
┃   5: <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once                                                                                                                        
┃             at /rustc/7737e0b5c4103216d6fd8cf941b7ab9bdbaace7c/library/alloc/src/boxed.rs:1853:9                                                                                                     
┃      <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once                                                                                                                        
┃             at /rustc/7737e0b5c4103216d6fd8cf941b7ab9bdbaace7c/library/alloc/src/boxed.rs:1853:9                                                                                                     
┃      std::sys::unix::thread::Thread::new::thread_start                                                                                                                                               
┃             at /rustc/7737e0b5c4103216d6fd8cf941b7ab9bdbaace7c/library/std/src/sys/unix/thread.rs:108:17                                                                                             
┃   6: start_thread                                                                                                                                                                                    
┃   7: clone

Expected Behaviour

Reproduction Steps

Additional information