Menu ▾ ▴

#170 Code Formatter - Static Arrays

Closed
closed-wont-fix
None
5
2020-04-13
2019-12-16
Rob Truby
No

The Code Formatter forats static array declarations as array references

Test: array [ 0..4] of Single;

with a space fefore the "[" is formatted the same as

Test[0] := 1;

which does not have a space before "["

Formatting removes the space in the declaration (depending on the options in the spacing tab of the formatter configuration.

Ideally I would like a space beofre the "[" in the declaration but not in the reference. This is not possible in GExperts at present.

In the spacing options it would also be useful to have "No Change" in addition to:

  • None
  • Before Only
  • After Only
  • Before and After

Related

Bugs: #170

Discussion

  • Thomas Mueller

    Thomas Mueller - 2019-12-16

    Is this a bug report or a feature request? If a bug report: What exactly is the bug?
    If it is a feature request, please file it as such.

     
  • Rob Truby

    Rob Truby - 2019-12-16

    My thoughts were that the formatter was not designed to format static array declarations and hence the bug report. But I can post this as a feature request if you prefer.

     
  • Thomas Mueller

    Thomas Mueller - 2020-03-15
    • assigned_to: Thomas Mueller
    • Group: New --> Need_More_Info
     
    • Rob Truby

      Rob Truby - 2020-03-16

      Hi Thomas,

      Thanks for following up - this is minor.

      I normally expect a space between the word array and the square bracket.
      Below is formatting from the Delphi in-built formatter.

      [cid:image001.png@01D5FBB8.574C9A90]

      The GExperts formatter removes this space.

      [cid:image002.png@01D5FBB8.574C9A90]

      Thanks again for all your work.

      Regards,

      Rob

      From: Thomas Mueller twm@users.sourceforge.net
      Sent: Monday, 16 March 2020 1:44 AM
      To: [gexperts:bugs] 170@bugs.gexperts.p.re.sourceforge.net
      Subject: [gexperts:bugs] #170 Code Formatter - Static Arrays

      • assigned_to: Thomas Mueller
      • Group: New --> Need_More_Info
      • Comment:

      Sorry, I still don't understand what the problem is. Could you please give some more context for the examples?


      [bugs:#170]https://sourceforge.net/p/gexperts/bugs/170/ Code Formatter - Static Arrays

      Status: open
      Group: Need_More_Info
      Created: Mon Dec 16, 2019 05:29 AM UTC by Rob Truby
      Last Updated: Mon Dec 16, 2019 11:16 PM UTC
      Owner: Thomas Mueller

      The Code Formatter forats static array declarations as array references

      Test: array [ 0..4] of Single;

      with a space fefore the "[" is formatted the same as

      Test[0] := 1;

      which does not have a space before "["

      Formatting removes the space in the declaration (depending on the options in the spacing tab of the formatter configuration.

      Ideally I would like a space beofre the "[" in the declaration but not in the reference. This is not possible in GExperts at present.

      In the spacing options it would also be useful to have "No Change" in addition to:

      • None
      • Before Only
      • After Only
      • Before and After

      Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gexperts/bugs/170/

      To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/

       

      Related

      Bugs: #170

  • Thomas Mueller

    Thomas Mueller - 2020-03-15

    Sorry, I still don't understand what the problem is. Could you please give some more context for the examples?

     
  • Thomas Mueller

    Thomas Mueller - 2020-04-13
    • status: open --> closed-wont-fix
    • Group: Need_More_Info --> Closed
     
  • Thomas Mueller

    Thomas Mueller - 2020-04-13

    I don't regard this as a bug and don't think I will spend any time on it if it was made a feature request. But feel free to submit a feature request anyway. Maybe somebody else will care enough to implement it (But don't hold your breath for that either, there aren't that many contributors left).

     

Log in to post a comment.