Ticket #4054 (closed defect: fixed)

Opened 8 months ago

Last modified 4 months ago

syntax highlighting for shell is broken since 4.8.24 -rc1

Reported by: wwp Owned by: andrew_b
Priority: major Milestone: 4.8.25
Component: mcedit Version: master
Keywords: syntaxt highlighting shell mcedit Cc:
Blocked By: Blocking:
Branch state: no branch Votes for changeset:

Description (last modified by andrew_b) (diff)

since 4.8.24-rc1 (4.8.23-149-g06bf088bc), the syntax highlighting of shell scripts in mcedit misbehaves around matches of "function blabla()" inside literal quotes. It applies syntax highlighting as if it was function definition in normal conditions (out of literal quotes), breaking the colouring of whatever follows.

The following sample shows the issue:

#!/bin/sh

function foo()
{
   echo "normal color highlighting"
   echo "function bar() abnormal color highlighting"
}

Change History

comment:1 Changed 8 months ago by wwp

Apparently, the default is NOT in sh.syntax, because replacing w/ 4.8.23's one doesn't fix it. If the code for syntax highlighthing in mcedit itself is fault, then it's probably buggy for some other languages.

comment:2 Changed 8 months ago by andrew_b

  • Component changed from mc-core to mcedit
  • Description modified (diff)

comment:3 Changed 8 months ago by andrew_b

Probably, this is a result of #3981.

comment:4 Changed 8 months ago by wwp

Right, I edited my sh.syntax to revert the changes and the issue has gone. Strangely I didn't notice the issue w/ mc 4.8.23.

Last edited 8 months ago by wwp (previous) (diff)

comment:5 Changed 4 months ago by andrew_b

  • Owner set to andrew_b
  • Status changed from new to accepted

comment:6 Changed 4 months ago by andrew_b

  • Status changed from accepted to testing
  • Resolution set to fixed
  • Milestone changed from Future Releases to 4.8.25

comment:7 Changed 4 months ago by andrew_b

  • Status changed from testing to closed
Note: See TracTickets for help on using tickets.