Re: File Handles, Perl Naming, Agglutination in Natural Languages (Partly OT:)
- From: "Veli-Pekka Tätilä" <vtatila@xxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 5 Jul 2006 23:43:15 +0300
ano 4000 rayden crc 2 per linda
[typeglobs]Umm interesting. Is this dirs are files in disguise part of Perl's Unix
open my $handle, $mode, $fileNo, dir handles appear as a special case of file handle, both are
the thing stored in the handle is a whole type glob. Print and other
functions then magically use the file handle portion of that glob.
are directory handles yet another kind of "scalar type"?
accessed through (say) *main::HANDLE{ IO} as the case may be.
heritage? I found it surprising as a user but some Unix man pages includedd
passages like "if a file is a directory" which let me conclude, ok I suppose
that's the case internally.
[Perl naming]
having read Larry Wall's essay on Perl's natural language principles at:
http://www.wall.org/~larry/natural.html
I wonder if Perl 6 will borrow even more from natural languages.
All of my Perl variables and comments are in English so far, though, so I
don't get to use all the fancy suffixes mentioned later on, <grin>. However,
I've tried using a kind of speech-synth friendly Hungarian notation to
denote the perl datatype in some way. I use singular words for scalars if
they aren't references to collections, plurals for arrays and the number 2
(read as the preposition to) to emphasize the kinds of mappings most hashes
are. Sometimes this can get very awkward and I scrap it after all. Hmm,
awkword would that be towards AWK as opposed to say Perlward <smile>?
Finally regarding compounds, I know programmers speaking English as a second
language who like to separate even the words in compounds, preferring to
write $postCard so the naming practices are absolutely clear to everyone.
[natural language OT]
Quite right, things like video card are compounds here but not in English.contains much less compound words than Finnish does. But then again, theHeh, the gluing-together of words is one trait shared by our otherwise
perldocs ues just that and programmres tend to like $hashref better than
$hash_ref.
widely unrelated languages , Finnish and German. It happens in English
In my entirely unqualified opinion, there is aI think I've seen the term somewhere. Let me guess glueing together pieces
tendency in English (rather recent, as languages go), to make more
productive use of agglutination.
Off topic? What's that?
to words to give them new and well-defined meanings. Finnish uses a number
of such suffixes. One of them is sto denoting a collection of things.
"Kirja" (book) "kirjasto" (library), "laiva" (ship) "laivasto"
(both fleat and the Navy), "kone" (machine) "koneisto" (machinery). Needless
to say not all words can be treated like this, even if it would make sense.
--
With kind regards Veli-Pekka Tätilä (vtatila@xxxxxxxxxxxxxxxxxxxx)
Accessibility, game music, synthesizers and programming:
http://www.student.oulu.fi/~vtatila/
.
- References:
- Learning Typeglobs, Symbol Tables and the More Obscure Features?
- From: Veli-Pekka Tätilä
- Re: Learning Typeglobs, Symbol Tables and the More Obscure Features?
- From: anno4000
- Re: Learning Typeglobs, Symbol Tables and the More Obscure Features?
- From: Veli-Pekka Tätilä
- Re: Learning Typeglobs, Symbol Tables and the More Obscure Features?
- From: anno4000
- Learning Typeglobs, Symbol Tables and the More Obscure Features?
- Prev by Date: Re: date format
- Next by Date: Re: Learning Typeglobs, Symbol Tables and the More Obscure Features?
- Previous by thread: Re: Learning Typeglobs, Symbol Tables and the More Obscure Features?
- Next by thread: Re: Learning Typeglobs, Symbol Tables and the More Obscure Features?
- Index(es):
Relevant Pages
|