bugGNU nano - Bugs: bug #56462, justifying snips trailing space...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #56462: justifying snips trailing space when next line begins with dash dash

Submitted by:  Benno Schulenberg <bens>
Submitted on:  Sat 08 Jun 2019 01:34:46 PM UTC  
 
Severity:  2 - Minor Status:  Fixed
Assigned to:  Benno Schulenberg <bens> Open/Closed:  Closed

Sat 08 Jun 2019 03:05:43 PM UTC, comment #3: 

Fixed in git, commit 33fea90b.

This fixes bug #56461 too, which was a different symptom of the same thing.

(Sorry, David, I should have done the bisect first before CC'ing you.)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Sat 08 Jun 2019 02:08:57 PM UTC, comment #2: 

The offending commit is my own, c5a72103: "justify: extend the quoting regex, to cover more types of comments".  Aaah...  It considers a line that starts with dash dash to be a quoted line, and thus it must be a new paragraph.

Okay, "--" as a comment introducer is weird.  Lua users and Postgress users will have to extend quotestr with "--" themselves if they want to be able to rewrap comments.  The "--" string is used too often for other purposes to allow it to disturb justifying.

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Sat 08 Jun 2019 01:47:25 PM UTC, comment #1: 

What happens is that since version 4.0 nano considers a line that starts with dash dash (--) to be the beginning of a new paragraph.  But why?

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Sat 08 Jun 2019 01:34:46 PM UTC, original submission:  

To reproduce, run:

  src/nano --ignore --fill=76 +1622 NEWS

Then type: M-P ^J <Up> <Up> ^J

Note that upon the second ^J, the space after the "the" above the "-T" disappears.  Note also that it does not disappear when using just one <Up>.  Absurd!

Now type a double dash before the word "on" (above "--tabsize") and type ^J.  The space after "the" reappears.  :|  Now type <Up> <Up> <Up> ^J, and the space after "text" disappears!  Perplexing.

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

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

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

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

    Only logged-in users can vote.

     

     

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-06-19 bens Open/ClosedOpen => Closed
    2019-06-08 bens StatusNone => Fixed
        Assigned toNone => bens
    2019-06-08 bens Severity3 - Normal => 2 - Minor
        Summaryjustifying snips trailing space when next line begins with -- (dash dash) => justifying snips trailing space when next line begins with dash dash
        Carbon-Copy- => Added dolorous

    Back to the top


    Powered by Savane 3.5