Notepad ++不喜欢这段代码,但它运行正常

时间:2015-02-19 03:18:23

标签: perl notepad++

use warnings;
use strict;    

my $GUID_char4 = qr/[A-F0-9]{4}/;
my $GUID = qr/$GUID_char4{2}-$GUID_char4-$GUID_char4-$GUID_char4-$GUID_char4{3}/;
my $date = qr/\d{4}-\d{2}-\d{2}/;
my $time = qr/\d{2}:\d{2}:\d{2}/;

sub write_to_file
{
    my ($src) = ($_[0]);
    $src =~ s/($GUID)\s*($date)\s*$time\s*//; //Notepad++ really doesnt like this line and highlights it in read
    print "writing $1 to $2 folder \n$src";

}

因此,在上面的摘录中,Notepad ++不知何故不喜欢它并继续突出显示我用红色注释的行。

我的代码有问题吗?

0 个答案:

没有答案