yes, stringy file handles suck and use strict doesn't always protect you from them. And that protection is even inconsistant, as you noted... tye

That's what I wanted to know tye, thanks. That is, I recognized that the behavior I illustrated was caused by the way that the hash was constructed and used, which magnified the ambiguity of globs and strings (which I did to try to clarify my question). My focus was on why the 'protection' of the strict pragma "didn't work" sometimes. I assumed that use strict;, turning on perl's ability to decide the difference between 'F' and *main::F, would always work. When it didn't work with complete consistency, I wanted to understand why.

So, I guess what I've learned from the discussion here is that there are some limits to perl's amazing context sensing abilities, but there is no need to approach that horizon, even when those limits are restrained by strict. Saying more explicitly what I mean can be an important help in assuring that the code will do exactly what I mean

Thanks to all for all of your patience and helpful comments
mkmcconn


In reply to Re: (tye)Re: unexpected close() success on (non-) filehandle by mkmcconn
in thread unexpected close() success on (non-) filehandle by mkmcconn

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.