diff options
author | John Ankarström <john@ankarstrom.se> | 2020-11-11 09:33:26 +0100 |
---|---|---|
committer | John Ankarström <john@ankarstrom.se> | 2020-11-11 09:33:26 +0100 |
commit | 0a2b57c68ee6d159fc9010e30a93da1e39bc35ca (patch) | |
tree | e504b4b5be4bf2e18c1022a1d105b5e2d501a1be | |
parent | 6544282d384e1284b53241c820b17e4f3ad010fe (diff) | |
download | rf-0a2b57c68ee6d159fc9010e30a93da1e39bc35ca.tar.gz |
fix alt inline ref bug
-rwxr-xr-x | rf | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -51,12 +51,13 @@ for (@lines) { $i++; # Inline reference if (/^\.R([fx]) +(.*)/) { + my ($suffix, $prefix, @points); my ($fld, $def) = ($1, $2); - $def =~ s/ ([.,:;\])]) ?([\[(])?$//; - my ($suffix, $prefix) = ($1, $2); + if ($def =~ s/ ([.,:;\])]) ?([\[(])?$//) { + ($suffix, $prefix) = ($1, $2); + } my $winner = 0; my @words = split /\s/, $def; - my @points; # replace '' with preceding word for (@words) { |