therium:
--------------------------------------------------------------------------------
Win 7 with PSPad 4.5.7 

This will help explain it: http://imgur.com/3wW1tK8

Double quotes in a Perl regex do not have to be escaped. So the Perl highlighter
in PS Pad does not work correctly. Since I have an odd number of double quotes,
PSPad thinks everything after the third quote is in a string. 

Example: $s=~s/""/"/g; # Not highlighted properly

If I escape the double quotes, PSPad highlights properly. But not sure if my
program would work right then. 

Example: $s=~s/\"\"/\"/g; # Highlighted properly but may not work in Perl

I deal with a lot of spreadsheet data which, when saved as a text file, inch
marks come out as 2 double quotes. So I have to change each pair of double
quotes to one dbl quote. 

Thanks!
--------------------------------------------------------------------------------


Hi,
there are indeed some problems in highlighting these kind of cases.
The autor of PSPad could say, whether it is fixable in the current state,
but you can generally work around it by placing another quote in the nearest
suitable position, e.g. at the end of the offending line - of course, as a
comment,

I believe, escaping with \ directly in the regex pattern should work here too -
I don't know perl, but as far as I know, in regex the backslashed characters
should behave the same like the "raw" ones, unless they are defined escape
sequences - in regex like \w or in the string literals - which \" shouldn't be.

hth,
   vbr

-- 
<http://forum.pspad.com/read.php?2,62228,62232>
PSPad freeware editor http://www.pspad.com

Odpovedet emailem