Show
Ignore:
Timestamp:
06/16/05 13:22:19 (4 years ago)
Author:
ogawa
Message:

Fix a regex bug for split_keywords.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • all-keywords/trunk/all-keywords.pl

    r86 r87  
    6060    $string = lc $string unless $case_sensitive; 
    6161 
    62     # keywords w/o whitespaces 
    63     return split(/\s+/, $string) unless $string =~ m/[[]"';,|]?/; 
    64  
    65     # keywords w/ whitespaces 
     62    # keywords separated by whitespaces 
     63    return split(/\s+/, $string) unless $string =~ m/[\[\]"';,|]/; 
     64 
     65    # keywords separated by non-whitespaces 
    6666    while ($string =~ m/(\[[^]]+\]|"[^"]+"|'[^']+'|[^;,|]+)/g) { 
    6767        my $keyword = $1;