[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-apl] Subtle bug in quad-tf
From: |
David B. Lamkins |
Subject: |
[Bug-apl] Subtle bug in quad-tf |
Date: |
Sat, 19 Apr 2014 20:03:49 -0700 |
When using 2⎕tf to encode a nested array in which the last element is a
character array of rank greater than one, the parentheses around the
denotation of that element are incorrectly omitted.
zzzz←'elan' 77 (2 3⍴⍳2)
2⎕tf 'zzzz'
zzzz←'elan' 77 (2 3⍴1 2 1 2 1 2)
zzzz←'elan' 77 (2 3⍴⍬)
2⎕tf 'zzzz'
zzzz←'elan' 77 (2 3⍴0 0 0 0 0 0)
zzzz←'elan' 77 (2 3⍴'ab')
2⎕tf 'zzzz'
zzzz←'elan' 77 2 3⍴'ababab'
zzzz←'elan' 77 (2 3⍴'')
2⎕tf 'zzzz'
zzzz←'elan' 77 2 3⍴' '
The problem doesn't exist when the rank of the final element is less
than two, since no parentheses are necessary to delimit the element's
denotation:
zzzz←'elan' 77 'abc'
2⎕tf 'zzzz'
zzzz←'elan' 77 'abc'
zzzz←'elan' 77 ''
2⎕tf 'zzzz'
zzzz←'elan' 77 ''
- [Bug-apl] Subtle bug in quad-tf,
David B. Lamkins <=