kevinlawler / kona

Open-source implementation of the K programming language
ISC License
1.36k stars 138 forks source link

Domain Error (on Windows) #599

Closed tavmem closed 3 years ago

tavmem commented 3 years ago

The project located at https://github.com/tavmem/ks has 2 steps in its description:

kona is reporting a domain error in the second step when using Windows. It works fine on Linux.

$ pwd
/home/tavme/ks
$
$ rlwrap -n ./k > ggg
(.((`a;1);(`b;2)))(,`a)
\\
$
$ rlwrap -n ~/kona/k ps
kona      \ for help. \\ to exit.

domain error
> 
tavmem commented 3 years ago

This was easily resolved with a change to how files are referenced in Windows. In Linux the command to read the relevant file is:

0: `"/home/tom/ks/ggg"

In Windows it is:

0: `"C:/msys64/home/tavme/ks/ggg"

I added a Windows version of the ps.k script called psw.k in the ks project. This issue can be closed.