diff options
| author | Teddy Wing | 2021-08-18 01:43:03 +0200 |
|---|---|---|
| committer | Teddy Wing | 2021-08-18 01:43:25 +0200 |
| commit | 990ca11c40881d6c4c407007b045d66b61d979d9 (patch) | |
| tree | 61ba2e940f98b950eab93c20b8c6d1a382c3c245 /incdec.pm | |
| parent | ea3260541f81be7b288c20da920084271625b1a3 (diff) | |
| download | readline-incdec-990ca11c40881d6c4c407007b045d66b61d979d9.tar.bz2 | |
incdec: Add note for myself about what `@-` and `@+` mean
Not what I was thinking when I wrote that looping code.
Diffstat (limited to 'incdec.pm')
| -rw-r--r-- | incdec.pm | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -45,6 +45,7 @@ sub incdec { $point_position = $original_point_position; my @matches = $line =~ /(\d+)/g; print "[[@matches]]"; + # TODO: @- and @+ hold a list of captured groups. You need to loop through matches to get positions for each match with $-+[0]. It doesn't give you a list of positions of all matches. print "-[[@-]]-.+[[@+]]+"; # for (my $i = 0; $i < scalar @+ - 1; $i++) { # print "..$-[$i]:$+[$i]..$point_position.."; |
