[prev in list] [next in list] [prev in thread] [next in thread]
List: kwrite-devel
Subject: [Bug 88485] New: Perl Syntax Highlighting problem with prototype
From: Art Bugorski <captainpinko () hotmail ! com>
Date: 2004-08-30 22:56:20
Message-ID: 20040830225620.27976.qmail () ktown ! kde ! org
[Download RAW message or body]
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
http://bugs.kde.org/show_bug.cgi?id=88485
Summary: Perl Syntax Highlighting problem with prototype for sub
with $ , & , and *
Product: kate
Version: 2.2.1
Platform: SuSE RPMs
OS/Version: Linux
Status: UNCONFIRMED
Severity: normal
Priority: NOR
Component: general
AssignedTo: kwrite-devel kde org
ReportedBy: captainpinko hotmail com
Version: 2.2.1 (using KDE KDE 3.2.1)
Installed from: SuSE RPMs
OS: Linux
I'm still learning Perl so this could be a misunderstanding on my part but I don't \
think so. I am learning from an older book but the code passes the "perl -c" check.
When creating a prototype for a sub the the highlighter seems to have trouble with \
the characters $ and &.
With the code:
<code>sub greet (;$) {print "czesc!\n";}</code>
the ')' in the "(;$)" is the reddish-brown of the '$' instead of being black like the \
opening bracket. I assuming this is because the syntax highlighter is mistaking the \
"$)" sequence as the special variable <var>$)</var>.
When the '$' is replaced with a ' ' or a '%' the closing ')' is appropriately \
coloured black. However, when if the prototype contains the '&' the '&' is bold and \
black instead of being brown as it should be (I guess anyways since the '$' ' ' and \
'%' are). If a '*' is put in the the place of the '$' it appears as it does normally.
I believe that the prototypes characters should be made the same colours as the \
variables since --while they are not strictly variables themselves-- they are place \
holders for them.
Also, shouldn't there be some kind of effect for the '\' (ie. mandatory variable) and \
';' (ie. all variables from now on are considered optional) symbols? I'd suggest \
simply making them bold. _______________________________________________
KWrite-Devel mailing list
KWrite-Devel@kde.org
https://mail.kde.org/mailman/listinfo/kwrite-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic