Re: [Csnd-dev] [EXTERNAL] [Csnd-dev] Syntax error with :
Victor Lazzarini <[email protected]> Tue, 28 Oct 2025 10:08:15 +0000
| Newsgroups | gmane.comp.audio.csound.devel |
|---|---|
| Message-ID | <[email protected]> |
Right, I can fix this by adding a rule to catch any misreading of ident: as a label in a ternary expression. I’ve made a PR for it. ======================== Prof. Victor Lazzarini Maynooth University Ireland > On 27 Oct 2025, at 22:36, Eduardo Moguillansky <[email protected]> wrote: > > *Warning* > This email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe. > This line gives an error: > > k2 = k0 > 0 ? k0: -1 > > error: syntax error, unexpected LABEL_TOKEN (token "k0:") from file xxx.csd (1) > > It is ok if the ":" has a space before the variable > > k2 = k0 > 0 ? k0 : -1 > > The code used to work some months ago, so this might be a recent change. I guess it should not be difficult to disambiguate the parsing, since a label should start a line. > > Thanks, > Eduardo > > >