We have had to activate anti-spam measures.
Only logged in users may comment. Registered accounts may still post anonymously but must first log in and then select anonymous posting. These measures will be revoked as soon as possible
** Some stories will accept AC comments without having to log in. They are marked [* AC Friendly *] This is part of an experiment to assess the practicality of mixed stories. **
[Editor's Note - This story has been moved up the display queue so that new arrivals can see what has been happening. JR 02-07-22 09:52 UTC]
(Score: 0) by Anonymous Coward on Friday July 01 2022, @01:46AM (4 children)
I don't get why people fuss over perl's sigils. They're simpler grammatically than most human languages' gender constructs (la le der die das het den diese etc) since there are actual rules about using them instead of having to memorize lists. It's simpler than having six arbitrary variable names for different aspects of the same function or data set, which (shot of vodka) leads to errors.
(Score: 3, Insightful) by bzipitidoo on Friday July 01 2022, @03:29AM (2 children)
It's redundant, that's why. There are all kinds of ways to assign a type to an identifier that need be done once only. This use of sigils has to be done over and over. It's as if you have to write C like this:
for (int i=99; int i >= 0; int i--){
float a[int i] = 0;
}
A big reason Perl has those '$' characters all over the place is to be like shell scripts. That feature of shell scripting never was a great idea, and should have been dropped.
(Score: 1) by NPC-131072 on Friday July 01 2022, @02:16PM
The dollar symbol identifies a scalar which is a dynamic typed data point -- simultaneously diverse and inclusive. 2/3rds is the best we can do as equality is still lacking in most programming languages. [newdiscourses.com] If SN were rewritten in a Social Justice programming language it would not be possible for fascists to moderate me down!
(Score: 2) by rleigh on Saturday July 02 2022, @11:00AM
The problems go even further though. You can reuse the same name for scalar, array and hash types; probably filehandles as well (it's a while since I've done much Perl, last was the Debian sbuild tool over a decade back). That makes naming potentially very confusing and ambiguous. And on top of that, you use $ when accessing individual array members or hash values, which adds in even more confusion. Perl 6 IIRC fixed the latter.
I used to love Perl, it was a fun language. But some of this stuff was never great. When writing strongly-typed C++ or Java, I've never once thought that sigils would have made the language better. Likewise Python and Lua.
(Score: 2) by tangomargarine on Friday July 01 2022, @06:26PM
I don't get why most of the planet other than English tolerates the conjugation of half their parts of speech either. It's such a pain in the neck to learn.
"Is that really true?" "I just spent the last hour telling you to think for yourself! Didn't you hear anything I said?"