bugGNU nano - Bugs: bug #46799, the formatter leaves curses mode...

 
 

bug #46799: the formatter leaves curses mode unnecessarily

Submitted by:  Benno Schulenberg <bens>
Submitted on:  Sun 03 Jan 2016 08:49:44 PM UTC  
 
Severity: 3 - NormalStatus: Fixed
Assigned to: Benno Schulenberg <bens>Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Thu 11 Feb 2016 05:02:20 PM UTC, comment #2:

Changed in SVN, r5632.

The formatter no longer leaves curses mode, and if the formatting program prints any error message (gofmt then has a return value of 2), it allows the user four seconds to look at them. (She can always press ^T again if she wants to see them again.)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Fri 29 Jan 2016 08:58:10 PM UTC, comment #1:

Chris? Can you comment on this?

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Sun 03 Jan 2016 08:49:44 PM UTC, original submission:

Hi Chris,

The function do_formatter() does an endwin(), but the comment at the start of the function says that the formatter is expected to run non-interactively. If the latter is the case, the formatter will not need the screen and endwin() is unneeded. Also, endwin() occurs right after a doupdate(), meaning that it annihilates whatever doupdate() put on the screen -- which is the message that the formatter is being started.

For both those reasons I want to get rid of endwin() in do_formatter(). Is it just a leftover from the mashup when you created the function, or... does it need to be there because the formatter for Go is somehow interactive after all?

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by bens (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 13 Feb 2016 10:35:30 AM UTCbensOpen/ClosedOpen=>Closed
    Thu 11 Feb 2016 05:02:20 PM UTCbensStatusNeed Info=>Fixed
      Assigned toNone=>bens

    Back to the top


    Powered by Savane 3.1-cleanup1