Audacity Bug Summary
••• Introduction •••
••• Keywords •••
    Audacity 3.0.3 development began 19th April 2021

Audacity Bugzilla



Bug 1573 - Multi-line SAL scripts fail in Nyquist Prompt
Multi-line SAL scripts fail in Nyquist Prompt
Status: RESOLVED QUICKFIXED
Product: Audacity
Classification: Unclassified
Component: Nyquist
unspecified
Per OS All
: P4 Repeatable
Assigned To: Steve Daulton
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2017-01-03 06:42 UTC by Steve Daulton
Modified: 2018-08-20 11:46 UTC (History)
6 users (show)

See Also:
Steps To Reproduce:
Release Note:
First Git SHA:
Group: ---
Workaround:
Closed: 2018-08-20 00:00:00


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Steve Daulton 2017-01-03 06:42:35 UTC
Reported on Audacity 2.1.2, Mac OS X 10.11.6
Also occurs on Audacity 2.1.3 alpha, Debian Stable.

Multi-line Nyquist input with SAL syntax doesn't work.

Example:

define variable myosc = hzosc(300)
return myosc

Error: Your code looks like SAL syntax, but there is no return statement etc.

trying:

define variable myosc = hzosc(300) return myosc

works fine.

Workaround (tested on Debian with Audacity 2.1.3 alpha):

Make the code type explicit by adding the ;codetype
header as the first line. Example:

;codetype sal
define variable myosc = hzosc(300)
return myosc
Comment 1 Steve Daulton 2017-01-03 08:16:04 UTC
(In reply to Steve Daulton from comment #0)
It looks like this bug crept in with the new Effect UI
https://github.com/audacity/audacity/commit/8fbfa460c

Assigned to myself.
Comment 3 Gale Andrews 2017-03-10 19:53:33 UTC
The statement that failed and its two workarounds work for me on Ubuntu 14.04 and  Sierra 10.12.3.