Skip to content

Information

THIS DOCUMENT IS STILL UNDER DEVELOPMENT

New Features, Changes, and Enhancements

This page describes the changes and new features in Dyalog v20.0 compared with Dyalog v19.0.

Language Changes

Primitive Functions/Operators

A new primitive operator, behind, has been added. This completes the set of function composition operators, which allow functions to be glued together to build up more complex functions:

  • Glyph: (Classic: ⎕U235B)
  • Derived function equivalence:
    • monadic: (f Y) g Y
    • dyadic: (f X) g Y

System Functions

The following system functions have been added:

  • ⎕SHELL
    This enables execution of external programs with more control and options than ⎕SH/⎕CMD.
  • ⎕VGET
    This enables values to be read for names in a source namespace/namespaces.
  • ⎕VSET
    This enables values to be set for names in a target namespace/namespaces.

The following system functions have been enhanced:

  • ⎕DT
    Additional conversion types have been added:
    • 15 – Go UnixMicro
    • 16 – Go UnixNano
    • 17 – APL+Win and APL64 workspace timestamp
    • 21 – Apollo NCS UUID
    • 22 – OSF DCE UUID
    • 70 – AmigaOS
  • ⎕FSTIE
    A new variant option, Mode, has been added. This specifies the intended purpose of the tie, and can affect when/how errors are generated.
  • ⎕FTIE
    A new variant option, Mode, has been added. This specifies the intended purpose of the tie, and can affect when/how errors are generated.
  • ⎕MKDIR
    A new variant option, Unique, has been added. This specifies whether the base name in the right argument is modified so that the name is unique.
  • ⎕NGET
    If Y is a 2-item vector, the second element (which specifies flags for the operation) can now be set to 2. In this situation, the first element of the result R is a matrix, with each row corresponding to a line in the text file specified within X.
  • ⎕NINFO
    • Several of the properties can now be set by extending the appropriate element in the left argument from a propertyNumber to a (propertyNumber newValue) pair.
    • A new variant option, ProgressCallBack, has been added. This causes ⎕NINFO to invoke an APL callback function as a file operation (for example, a query relating to a file's size, name, or modification date) proceeds.
  • ⎕NPUT
    The single/first element of X (which specifies content) can now be a matrix. In this situation, the resulting text file will include one line for each row of the matrix, with trailing spaces stripped.
  • ⎕NS
    • The left argument X has been extended to allow references to namespaces to be specified. It can also now be an array in which each element identifies a namespace.
    • The right argument Y has been extended to allow references to namespaces to be specified. It can also now be an array produced by the ⎕OR of a namespace.
    • A new variant option, Trigger, has been added. This specifies whether any triggers should be run for the modified variables in the target namespace that have triggers attached.

I-beams

Warning

Any service provided using an I-Beam should be considered as "experimental" and subject to change – without notice - from one release to the next. Any use of I-Beams in applications should, therefore, be carefully isolated in cover-functions that can be adjusted if necessary.

The following I-beams have been added:

  • 13⌶ – Deprecated Features
    Records information in the log file set by 109⌶ about the specified deprecated feature names or keywords
  • 43⌶ – Monadic Operator Generator
    Generates a monadic operator with specified functionality. The functionality is currently limited to creating a .NET-specific operator that can create concrete versions of generic classes and execute generic methods.
  • 109⌶ – Log File for Deprecations
    Manages the file used to log the use of deprecated features.
  • 120⌶ – Generate UUID
    Generates a UUID (Universally Unique IDentifier) according to the RFC 9562 specification.
  • 3535⌶ – Scan For Deprecated Files
    Scans the specified directory (and, optionally, sub-directories) for deprecated saved workspaces, component files, and external variables.
  • 5581⌶ – Unicode Normalisation
    Applies the specified Unicode normalisation form to given character data.
  • 8373⌶ – Shell Process Control
    Provides a way to determine the process IDs of processes started by ⎕SHELL, as well as enabling the sending of signals to any of those processes.

The following I-beams have been removed:

  • 819⌶ – Case Convert (introduced in Dyalog v15.0)
    The functionality provided by this I-beam is available through the ⎕C system function.
  • 8468⌶ – Hash Table Size (introduced in Dyalog v19.0)
    Temporary functionality used for identification of potential side-effects of a change that has now been implemented. No longer relevant.
  • 8469⌶ – Lookup Table Size (introduced in Dyalog v19.0)
    Temporary functionality used for identification of potential side-effects of a change that has now been implemented. No longer relevant.

Syntax Changes

Array Notation

Array notation is a literal syntax for most arrays (including nested and high-rank arrays) and namespaces. Array notation is an extension of APL syntax, and, as such, can be used inside and around all other APL expressions, and wherever an APL expression can appear (for example in the Session, in functions, and in namespace scripts).

You can edit variables using array notation in the following ways:

  • Enter the Edit command (<ED>) from within the Editor.
  • Call the system command )ED and prefix the variable name with a diamond character, for example, )ED ⋄foo
  • Call the system function ⎕ED with a left argument '⋄', for example, '⋄' ⎕ED 'foo'.
  • Set the APLAN_FOR_OUTPUT configuration parameter to 1 (this sets use of array notation to be permanently on)

