Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't load shen-libs 'strings' module #2

Open
dysinger opened this issue Nov 25, 2018 · 2 comments
Open

Can't load shen-libs 'strings' module #2

dysinger opened this issue Nov 25, 2018 · 2 comments

Comments

@dysinger
Copy link
Contributor

FFIW I can't load this string module from shen-libs. shen-go panics.

\* modulesys *\                                                                                                                         
(load "/home/tim/src/shen/callwords/shen-libs/modulesys.shen")                                                                          
(module.add-path "/home/tim/src/shen/callwords/shen-libs")                                                                              
                                                                                                                                        
\* shen-libs *\                                                                                                                         
(module.use [strings])                               

results in

Recovered in Eval: (module.use (cons strings ()))                                                                                       
goroutine 1 [running]:                                                                                                                  
github.com/tiancaiamao/shen-go/runtime.(*VM).Eval.func1(0xc0001ce780, 0xc000a3b840, 0xc0024e3b70)                                       
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:566 +0xdd                                                         
panic(0x8e7b40, 0x9e4640)                                                                                                               
        /nix/store/kdv438a5wjnh1kaib41479lriqlhhc15-go-1.11/share/go/src/runtime/panic.go:513 +0x1b9                                    
github.com/tiancaiamao/shen-go/runtime.mustNumber(...)                                                                                  
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/types.go:200                                                            
github.com/tiancaiamao/shen-go/runtime.greatThan(0xc0004140c8, 0x2, 0xe7, 0xb)                                                          
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/primitives.go:247 +0xca                                                 
github.com/tiancaiamao/shen-go/runtime.opNativeCall.func1(0xc0001ce780)                                                                 
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:481 +0x127                                                        
github.com/tiancaiamao/shen-go/runtime.(*VM).Run(0xc0001ce780, 0xc0019dd810, 0xa, 0xa, 0x0)                                             
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:146 +0x5c                                                         
github.com/tiancaiamao/shen-go/runtime.(*VM).Eval(0xc0001ce780, 0xc000a3b840, 0x0)                                                      
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:577 +0x117                                                        
github.com/tiancaiamao/shen-go/runtime.primEvalKL(0xc00150e080, 0x1, 0x3f0, 0x11)                                                       
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/primitives.go:490 +0x5b                                                 
github.com/tiancaiamao/shen-go/runtime.opNativeCall.func1(0xc0001ce140)                                                                 
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:481 +0x127                                                        
github.com/tiancaiamao/shen-go/runtime.(*VM).Run(0xc0001ce140, 0xc0000975f0, 0x5, 0x5, 0x0)                                             
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:146 +0x5c                                                         
github.com/tiancaiamao/shen-go/runtime.(*VM).Eval(0xc0001ce140, 0xc000560f20, 0x0)                                                      
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:577 +0x117                                                        
github.com/tiancaiamao/shen-go/runtime.primEvalKL(0xc000787838, 0x1, 0xf9, 0x11)                                                        
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/primitives.go:490 +0x5b                                                 
github.com/tiancaiamao/shen-go/runtime.opNativeCall.func1(0xc0001ce0a0)                                                                 
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:481 +0x127                                                        
github.com/tiancaiamao/shen-go/runtime.(*VM).Run(0xc0001ce0a0, 0xc000283bc0, 0x4, 0x4, 0x0)                                             
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:146 +0x5c                                                         
github.com/tiancaiamao/shen-go/runtime.(*VM).Eval(0xc0001ce0a0, 0xc000283920, 0x0)                                                      
        /home/tim/go/src/github.com/tiancaiamao/shen-go/runtime/vm.go:577 +0x117                                                        
main.main()                                                                                                                             
        /home/tim/go/src/github.com/tiancaiamao/shen-go/cmd/shen/main.go:58 +0x664                                                      
                                                                                                                                        
panic                  
@tiancaiamao
Copy link
Owner

Thanks for your report, I'll take a look. @dysinger

@tiancaiamao
Copy link
Owner

I find it's not the problem of shen-go.
I try the standard common lisp implementation, it also fail.
So maybe there is something wrong with https://github.com/vasil-sd/shen-libs (it's pretty old and I'm not sure it's actively maintained), or something compatibility problem with the recent shen source
@dysinger

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants