Hacker News new | past | comments | ask | show | jobs | submit login

But when you talk about Perl stagnating and losing out to other languages, the languages it lost out to were Python and Ruby, which don't require any type notation. It also lost out to PHP, which has sigils, but they don't carry as much information: $foo just means foo is a variable. Perl didn't lose out to C++ and C#; they were never really competing in the same domain.

In Perl, you write:

    my @list = (1, 2, 3);
Whereas in Perl's popular successors, Python and Ruby, you write:

    list = [1, 2, 3]
Saying the former lost out because the @ makes it unreadably terse is nonsense.



>Saying the former lost out because the @ makes it unreadably terse is nonsense.

Well, that's not what I claimed. I also wasn't really focused on "@%$" specifically but you had brought it up so went with it. (I get this weird feeling that I'm discussing with someone who's emotionally invested in Perl and he feels like I'm bashing Perl. Please let's us both stop this and make sure we're talking about Perl in a detached manner.)

Yes, strlen("my @list = (1, 2, 3)") is greater than strlen("list = [1, 2, 3]"). I wasn't talking about that. I was talking about things like strlen("@") < strlen("arraylist"). But... "C# doesn't compete with Perl!". Yes, that's true.

A realistic scenario where perceptions of "@" and "Arraylist" is compared would be a C# programmer working on an ASP.NET website or Javascript programmer working on Nodejs and then the company needs him to go fix an old website that was written in Perl ~15 years ago. The old Perl programmer left and C# programmer is stuck looking at Perl's "line noise". That irritated C# programmer then fills the Stackoverflow survey expressing his "dislike" of Perl. The C# and Javascript looked "readable" but Perl syntax such as "<>" looked like gibberish.


> I also wasn't really focused on "@%$" specifically but you had brought it up

My involvement in this conversation started with quoting you saying that one of the major reasons for Perl becoming disliked was "PERL's usage of sigils.[1] One the one hand, it makes code compact and terse". Perl's use of sigils has nothing to do with terseness, and since Perl lost its mindshare to Ruby and Python which to the tiny extent that sigils contribute to terseness/verbosity are more terse, I don't think that's a valid point about Perl's trajectory.

> I get this weird feeling that I'm discussing with someone who's emotionally invested in Perl and he feels like I'm bashing Perl.

I don't even know Perl, I'm just critiquing your logic.

> Perl syntax such as "<>"

'<' and '>' are not used as sigils in Perl.


>, I don't think that's a valid point about Perl's trajectory.

Again, the "Perl lost to Python/Ruby ... terseness" connection is your narrative, not mine. I feel you have my comments mixed up with someone else.

>'<' and '>' are not used as sigils in Perl.

I agree and I didn't say they were.

That's 3 cases of nitpicking something I actually didn't claim. I can only assume this over-interpretation of things I didn't write is a result of some underlying irritation that I caused. Let's just stop. Peace.


> Again, the "Perl lost to Python/Ruby ... terseness" connection is your narrative, not mine.

Well, if you just weren't considering Python and Ruby, then aren't they counter-examples to your point? They're terser than Perl in that regard; if that's a major reason people moved away from Perl, then why did so many of them move to those languages?

> I agree and I didn't say they were.

Then why did you bring them up in a discussion about sigils?


>They're terser than Perl in that regard;

Again, that wasn't the "regard" I was focused on. It wasn't strlen(Perl_syntax) to strlen(Python_syntax). It's not about counting characters. It was terseness of non-obvious meanings for symbols which reduced readability for many. Yes, "$foo=7" is literally 1 character longer than "foo=7" which seems to violate terseness. (This is the example you seem to always gravitate back to.) For the 2nd time, I'm stressing that I already agree with that definition. However, that wasn't what I was talking about. People unfamiliar with a language that happens to have "ArrayList" spelled out will see as not being as terse as "@". It's a different axis of terseness. This cognitive readability is orthogonal to whether people migrate to Python because it's 1 less character type in front of a variable name.

>Then why did you bring them up in a discussion about sigils?

I wasn't talking about sigils exclusively by that point. I was talking about overall readability and "line noise" to fill out the C# story.


> Yes, "$foo=7" is literally 1 character longer than "foo=7" which seems to violate terseness. (This is the example you seem to always gravitate back to.) For the 2nd time, I'm stressing that I already agree with that definition. However, that wasn't what I was talking about. People unfamiliar with a language that happens to have "ArrayList" spelled out is not as terse as "@".

I gravitate back to sigils because your point, that sigils' terseness contributed majorly to Perl's decline, was all I was objecting to. Python, Ruby, and Javascript don't spell out ArrayList either, yet those languages are now being used in most of the places where Perl used to be used. I ask again, if that was a major reason people left Perl, then why did the people who had that problem move to other languages that are even terser (ie, they don't spell out ArrayList and they don't even use sigils)?


>I gravitate back to sigils because your point, that sigils' terseness contributed majorly to Perl's decline,

I didn't tie sigils to the "decline" -- I tied it to the survey's "dislike". I also didn't claim Perl sigils is what drove Python/Ruby adoption. I never claimed a logical cause and effect between sigils and Perl's decline.

Indeed, the Rust language adds a whole new taxonomy of sigils[1] and it's on the upswing in popularity. (Of course, someone will probably come along and think I claimed that "adding sigils to Rust contributed to its growing popularity".)

The decline of Perl's mindshare for new domains was totally separate from "sigils". The usage decline was a 2nd observation of why Perl topped the charts of "most disliked" languages.

>then why did the people who had that problem move to other languages that are even terser

You're asking that question because you're still focused on only one string length definition of "terse".

Let me try another way:

  strlen(Rust_code) > strlen(Python_code)
... and yet... Rust can still be perceived as more terse than Python. Why? Because special non-obvious symbols that "don't explain themselves" are perceived as terse. This leads to the paradox that adding to the text length makes it more terse. Lastly, not all opinions about Perl's reputation for terseness comes from Python/Ruby programmers.

[1] https://github.com/rust-lang/rust-wiki-backup/blob/master/Si...


> The decline of Perl's mindshare for new domains was totally separate from "sigils".

When you quoted someone saying "how Perl managed to become quite so profoundly disliked" and said "the conspicuous reasons seem to be a combination of: 1) PERL's usage of sigils," I took that to mean you were saying that sigils were a major reason that Perl isn't well-liked by as many people anymore. I'm sorry if that was a misunderstanding.

> Because special non-obvious symbols that "don't explain themselves" are perceived as terse.

The Merriam-Webster definition of 'terse' is 'using few words: devoid of superfluity.' It is not a synonym for noisy. 'my @list' is terser than 'List<T> list,' but both are wordier than better-liked-than-Perl languages like Python, Ruby, and Javascript, which is where Perl's mindshare went (I've been taking that last part as a given). I'm not claiming Perl isn't terse, I'm just saying that it was nonsensical to say that 'PERL's usage of sigils [...] makes code compact and terse.' Compared to C#, sure, but Perl was never competing with C#, and most of the mindshare it used to have didn't go to C#, so it's not really relevant. If the extra terseness (not noisiness) afforded by using sigils was a major reason for Perl's unpopularity, then Python, Ruby, and Javascript's popularity is very strange.

    print while (<>);
Is definitely terser than

    for line in fileinput.input():
        print(line)
But you'll notice there aren't even any sigils in the Perl version.

Sigils being ugly and Perl being too terse might both be problems it has, but they're different issues.


You may have made a mistake linking to this page for Rust; as the URL says, it's a backup: the only ones that exist today are *, &, and ', and the former work the same way they do in other systems languages. (With the exception that & is borrow checked but like, it's a pointer inside, same exact deal.)

We in fact removed these sigils from Rust because user feedback was extremely negative about them, and ' still gets a lot of complaints. Nobody has come up with something better though.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: