idris-vimscript
idris-vimscript copied to clipboard
Compile Idris to Vimscript, like you always wanted.
This modifies the code generator to perform TCO directly, and removes the separate TCO pass. I plan on continuing from here when trying out `LDecl` IR instead of `SDecl` (see...
The first field of `SApp` in `SExp` marks tail calls. Could we use this and do TCO directly in the `CodegenVim` module?
Currently we only support regular variables with the sigils `[glsa]:`, but we will need to access registers, options, and environment variables (with `@`, `&`, `&[gl]:`, and `$`).
Currently, the code generator outputs Vim functions with horribly long names, leading to code like ```idris function! s:Idris_PreludeziInterfacesziPreludeziShowziz40UPreludeziInterfacesziOrdzdPrecZCznzgzeZC0_2(a,b) let l:c = s:Idris_PreludeziInterfacesziPreludeziShowziz40UPreludeziInterfacesziOrdzdPrecZCzncompareZC0_2(a:a,a:b) if l:c[0] == 2 let l:c = [1]...
Oskar and I discussed this over DMs already. One idea that came up was @owickstrom's "org-mode light". Investigate.