develooper Front page | perl.perl5.porters | Postings from December 2008

Re: [perl #1154] -pi doesn't sanely handle write errors

Thread Previous | Thread Next
From:
Tom Christiansen
Date:
December 1, 2008 21:15
Subject:
Re: [perl #1154] -pi doesn't sanely handle write errors
Message ID:
2836.1228194916@chthon
> So if we had tied eof() processing and READLINE was
> responsive to context, it could work?

I'm wondering about your mood there, Chip.  Not your 
fault, but rather English's, the language being a bit 
defective on ample, separate, distinguishible forms for 
some useful shadings of meaning.  Two possibilities 
arise for valid sequences of tenses, and I don't know 
which to apply here so to suss out your intended meaning:

 1. If <past subj> then <conditional>.

 2. If <past indic> then <past indic>.

If you meant an exhortation, 
	(mode=[optative] subjunctive,
	 "O! If only 'twere so!" or "God grant ..."), 
with a consequent necessarily in the conditional mood:

    eg1: If only READLINE() were responsive to context, 
         then lo! it would work fine.

then your exhortation has long been granted.

If, however, you meant a simple statement of fact
	(mode=indicative, tense=past, voice=active, completedness 
	 or finitude possibly perfect, but more probably imperfect),
which takes therefore a consequent likewise in the past
indicative, not in any subjunctive or conditional mode:

    eg2: If READLINE() was responsive to context in 1994, 
         then I didn't know about it.

Then I'd have to check *when* it became true.  But my 
tests show it's fine now.  

The eof problem may be different.

Allegedly, per perltie(1), the ->EOF() method can be overridden
on a tied handle.  However, I guess you'd need to use the hasargs
part of your frametrace to tell eof from eof().  Maybe.
 
---tom


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About