[Bug-apl] Leftover debug code?

2014-05-28 Thread David B. Lamkins
QuadFunction.cc:1425 ⎕es 'DOMAIN ERROR' error.error_code:'1' at QuadFunction.cc:1425 DOMAIN ERROR ⎕ES 'DOMAIN ERROR' ^

Re: [Bug-apl] PT←⎕NEW Point -- An example lifted from microapl returns value errors.

2014-05-28 Thread David B. Lamkins
That is a language extension specific to MicroAPL. It is not part of either ISO Extended APL or IBM APL 2, which are the references upon which GNU APL is based. The README-7-more-info file in the GNU APL distribution contains links to the reference documents. On Wed, 2014-05-28 at 20:15 -0700, A

[Bug-apl] quad-ET doesn't follow SI

2014-05-28 Thread David B. Lamkins
quad-ET should always reflect the error that caused the top suspension on the SI. When the SI is empty, quad-ET should yield 0 0. ⎕et 0 0 foo VALUE ERROR foo ^ ⎕et 3 1 1÷0 DOMAIN ERROR 1÷0 ^^ ⎕et 5 4 → ⎕et 5 4 ^^ NOTE: should be 3

Re: [Bug-apl] Shouldn't this be a Domain error?

2014-05-28 Thread Elias Mårtenson
No, sqrt(-1) is equal to i. 0J1 is how i is represented in APL. Regards, Elias On 29 May 2014 11:12, "Akiva Avraham" wrote: > ¯1*0.5 > > 0J1 ⍝ Shouldn't this be a Domain Error? > http://www.microapl.co.uk/apl_help/ch_020_020_200.htm > > -- >

[Bug-apl] PT←⎕NEW Point -- An example lifted from microapl returns value errors.

2014-05-28 Thread Akiva Avraham
I am not experienced enough in gnu-APL to determine whether you intend for this type of expression to be executable, so I just bring it to your attention. http://www.microapl.co.uk/apl_help/ch_020_020_310.htm If the arguments contain object (or class) references, the elements are considered equal

[Bug-apl] Shouldn't this be a Domain error?

2014-05-28 Thread Akiva Avraham
¯1*0.5 0J1 ? Shouldn't this be a Domain Error? http://www.microapl.co.uk/apl_help/ch_020_020_200.htm --

[Bug-apl] quad-EC fails with function that doesn't return a value

2014-05-28 Thread David B. Lamkins
⎕fx 'bar' '1' bar ⎕ec 'bar' 1 unexpected result tag 0x56020011 in eoc == Assertion failed: 0 in Function: eoc in file: QuadFunction.cc:1305 Call stack:

Re: [Bug-apl] Revisiting the APL 2 empty-array display behavior

2014-05-28 Thread David B. Lamkins
On Wed, 2014-05-28 at 18:11 -0500, Blake McBride wrote: > Dear David, > > > Thanks for the idiom reference! > You're welcome. :) > > With a lot of respect, I think you missed my point. The APL 1 idiom > works as you want and expect in APL 1, APL 2, and GNU APL. Look > closely at my example.

Re: [Bug-apl] Revisiting the APL 2 empty-array display behavior

2014-05-28 Thread Blake McBride
Dear David, Thanks for the idiom reference! With a lot of respect, I think you missed my point. The APL 1 idiom works as you want and expect in APL 1, APL 2, and GNU APL. Look closely at my example. On the other hand, if it is I who is missing the point (quite possible), please explain. Thank

Re: [Bug-apl] Revisiting the APL 2 empty-array display behavior

2014-05-28 Thread David B. Lamkins
Yes, it is interesting. I now understand that ⍎BS/'expr' is an APL 1 idiom that became obsolete with APL 2. The APL 2 IDIOMS Library[*] offers this instead: fn¨BS/⊂A ⍝ Conditional execution of monadic function. As-is, this is not as general as APL 1's ⍎BS/'expr', but it's still useful. With a h

[Bug-apl] ?(3⍴5) (2 3⍴10) gives a domain error.

2014-05-28 Thread Akiva Avraham
http://i.imgur.com/7vMrDan.jpg ?(3⍴5) (2 3⍴10) DOMAIN ERROR ?(3⍴5)(2 3⍴10) ^^ (3⍴5) (2 3⍴10) 5 5 5 10 10 10 10 10 10 ?(3⍴5) 5 3 4 ?(2 3⍴10) 9 6 5 5 10 7 ?(3⍴5) 30 DOMAIN ERROR

