[Csnd-dev] Line continuation issue
| Date | 2024-06-11 16:48 |
| From | Dave Seidel |
| Subject | [Csnd-dev] Line continuation issue |
Using develop, this code fails unless I add '\' after each line in the expression:
aout = (adiff * $CTL_COMBOS_DIFF1) + (adiff2 * $CTL_COMBOS_DIFF2) + (adiff3 * $CTL_COMBOS_DIFF3) + (asum * $CTL_COMBOS_SUM1) + (asum2 * $CTL_COMBOS_SUM2) + (aprod * $CTL_COMBOS_PROD) This seems like a regression to me. Is this a known parser issue, or should I make a new ticket? |
| Date | 2024-06-11 16:53 |
| From | vlz |
| Subject | Re: [Csnd-dev] Line continuation issue |
yes, there is a ticket open on that exact issue, #1886 As I said there are a few minor parser issues, and it's good time to figure out if there are others. Prof. Victor Lazzarini Maynooth University Ireland > On 11 Jun 2024, at 16:48, Dave Seidel |
| Date | 2024-06-11 16:55 |
| From | Dave Seidel |
| Subject | Re: [Csnd-dev] Line continuation issue |
OK, cool. This is the only parser issue I've seen. When I add the continuation char (three places in my code), it runs. On Tue, Jun 11, 2024 at 11:53 AM vlz <viclazzarini@gmail.com> wrote: yes, there is a ticket open on that exact issue, |
| Date | 2024-06-11 17:12 |
| From | Victor Lazzarini <000010b17ddd988e-dmarc-request@LISTSERV.HEANET.IE> |
| Subject | Re: [Csnd-dev] [EXTERNAL] Re: [Csnd-dev] Line continuation issue |
|
That's great, thanks. Prof. Victor Lazzarini
Maynooth University
Ireland
On 11 Jun 2024, at 16:56, Dave Seidel <dave.seidel@gmail.com> wrote:
|
| Date | 2024-06-12 20:42 |
| From | john |
| Subject | Re: [Csnd-dev] Line continuation issue |
Some thoughts.....
Looking at Engine/csound_orc.lex in cs6 the lexing of '+' is
"+"{OPTWHITE}"\n"? {
if (UNLIKELY(strchr(yytext, '\n')))
csound_orcset_lineno(1+csound_orcget_lineno(yyscanner),
yyscanner);
return '+';
}
So the whte space after the plus is removed. So Dave's Code becomes
aout = (adiff * $CTL_COMBOS_DIFF1) + (adiff2 * $CTL_COMBOS_DIFF2) +
And so e dse what we get in cs6
. Compare this with the Engine.csound_orc.lex in cs7
On Tue, 11 Jun 2024, Dave Seidel wrote:
> Using develop, this code fails unless I add '\' after each line in the
> expression:
> aout = (adiff * $CTL_COMBOS_DIFF1) +
> (adiff2 * $CTL_COMBOS_DIFF2) +
> (adiff3 * $CTL_COMBOS_DIFF3) +
> (asum * $CTL_COMBOS_SUM1) +
> (asum2 * $CTL_COMBOS_SUM2) +
> (aprod * $CTL_COMBOS_PROD)
>
> This seems like a regression to me. Is this a known parser issue, or should
> I make a new ticket?
>
>
I cannot find the selfsame ode nor a version. cs6 uses more Flex formats
but I think it is lost.
Who wrote the cs7 lexer? Was not me and do not follow it.
On the other hand mu Head is hurting so thinking is hard
==John ff |
| Date | 2024-06-12 21:38 |
| From | vlz |
| Subject | Re: [Csnd-dev] Line continuation issue |
Steven wrote it. Can we add that whitespace removal to it and see if it does the trick? Prof. Victor Lazzarini Maynooth University Ireland > On 12 Jun 2024, at 20:42, john |