In article <[EMAIL PROTECTED]>, Brandon
S. Allbery KF8NH <[EMAIL PROTECTED]> wrote:

> File tests are supposed to return something which:
> - behaves as a Bool
> - stringifies as a filename
> - numifies as a file size or as a time, if appropriate
> - propagates a stat object (obviating perl5's magic _)
> Current Pugs only does the first three, sort of:  the size and time  
> operators return numeric, the others string, all behave appropriately  
> if used as booleans.

I'm not sure Pugs does that right. The file named "0" (zero) seems to
behave inappropriately. In this example, "foo" and "0" are real files,
and "not there" is not a file that exists:

pugs> "foo" ~~ :e
pugs> true "foo" ~~ :e

pugs> "not there" ~~ :e
pugs> true "not there" ~~ :e

pugs> "0" ~~ :e
pugs> true "0" ~~ :e

Again, I don't really mind whatever the answer is as long as I can
document it. :)

Reply via email to