Re: [Bug-apl] quote-quote should display a blank line

2014-05-28 Thread Frederick H. Pitts
Hello David, FYI, Figure 8, on page 49 of IBM's "APL2 Programming: Language Reference" (2nd ed, Feb 1994) says an empty character vector displays as a blank line. Regards, Fred On Tue, 2014-05-27 at 12:32 -0700, David B. Lamkins wrote: > I find this confusing and counterintuitive. > >

Re: [Bug-apl] )COPY copies extra stuff - sometimes

2014-05-28 Thread Blake McBride
Additional information - ∆RD calls no user functions and is not called by any other function. So, ∆RD is not being called in because it is used by another function. Thanks. Blake On Wed, May 28, 2014 at 1:47 PM, Blake McBride wrote: > )CLEAR > CLEAR WS > )COPY Devices ∆SS > SAVE

[Bug-apl] )COPY copies extra stuff - sometimes

2014-05-28 Thread Blake McBride
)CLEAR CLEAR WS )COPY Devices ∆SS SAVED 2014-5-27 2:53:43 (GMT-5) )FNS ∆SS )COPY Devices ∆LP SAVED 2014-5-27 2:53:43 (GMT-5) )FNS ∆LP ∆LPH∆RD ∆SS Where did ∆LPH and ∆RD come from? (Devices is a workspace and not a dump file.) Thanks. Blake

Re: [Bug-apl] Revisiting the APL 2 empty-array display behavior

2014-05-28 Thread Blake McBride
Dear David, Interesting observation. More interesting is how GNU APL correctly handles it. i.e.: ∇test[⎕]∇ ∇ [0] test [1] '1' [2] ⍎0/'test2' [3] '2' [4] '' [5] '3' [6] ⍎1/'test2' [7] '4' ∇ ∇test2[⎕]∇ ∇ [0] test2 [1] 'test2' ∇ test 1 2 3 tes

Re: [Bug-apl] Loading dump files

2014-05-28 Thread Juergen Sauermann
Hi Blake, I have fixed the WSID, see SVN 297. I also aligned some messages. If both an .xml and a .apl file with the same name, a warning is printed and the .xml file is loaded (for backward compatbility). I found the )SAVE message a bit sparse so I took the freedom to be more verbose on )DUMP

[Bug-apl] Revisiting the APL 2 empty-array display behavior

2014-05-28 Thread David B. Lamkins
Now that I can see how printing '' as CR affects a larger program, I've gotta say that I'm stumped as to how this behavior can be considered usable. Specifically, it's now (unless there's a trick I haven't yet discovered) difficult (see below) to silently (i.e. without affecting the display) execu

[Bug-apl] Error message cleanup

2014-05-28 Thread Blake McBride
∇unbox;⎕'∇ Workspace::more_error(): 'UserFunction.cc:179' at Nabla.cc:554 DEFN ERROR+ ∇unbox;⎕'∇ ^ Could probably do without the Workspace:: line. Thanks. Blake

Re: [Bug-apl] )COPY problem

2014-05-28 Thread Blake McBride
The "significantly worse" problem is now fixed, but the original problem (May 27, 2014 at 9:23 PM) remains. Thanks. Blake On Tue, May 27, 2014 at 10:16 PM, Blake McBride wrote: > I just updated to the latest GNU APL. The problem is significantly worse. > Now )LOAD doesn't work either. The

[Bug-apl] Rank error

2014-05-28 Thread Blake McBride
)CLEAR CLEAR WS 1 2 3[2] RANK ERROR 1 2 3[2] ^^ 1 2 3[2 2] RANK ERROR 1 2 3[2 2] ^^ x←1 2 3 x[2 2] 2 2 Of course, they should all work as if they were assigned to a variable first. Blake

Re: [Bug-apl] Loading a dumped file doesn't execute the Latent Expression

2014-05-28 Thread Blake McBride
This issue is working very strange now. When I first tried it it still didn't execute ⎕LX. Then I found this while trying to create a test for you: )CLEAR CLEAR WS ∇test [1] 'Hello World' [2] ∇ ⎕LX←'test' )dump test DUMPED WORKSPACE 'test' TO FILE '/home/blake/workspaces

