[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-apl] The ' 2 ⎕TF ' bug, more info
From: |
Christian Robert |
Subject: |
[Bug-apl] The ' 2 ⎕TF ' bug, more info |
Date: |
Tue, 31 Mar 2015 20:52:58 -0400 |
User-agent: |
Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 |
var←'kelvin' (,'v') 'some text'
D var
┌3───────────────────────┐
│┌6─────┐ ┌→┐ ┌9────────┐│
││kelvin│ │v│ │some text││
│└──────┘ └─┘ └─────────┘│
└∊───────────────────────┘
2 ⎕tf 'var'
var←'kelvin' 'v' 'some text'
⍎2 ⎕tf 'var'
D var
┌3─────────────────────┐
│┌6─────┐ v ┌9────────┐│
││kelvin│ │some text││
│└──────┘ └─────────┘│
└∊─────────────────────┘
⍝ Length 1 vectors ( here (,'v') ) have been converted to scalar 'v'
var←'kelvin' (,'v') (0⍴'') (⍳0) 'some text'
D var
┌5───────────────────────────────┐
│┌6─────┐ ┌→┐ ┌⊖┐ ┌⊖┐ ┌9────────┐│
││kelvin│ │v│ │ │ │0│ │some text││
│└──────┘ └─┘ └─┘ └─┘ └─────────┘│
└∊───────────────────────────────┘
⍎2 ⎕tf 'var'
D var
┌5─────────────────────────────┐
│┌6─────┐ v ┌⊖┐ ┌⊖┐ ┌9────────┐│
││kelvin│ │ │ │0│ │some text││
│└──────┘ └─┘ └─┘ └─────────┘│
└∊─────────────────────────────┘
⍝ in fact only Length 1 vectors are affected, length 0 are OK.
ps; copy&paste had problem here because of the horizontal pixel width of '⊖' in
windows
Xtian.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Bug-apl] The ' 2 ⎕TF ' bug, more info,
Christian Robert <=