fixes for Linux nvim support
Some checks failed
Publish Playground / build (push) Has been cancelled
Publish Playground / deploy (push) Has been cancelled

This commit is contained in:
2026-02-27 21:53:56 -08:00
parent 2075f2dfc3
commit ea7ba4ea40
2 changed files with 6 additions and 4 deletions

View File

@@ -388,10 +388,12 @@ class HasIO (m : U → U) where
instance HasIO IO where
liftIO a = a
-- NB console.log is _not_ always synchronous
-- https://nodejs.org/api/process.html#a-note-on-process-io
-- But writeSync(1, ...) adds noise to LSP on linux
pfunc primPutStrLn uses (MkIORes MkUnit) : String IO Unit := `(s) => (w) => {
// https://nodejs.org/api/process.html#a-note-on-process-io
// Previously console.log, but that is _not_ always synchronous
fs.writeSync(1, s + '\n')
//fs.writeSync(1, s + '\n')
console.log(s)
return Prelude_MkIORes(Prelude_MkUnit,w)
}`

View File

@@ -4,4 +4,4 @@ setlocal commentstring=--\ %s
setlocal expandtab
setlocal tabstop=2
setlocal makeprg=build/exec/newt\ %
setlocal makeprg=newt\ %