Re: [Bug-apl] Quad-IO localization problem

2014-05-28 Thread Blake McBride
Looks good. Thanks! On Tue, May 27, 2014 at 11:43 AM, Juergen Sauermann < juergen.sauerm...@t-online.de> wrote: > Hi Blake, > > thanks, fixed in SVN 294. > > /// Jürgen > > > > On 05/27/2014 04:59 AM, Blake McBride wrote: > >)CLEAR > CLEAR WS > ⎕IO > 1 > 'abc'⍳'a' > 1 >

Re: [Bug-apl] Indexed assignment error for characters but not numbers

2014-05-28 Thread Blake McBride
Looks good. Thanks! On Tue, May 27, 2014 at 1:07 PM, Juergen Sauermann < juergen.sauerm...@t-online.de> wrote: > Hi Blake, > > thanks, fixed in SVN 295. > > /// Jürgen > > > > On 05/26/2014 11:01 PM, Blake McBride wrote: > >)CLEAR > CLEAR WS > ⎕IO > 1 > a←b←5 5⍴⍳25 >

Re: [Bug-apl] Parse error

2014-05-28 Thread Blake McBride
Looks good. Thanks! On Wed, May 28, 2014 at 10:44 AM, Juergen Sauermann < juergen.sauerm...@t-online.de> wrote: > Hi Blake, > > thanks, fixed in SVN 296. > > /// Jürgen > > > > On 05/27/2014 12:53 AM, Blake McBride wrote: > >)CLEAR > CLEAR WS > ⎕IO > 1 > (4 5)[1]≥12 > 0 >

Re: [Bug-apl] Patch for ]usercmd

2014-05-28 Thread Juergen Sauermann
Hi David, sorry, no idea where it went. Will be in SVN 297. /// Jürgen On 05/28/2014 06:59 AM, David B. Lamkins wrote: Jürgen, I submitted this patch in a slightly different form once before; it didn't make it into GNU APL. After having lived with the patch for a while on my own system, I'v

Re: [Bug-apl] Restrictions on localization of system variables?

2014-05-28 Thread Juergen Sauermann
Hi David, of course. It came back in SVN 296. /// Jürgen On 05/27/2014 08:18 PM, David B. Lamkins wrote: Thanks. One more thing: quad-IO should be on that list. See UserFunction.cc, around line 252. On Tue, 2014-05-27 at 18:06 +0200, Juergen Sauermann wrote: Hi, thanks, should be fixed in

Re: [Bug-apl] Parse error

2014-05-28 Thread Juergen Sauermann
Hi Blake, thanks, fixed in SVN 296. /// Jürgen On 05/27/2014 12:53 AM, Blake McBride wrote: )CLEAR CLEAR WS ⎕IO 1 (4 5)[1]≥12 0 (⎕TS[4 5])[1]≥12 VALENCE ERROR (⎕TS[4 5])[1]≥12 ^

Re: [Bug-apl] Parse error

2014-05-28 Thread Blake McBride
Additional facts: x←4 5 x[1]≥12 0 (x)[1]≥12 0 (x[⍳⍴x])[1]≥12 VALENCE ERROR (x[⍳⍴x])[1]≥12 ^ ⍴x 2 x[1 2] 4 5 x[1 2][1]≥12 VALENCE ERROR x[1 2][1]≥12 ^ x[1 2][1] 4 ⍴x[1 2][1]≥12 VALENCE ERROR ⍴x[1

Re: [Bug-apl] quote-quote should display a blank line

2014-05-28 Thread Blake McBride
I am not sure I disagree with David, I am just arguing for consistency. Thanks! Blake On Wed, May 28, 2014 at 5:02 AM, Juergen Sauermann < juergen.sauerm...@t-online.de> wrote: > Hi, > > I agree with David that this is counter-intuitive, but I will > make it IBM APL2 compatible. > > /// Jürge

Re: [Bug-apl] quote-quote should display a blank line

2014-05-28 Thread Juergen Sauermann
Hi, I agree with David that this is counter-intuitive, but I will make it IBM APL2 compatible. /// Jürgen On 05/27/2014 11:37 PM, David B. Lamkins wrote: On Tue, 2014-05-27 at 15:19 -0500, Blake McBride wrote: Dear David, First, I assure you, this is how it works. I'm certainly not arguin