Re: MARC::File::XML 0.85

[email protected] (Paul POULAIN)
Newsgroups perl.perl4lib
Message-ID <[email protected]>
Mike Rylander a écrit :
> On 4/13/07, Joshua M. Ferraro <[email protected]> wrote:
>  $parser->{ Handler }{ toMARC8 } = (lc($format) =~ /^unimarc/o || (
> $enc && lc($enc) =~ /^utf-?8$/o )) ? 0 : 1;
> 

mmm... I agree with you.
In fact, I think having a test that, if true make 0 as result and if 
false make 1 is confusing me. The good test is :
"do nothing if we have :
- UNIMARC (that is latin1 or utf8, never marc8)
OR
- marc21 and encoding set to utf8

don't you have something in marc21 to specify marc8 ?
we could simplify the test to something like :
parser->{ Handler }{ toMARC8 } =($enc && lc($enc) eq 'marc8')?1:0;

that would be much more readable


> On a related note, there are several other changes intended improve
> support for UNIMARC authority records.  IIRC, I asked Paul to test
> this, but it's been very hectic recently and I don't recall if he
> responded to me or not.

I've been quite overloaded on the last 2 months (a new boy, thanks to my 
beloved wife...),
  and don't remember the question, so can't say if I answered :-(

-- 
Paul POULAIN et Henri Damien LAURENT
Consultants indépendants en logiciels libres et bibliothéconomie 
(http://www.koha-fr.org)
Tel : 04 91 31 45 19
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.