In addition, in the Microsoft Windows IDE, array notation can be accessed in the following ways:

  • Click the icon in the Session toolbar – this button toggles use of array notation syntax on/off.
  • Click the icon in the Object toolbar when the cursor is over the name of an array – this opens the array in the Editor in the same way as )ED ⋄foo.
  • Click the icon in the Editor's toolbar – this button toggles use of array notation syntax on/off.
  • Select Show as Array Notation from the Editor's Syntax menu – this displays the contents of the Editor using array notation.

User Interface Changes

Inline Tracing

Inline Tracing is an extension to tracing that allows you to step through the execution of individual primitives within expressions, examining intermediate results and arguments of sub-expressions. It enables an in-depth inspection of complex expressions typed directly into the session. Inline Tracing is tracing with the (approximate) granularity of primitives, although it does stop on non-primitives, such as user-defined functions.

Inline tracing can be enabled in the following ways:

  • Enter the Inline Tracing command (<IT>) from within the Session when the cursor is within the expression of interest.

In addition, in the Microsoft Windows IDE, inline tracing can be enabled in the following ways:

  • Click the icon in the Tracer toolbar
  • Select Trace Inline... from the Session's Action menu.
  • Select Action > Trace Inline... from the Session's context (right-click) menu.

Configuration Parameters

The following configuration parameters have been added:

  • APLAN_FOR_OUTPUT
    This displays session output using array notation when possible. The default is 0 (array notation is not in use).
  • DYALOG_SHELL_SUBPROCESS
    This improves the performance of ⎕SHELL on AIX. When set to 1 (the default on AIX), the interpreter starts a (small) child process that handles calls to ⎕SHELL, mitigating some of the performance issues seen on AIX when fork()ing large processes.

Command Shortcuts

The following command shortcuts have been extended:

  • The Redraw Function command (<RD>) will now reformat and indent an array when array notation is switched on (previously this functionality was restricted to functions).
  • The Undo All command (<UA>) will now exit multi-line input (previously this only "unmarked" input lines within multi-line input).

Home and End Keys

The actions of the Home and End keys have been enhanced to provide finer granularity.

When the cursor is placed in a line in the Session:

  • Home moves the cursor left to whichever of these it encounters first from its starting position:
    • the start of the content of the line
    • the six space prompt (except when in the Editor, in which case this is skipped)
    • the left edge of the session
  • End moves the cursor right to whichever of these it encounters first from its starting position:
    • the end of the content of the line excluding space characters
    • the end of the content of the line including space characters
    • the six space prompt (only when the cursor is on a blank line)

Pressing Home or End multiple times progresses through the list in the order shown.

Session Gutter

The left bracket that appears in the Session gutter when entering multi-line input now includes a close icon at the bottom (). Clicking this cancels the multi-line input.

Microsoft Windows IDE

The following changes have been made to the Microsoft Windows IDE:

  • A new menu, Layout, provides options for the location (or undocking) of the Debugger window.
  • A new keyboard shortcut has been added to toggle inline tracing:
    • key code: <IT>
    • keystroke: Ctrl + Alt + Enter
  • A new icon () has been added to the Object toolbar. This enables array notation to be used when editing an object, and replaces the previous Array Editor icon.
  • A new icon () has been added to the Session toolbar to toggle the use of array notation.
  • The Session caption can now include the current thread by adding the {TID} field to the ⎕SE.Caption property.
  • In the Configuration dialog box's Keyboard Shortcuts tab, the Available shortcuts now include function keys (code F1-F48). These can be used in conjunction with ⎕PFKEY to define keyboard shortcuts for function key actions.

TTY Interface

The following changes have been made to the TTY interface:

  • A new keyboard shortcut has been added to toggle inline tracing:
    • key code: <IT>
    • keystroke – terminal emulator under Linux GUIs: <undefined>
    • keystroke – PuTTY terminal emulator: Ctrl + Alt + Enter

Interfaces and Libraries

PCRE Library

The Perl Compatible Regular Expressions (PCRE) library used by the interpreter has been upgraded from PCRE v8.45 to PCRE2 v10.45.

Warning

Some semantic changes introduced with this upgrade could result in unexpected results when using ⎕R, ⎕S, or the search functionality within the Microsoft Windows IDE (and all tools that build on these) compared to results in Dyalog v19.0.

.NET Interface

In .NET, a generic class is a class that has type parameters, which must be given values to create a concrete version of the class. Similarly, a generic method has type parameters which must be specified before the method can be called.

The .NET interface now supports creating concrete versions of generic classes, instantiating them, and calling generic methods. For more information, see the .NET Interface Guide.

The .NET Framework interface does not support generics.