Dyalog APL versions: Difference between revisions

Jump to navigation Jump to search
593 bytes added ,  21:52, 11 December 2019
Line 24: Line 24:


Identity functions <source lang=apl inline>⊣</source> ([[Same]], [[Left]]) and <source lang=apl inline>⊢</source> ([[Same]], [[Right]]) were introduced. Monadic <source lang=apl inline>+</source>, formerly called [[Identity]], was changed to [[Conjugate]] (a change which did not break backwards compatibility, because prior to the introduction of [[complex number]]s the two functions were indistinguishable). Dyadic functions [[Take]] (<source lang=apl inline>↑</source>), [[Drop]] (<source lang=apl inline>↓</source>), and [[Index function|Index]] (<source lang=apl inline>⌷</source>) were extended to allow short left arguments, matching [[SHARP APL]]'s interpretation of the [[leading axis theory]].
Identity functions <source lang=apl inline>⊣</source> ([[Same]], [[Left]]) and <source lang=apl inline>⊢</source> ([[Same]], [[Right]]) were introduced. Monadic <source lang=apl inline>+</source>, formerly called [[Identity]], was changed to [[Conjugate]] (a change which did not break backwards compatibility, because prior to the introduction of [[complex number]]s the two functions were indistinguishable). Dyadic functions [[Take]] (<source lang=apl inline>↑</source>), [[Drop]] (<source lang=apl inline>↓</source>), and [[Index function|Index]] (<source lang=apl inline>⌷</source>) were extended to allow short left arguments, matching [[SHARP APL]]'s interpretation of the [[leading axis theory]].
A [[primitive operator]] (<source lang=apl inline>⍠</source>) was introduced as an alternative spelling of the existing [[system operator]] [[Variant]] (<source lang=apl inline>⎕OPT</source>), with a functionality similar to one sketched by [[Ken Iverson]] (<source lang=apl inline>:</source>)<ref>Kenneth E. Iverson, [https://www.jsoftware.com/papers/APLDictionary.htm A Dictionary of APL], VI. Conjunctions, [https://www.jsoftware.com/papers/APLDictionary1.htm#colon Custom]. APL Quote Quad, Volume 18, Number 1, 1987-09.</ref> and implemented in J (<source lang=j inline>!.</source>).


The [[Index Generator]] function was changed so that <source lang=apl inline>⍳⍬</source> would return <source lang=apl inline>⊂⍬</source> rather than <source lang=apl inline>⎕IO</source>. The former behaviour was considered a bug because <source lang=apl inline>⎕IO</source> is not a valid [[index]] into an array with [[empty]] [[shape]] (that is, a [[scalar]]).
The [[Index Generator]] function was changed so that <source lang=apl inline>⍳⍬</source> would return <source lang=apl inline>⊂⍬</source> rather than <source lang=apl inline>⎕IO</source>. The former behaviour was considered a bug because <source lang=apl inline>⎕IO</source> is not a valid [[index]] into an array with [[empty]] [[shape]] (that is, a [[scalar]]).

Navigation menu