19
$\begingroup$

I was looking forward to the PLDI StackExchange site, but am dismayed to seee that it has fallen victim to Wadler's law:

In any language design, the total time spent discussing
a feature in this list is proportional to two raised to
the power of its position.
           0. Semantics
           1. Syntax
           2. Lexical syntax
           3. Lexical syntax of comments

Indeed, here are the current top questions:

  1. What are some syntax options for generators?
  2. Why do most languages prefer complex enum instead of simple enum?
  3. What are common options for lambda function syntax?
  4. What are some options for syntax for async/await?
  5. What are the pros and cons of dynamic scoping?
  6. What are the syntax options for implementing a ternary "if" operator?

The site should have been called "the concrete syntax of programming languages". I do hope this is just an initial phase, but perhaps there is something we can do to promote the kind of thinking and understanding of programming language design that's actually found at PL conferences and papers. That would presumably do more good to the wider audience than strict adherence to Wadler's law. Or should we just wait until all questions regarding the lexical structure of syntax have been exhausted?

$\endgroup$
8
  • 4
    $\begingroup$ I can feel your pain, but I have two questions: 1) is the type of questions you'd like to see suitable for the Stack Exchange Q&A format and 2) you haven't posted anything yet on the main site. If there is no content that you like, we can't promote it ... $\endgroup$
    – Glorfindel
    Commented May 19, 2023 at 6:54
  • 5
    $\begingroup$ I answered one question, was told immediately it was an invalid answer because I failed to list cons, deleted the question, and am I now waiting to see if contributing to this site is something I can afford to invest my time in. $\endgroup$ Commented May 19, 2023 at 7:00
  • 5
    $\begingroup$ Also, still waiting for PL design question that I can usefully contribut to. When I have PL design questions, I won't ask them here. $\endgroup$ Commented May 19, 2023 at 7:02
  • 5
    $\begingroup$ for a start, you could write the kinds of questions you want to see. $\endgroup$
    – starball
    Commented May 19, 2023 at 7:16
  • $\begingroup$ The dynamic scoping question is a very good one. But more to the point, how does SE rank "top questions"? $\endgroup$
    – Pseudonym
    Commented May 19, 2023 at 9:44
  • 2
    $\begingroup$ 4. Lexical syntax of whitespaces $\endgroup$
    – ice1000
    Commented May 19, 2023 at 19:38
  • $\begingroup$ Theoretical Computer Science is for academics, Computer Science is for students (which saddens me a little, as a professional programmer, I've never managed to steer the site to be more attractive to programmers). It feels like this site is the kiddie space. $\endgroup$ Commented May 21, 2023 at 21:36
  • 3
    $\begingroup$ I think this is just a case of low hanging fruit being asked and answered first $\endgroup$ Commented May 21, 2023 at 22:11

2 Answers 2

4
$\begingroup$

I've waited a while for someone more eloquent than me to speak up but as they haven't you are stuck with me for now.

I have two answers to this one:

  • Don't worry about it
  • Ask Better Questions

Don't worry about it

The syntax of a programming language is its user interface. Some people rightly concern themselves with the surface syntax as programming is fundamentally (from their point of view) a HCI issue.

Lots of questions about syntax does not mean these are the only types of question that will exist here. There is no upper limit to the total number of questions.

We haven't devolved to the level of bikeshedding the one true syntax of comments.

Ask Better Questions

Rather than Wadler's law we should perhaps worry more about the similar Law of triviality.

The risk is the community becoming populated by people concerned with trivial issues like syntax and scaring off important contributions from the more advanced engineering & academic communities.

The way to beat that is to ask enough good questions to keep those people interested in engaging.

Most communities like this will have a range of people with different levels of experience and backgrounds. As long as the mix does not tilt too far one way or the other this one will do fine. I think we have a good mix here currently. I would be sad to lose either half of the community even if that means having to suffer the occasional dumb question about the lexical syntax of comments.

$\endgroup$
7
  • $\begingroup$ I like this answer, although I've decided not to participate in the site. I work on the mathematical side of PL, so all the questions there seem either trivial (concrete syntax, pro-and-cons-to-death), or quite technical and out of my scope. $\endgroup$ Commented Jun 25, 2023 at 15:22
  • 1
    $\begingroup$ That's disappointing. We need you folk too! I find the mathematical questions impenetrable some of the time but I still keep an eye out on CS and proof assistants (which is also in beta). $\endgroup$ Commented Jun 25, 2023 at 17:41
  • $\begingroup$ Proof assistants is not in beta as far as I know, they're just not updating the site style for some reason. And there are only so many things I can do at once. The language design SE just doesn't have questions that I can usefully contribute to. I tried once, gave useful pointers, and was told that "this is not a good answer because you didn't list pros and cons". Thank you very much. $\endgroup$ Commented Jun 25, 2023 at 19:57
  • $\begingroup$ If that was just one user then its no reason to go. If it was the community on the other hand we might have a problem. I wonder if this sort of question is more up your street? languagedesign.stackexchange.com/questions/1657/… $\endgroup$ Commented Jun 25, 2023 at 20:04
  • 2
    $\begingroup$ I am going to demonstrate it by giving an answer which I consider appropriate. $\endgroup$ Commented Jun 25, 2023 at 20:19
  • $\begingroup$ I do hope the community does better than respond with a preverbial raspberry! $\endgroup$ Commented Jun 25, 2023 at 20:23
  • $\begingroup$ This is a good synthesis, especially the point of being swamped by triviality as more of an issue than subject matter per se, and feeding in strong questions addresses that. I think things have been going ok recently There's always going to be a mixture, on multiple dimensions. $\endgroup$
    – Michael Homer Mod
    Commented Jun 26, 2023 at 1:28
8
$\begingroup$

I have also seen "Wadler's law" brought up in the r/ProgrammingLanguages Discord server, and in the #lang-dev channel on the official Rust Discord server, in reference to this Stack Exchange site. So clearly there is a perception that too many questions here are about syntax.

But I can't say I have noticed this as a problem so far. You have pointed at the top 6 questions (why 6?) and four of these are about syntax, while one is about data types and another is about name resolution. But Wadler's law, as stated by the OP, is not about popularity but about quantity, so the fact that the top questions are disproportionately about syntax doesn't tell us about the proportion of questions on the entire site.

At the moment I write this answer, there are 150 questions on the main site, 46 of which contain the word "syntax". Of course, not all questions about syntax will contain the exact word "syntax", and a few questions will contain the word "syntax" despite not really being about syntax (e.g. questions about transforming abstract syntax trees).

But 150 questions is few enough for me to go through all of them to make sure that the tag was applied to all questions where I think it's appropriate; so I did that. There were several questions missing the tag (so I added it) and one or two where I think the tag was misused (so I removed it). I may have missed a couple due to the pagination order changing as I went through, but afterwards there are now 40 questions with the tag. (There were about 35 when I started).

This means approximately 27% of questions on the site are currently about syntax. I also suspect this will tend to go down over time, since it's early days for the site, and syntax questions are the ones that are easier to ask and also the ones most likely to be closed as duplicates in the future once there is an established base of canonical dupe-targets. Even so, 27% is not really that concerning to me.


Update (15th June 2023): I've periodically gone through the list of all questions sorted by date, to make sure that the tag is used where appropriate (in my own judgement). Currently, 66 out of 312 questions are about syntax. That's 21%, so the proportion has indeed fallen, and I suspect it will continue to fall.

$\endgroup$
6
  • 2
    $\begingroup$ In PLDI (the conference), syntax is more like 0.27% of the content (it's certainly markedly less than one paper per year). So 27% here is a massive overrepresentation. $\endgroup$ Commented May 21, 2023 at 21:34
  • 2
    $\begingroup$ @Gilles'SO-stopbeingevil' That's an academic conference so it's not surprising there is much less focus on syntax. But this site isn't trying to be representative of academic research. I'm sure if you compared the questions on Stack Overflow to research papers at a conference on software development, you would find some very drastically different proportions there, too; but Stack Overflow is useful for the people it's supposed to be useful for. $\endgroup$
    – kaya3
    Commented May 21, 2023 at 21:39
  • 1
    $\begingroup$ In any case, Wadler's law as stated in the OP would have us believe 93% of questions are about syntax, and (less hyperbolically) outside of this site I've been told that 50% of our questions are about syntax. If you think the proportion of questions here about syntax should be more like 0.27%, you should make an argument for why you think the site would be more useful in that case, and we can discuss it and come to a consensus. I don't think 27% is a problem for the site given that we have a lot of hobbyists here, and in any case the academics can just ignore the syntax tag if they want to. $\endgroup$
    – kaya3
    Commented May 21, 2023 at 21:44
  • $\begingroup$ FWIW, two days later it's now at ~24%. (I went through the last couple of days of questions and made sure there weren't any missing the tag.) $\endgroup$
    – kaya3
    Commented May 21, 2023 at 21:53
  • $\begingroup$ I think this exercise highlights that "syntax" is not really a good tag for us - those questions really don't have much commonality. The objection was to "list syntaxes for ...", not questions about parsing (which are inherently about syntax in a sense, but not related to the other ones), and not to questions about language features & control structures themselves that happen to have syntax. Perhaps we need syntax-options for the former and either block syntax entirely or reserve it for other syntax questions. The proportion of bikeshed syntax questions would then be even lower. $\endgroup$
    – Michael Homer Mod
    Commented Jun 16, 2023 at 2:01
  • $\begingroup$ @MichaelHomer That's a fair comment; I don't have strong feelings either way but it seems worthy of discussion. $\endgroup$
    – kaya3
    Commented Jun 16, 2023 at 2:04

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .