bug-apl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-apl] Messed up indentation with )DUMP


From: Juergen Sauermann
Subject: Re: [Bug-apl] Messed up indentation with )DUMP
Date: Sat, 31 May 2014 16:58:57 +0200
User-agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130330 Thunderbird/17.0.5

Hi Daniel,

I cant confirm this but would need additional information.
A few hints, though:


1. the del editor (∇) removes leading spaces from lines entered:

      ∇foo
[1] 1
[2]  2
[3]   3
[4] [⎕]
    ∇
[0]   foo
[1]   1
[2]   2
[3]   3
    ∇
[4] ∇


This is a bit strange but for IBM APL2 compatibility.


2. The ∇-editor indents lines that are not comments or labels by one space.
This was not so earlier but was requested recently:

      ∇foo
[1] ⍝ Comment 1
[2] L2:   ⍝ Label 2
[3] 3 ⍝ Normal line 3
[4] [⎕]
    ∇
[0]   foo
[1]  ⍝ Comment 1
[2]  L2:   ⍝ Label 2
[3]   3 ⍝ Normal line 3
    ∇
[4] ∇


The same happens if you ⎕FX the function.


3. The ⎕CR should have the function lines un-indented:

      ⎕CR 'foo'
foo             
⍝ Comment 1     
L2:   ⍝ Label 2 
3 ⍝ Normal line 3



4. )DUMP uses ⎕CR for output, so the function in the file should be un-indented:

      )DUMP xxx
      ...
      )HOST cat /home/eedjsa/projects/juergen/apl-1.3/src/workspaces/xxx.apl
      ...
∇foo
 ⍝ Comment 1
 L2:   ⍝ Label 2
 3 ⍝ Normal line 3

      ...

If the file is )LOADed again then foo should look like 2./3.

/// Jürgen


On 05/30/2014 09:33 PM, Daniel H. Leidisch wrote:
Hello!

Workspaces saved with )DUMP mess with my identation. Looking at the .apl
files, some kind of automatic indentation seems to take place, and when
I edit functions, there is no indentation at all. This does not happen
with workspaces saved via )SAVE, or with functions saved via )OUT.

Since some automatic reindentation seems to happen on )DUMP, I am not
sure if this is a bug. Is it expected behavior? If yes, is there a way
to prevent it? I do not want )DUMP to mess with my indentation.


Regards,

Daniel





reply via email to

[Prev in Thread] Current Thread [Next in Thread]