Closed jordanwhitede closed 6 months ago
Yes! I have been having this issue for a long long time. Have been super puzzled by it. Though I cant reproduce while typing the following:
(
SynthDef('huuuh', {
env = Env.asr(10, 1, 10).ar(Done.freeSelf, \gate.kr(1));
})
)
I have def experienced this with other input in insertmode. Will try and find my notes.. hmm hope is that @davidgranstrom have an idea about whats going on here. I guess its a bug in the line parser?
@jordanwhitede Thanks for the report and the example! I'm aware of the issue and find it annoying as well :)
@salkin-mada Yes, its indeed an issue with the parsing and extraction of the object to get the signature for (the implementation is here)
In a previous version of scnvim the SCNvim.methodArgs
function was using a try
block to suppress the error, however this had strange side effects of (sometimes) handling other unrelated errors down the line, possibly some kind of stack corruption was happening inside the sclang VM, but I never found a good way to reproduce the issue so I left this at the state it is now.
I'll take a look and see if there is an easy fix for this on the lua side, but otherwise I would rather spend time trying to bring the supercollider LSP integration to nvim/scnvim which will solve this issue and provide a lot more and better features.
Describe the bug When using the .ar method on an Env, adding "\gate.kr()" after the (Done.freeSelf) throws the following error:
I've had this on various versions of scnvim, nvim etc and never bothered to report it. It doesn't actually cause any problem, the code still runs, but the error comes every time.
Expected behavior No error message.
Steps to reproduce Within a SynthDef, type
env = Env.asr(10, 1, 10).ar(Done.freeSelf, \gate.kr(1));
I haven't tested this much - it seems to only turn up in SynthDefs though.Information
Operating system arch, but have also had this error with Fedora in the past
SuperCollider version SC3.13.0
nvim --version
0.9.5Package manager vim.lazy