aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Ankarström <john@ankarstrom.se>2020-11-13 01:52:34 +0100
committerJohn Ankarström <john@ankarstrom.se>2020-11-13 01:52:34 +0100
commitc6888f6ded05885e2572cb1bfac84e4a6b99f8ff (patch)
tree1c0c65a6b2733b78ef3bd486ec10033e956780a8
parentc42f9f0a3eb540da2a46d2d4df4e575f0c3cdc4c (diff)
downloadrf-c6888f6ded05885e2572cb1bfac84e4a6b99f8ff.tar.gz
add field m (misc)
-rwxr-xr-xrf6
1 files changed, 3 insertions, 3 deletions
diff --git a/rf b/rf
index c1de63a..0cf92a4 100755
--- a/rf
+++ b/rf
@@ -48,7 +48,7 @@ for (my $i = $#lines; $i >= 0; $i--) {
chomp;
# Reference definition
- if (/^\.R([acdnpqtwy]) +(.*)/) {
+ if (/^\.R([acdmnpqtwy]) +(.*)/) {
my ($fld, $rest) = ($1, $2);
$refi++ if not $refblock; # new reference
@@ -163,8 +163,8 @@ for (my $i = $#r; $i >= 0; $i--) {
sub fmt {
my ($fmt, $i) = @_;
my %ref = %{$refs[$i]};
- for my $fld (split //, 'Aacdnpqtwy') {
- if ($ref{lc $fld}) {
+ for my $fld (split //, 'Aacdmnpqtwy') {
+ if ($ref{lc $fld}) { # interpolate
no warnings;
my $val = $ref{lc $fld};
$val = join '; ', @$val if lc $fld eq 'a';