/[webpac]/branches/hidra/parse_format.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /branches/hidra/parse_format.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 170 by dpavlin, Sun Nov 23 15:42:16 2003 UTC revision 187 by dpavlin, Sat Nov 29 18:58:34 2003 UTC
# Line 80  sub parse_iso_format { Line 80  sub parse_iso_format {
80                          # this might be our local scpeciality -- fields 10 and 11                          # this might be our local scpeciality -- fields 10 and 11
81                          # (as opposed to 010 and 011) so they are strictly listed                          # (as opposed to 010 and 011) so they are strictly listed
82                          # here                          # here
83                          } elsif ($f =~ s/^(1[01])//) {                          } elsif ($f =~ s/^(1[01]\w?)//) {
84                                  push @fmt,$1;                                  push @fmt,$1;
85                                  push @fmt,undef;                                  push @fmt,undef;
86                          } elsif ($f =~ s/^mfn//i) {                          } elsif ($f =~ s/^mfn//i) {
87                                  push @fmt,'mfn';                                  push @fmt,'mfn';
88                                  push @fmt,'';                                  push @fmt,'';
89                          } elsif ($f =~ s/^([^\d]+)(\d{0,3})/$2/) {                          } elsif ($f =~ s/^([^\d]+)(\d{0,3})/$2/) {
90                                  push @fmt,$1;                                  # still prefix?
91                                    if ($#fmt == 0) {
92                                            $fmt[0] .= $1;
93                                    } else {
94                                            push @fmt,$1;
95                                    }
96                          } elsif ($f =~ s/^([^\d]+\d{0,2})//) {                          } elsif ($f =~ s/^([^\d]+\d{0,2})//) {
97                                  push @fmt,$1;                                  if ($#fmt == 0) {
98                                            $fmt[0] .= $1;
99                                    } else {
100                                            push @fmt,$1;
101                                    }
102                          } elsif ($f =~ s/^(\d{1,2})//) {                          } elsif ($f =~ s/^(\d{1,2})//) {
103                                  push @fmt,$1;                                  if ($#fmt == 0) {
104                                            $fmt[0] .= $1;
105                                    } else {
106                                            push @fmt,$1;
107                                    }
108                          } else {                          } else {
109                                  print STDERR "unparsed format: $f\n";                                  print STDERR "unparsed format: $f\n";
110                                  $f = "";                                  $f = "";
# Line 140  sub parse_iso_format { Line 153  sub parse_iso_format {
153          $display = $prefix.$display.$sufix if ($display);          $display = $prefix.$display.$sufix if ($display);
154          print STDERR "format left unused: [",join("|",@fmt),"]\n" if (@fmt);          print STDERR "format left unused: [",join("|",@fmt),"]\n" if (@fmt);
155    
156  #       print STDERR "display: $display swish: $swish\n";          print STDERR "format: [",join("|",@{$tmp}),"]\n" if (@fmt);
157    
158    #       print STDERR "format: {",$format || '',"} display: {",$display || '',"} swish: {",$swish || '',"}\n";
159    
160          return ($swish,$display);          return ($swish,$display);
161  }  }

Legend:
Removed from v.170  
changed lines
  Added in v.187

  ViewVC Help
Powered by ViewVC 1.1.26