8
\$\begingroup\$

Related:

Code Review is about writing good, efficient and maintainable code. Not always all three at once, but those are the main goals.

Both and should not exist on Code Review in my opinion. Both tags are subtle guides towards a phenomena known as Code Golf. Code Golf is explicitly off-topic according to the help center. The tags are often misused and its very existence is an act of war on maintainable code.

The only use-case it has is already covered with (minimize usage of everything). Another possibility are web-scripts, but whatever can be fixed on those is often done by removing needless repetition (Don't Repeat Yourself: ).

Currently no questions are tagged with . 6 questions exist for . I request both tags to be burninated after re-tagging.

enter image description here

\$\endgroup\$
  • 1
    \$\begingroup\$ "The tags are often misused" - what is this misusage that you speak of? Any example? \$\endgroup\$ – Simon Forsberg Jul 19 '15 at 16:09
  • 2
    \$\begingroup\$ minification has not existed. When a tag has no questions, it is already considered burninated (or just simply never existed, which is more accurate in this case) \$\endgroup\$ – Simon Forsberg Jul 19 '15 at 16:09
  • \$\begingroup\$ For everyone wondering why minification is listed, it came up in chat and I check for it's existence in a wrong way. It does not exist and as far as I (currently) know it never existed. \$\endgroup\$ – Mast Jul 19 '15 at 18:33
12
\$\begingroup\$

Note: Given that doesn't actually exist, this answer will simply focus on .


There are four possible logical uses of :

  1. A compiled language requires a minimal executable size, usually because it's being used in an embedded system.
  2. A client-side web-based language needs a minimal source code size because the source code itself is uploaded to the client (for example, JavaScript).
  3. The user just wants their code size to be smaller for whatever reason.
  4. Code Golf.

So, let's address these points one at a time...


1. Minimize executable size.

Minimizing the size of an executable and minimizing the size of the source code are two drastically different things. Whether I name my variable as i or as numberOfTimesIteratedThroughForLoopAtLine752, once the compiler gets through with it, the machine code is ultimately going to be the same.

Minimizing the size of your executable is about reducing the number of instructions and has nothing to do with how many lines (or characters) are in your source code file. Using for these questions is arguably misleading. Moreover, outside deploying to embedded systems, worrying about the size of your executable isn't something that gets done any more these days. And if it is something you're worried about, your question isn't likely to be a good fit for Code Review. Instead, you probably need to think about your applications design from a bigger picture and probably formulate a question that's a good fit for Programmers.

So, for a question that's about minimizing the executable size of your program:

  • is misleading.
  • probably covers it.
  • If doesn't cover it, your question probably isn't a good fit for Code Review. You probably need to ask more of a whiteboard type question.

2. Shrinking interpreted script sizes.

Minification is the process of shrinking the size of your source code in order to optimize the process of transferring it over the Internet (that's a rough/broad definition). It's a very real and very important part of optimizing code for client-side languages like JavaScript.

Arguably, this would be an appropriate use-case for . However, creating & using might be more appropriate. It's more specific, and to me, it seems to make it more clear that this tag is for discussing a very real constraint on code. More importantly, proper moderation of the tag could mean it's only allowed to be used in cases where it makes sense (effectively, when we're talking about interpreted language scripts that need to be smaller so they can be transferred more efficiently).


3. Asker just wants less source code.

While this is a logical use of the tag, it's not an appropriate use of the tag. Using the tag in this way is using it as a meta tag, and we don't allow meta tags.

One of the most common ways to reduce the amount of source code is through effective refactoring, and applying "DRY" principles. Well, guess what? doesn't exist, and has already been burninated (as a meta tag).

While there's nothing wrong with asking for help reducing your source code size (generally speaking), you shouldn't be using tags to communicate that desire.


4. Code Golf

Again, code golf would be a logical use of the tag, but it can't be an appropriate use of the tag, as questions asking for help golfing code are all off-topic. So this will never be a valid use of for Code Review.


So in summary, really, the only valid use of would be for questions asking for help minifying their code. Yet by my eyes, of the 6 total questions tagged , none of them are actually asking about this.

Given that there are only six, we could simply clean this tag up manually. Without making any edits myself, here are my recommendations for the six questions (domain experts should handle these at their own discretion):

Java:

PHP:

  • PHP cron job for updating broadcast status - Again, none of the plain-English on this question makes it clear at all why it should have the tag. PHP is a server-side language, so this isn't a minification issue. It seems most likely, the tag simply exists because the user was trying to add and stumbled across in the auto-complete list (and the asker is looking for any optimization). Seems like a meta use, so we can probably simply remove the tag from this question.

TI-Basic:

  • Roman numeral to decimal converter - This question actually is explicitly asking for optimizing the code for size. However, that doesn't make it any less of a meta tag. I don't know anything about TI-Basic. Presumably this is for or related to TI calculators? I'm not going to make the case for using the tag or simply removing the tag. But either way, I can't see a strong case for here. If there are any domain experts for TI-Basic, please advise or take appropriate action.

C:


Once these six usages of the tag are cleaned up, the tag will simply cease to exist. We will only have to worry about it again if someone else creates it.

\$\endgroup\$
  • 1
    \$\begingroup\$ If I've somehow missed a logical use-case for the tag, please let me know. \$\endgroup\$ – nhgrif Jul 19 '15 at 18:31
  • \$\begingroup\$ I was browsing through the Qs earlier and the only one I'm sketchy on is the TI-80 question. It has similar constraints as embedded programming, but really isn't embedded programming. Not sure what to do with that one, but I think this tag needs burnt. I'm also undecided about creating a "minification" tag, but I suppose we can cross that bridge if it ever really comes up. \$\endgroup\$ – RubberDuck Jul 19 '15 at 18:37
  • 1
    \$\begingroup\$ Right. This meta question is strictly for [code-size-optimization]. Minification is the only valid use for the tag I could possibly imagine, and yet no one is currently using [code-size-optimization] on any questions that would otherwise be tagged [minification]. We can talk about [minification] as a tag if it's ever created. \$\endgroup\$ – nhgrif Jul 19 '15 at 18:40
  • 3
    \$\begingroup\$ Two things - in almost all cases where minification is useful (like Javascript client code), there are tools that are used to do the minification for you, and the "source code" is not the minimized code, but the pre-processed code. As a result, the minimized code is not suitable for review. In the event though, that your program is specifically about processing pre-minimized code to minimized code, and, if there's a reasonable number of questions with a similar theme, then the "minimization" tag may become useful to represent the "task" that the code is doing, not the "type" of review \$\endgroup\$ – rolfl Jul 20 '15 at 17:33
  • \$\begingroup\$ Right... this answer isn't really about [minification]. \$\endgroup\$ – nhgrif Jul 20 '15 at 19:29

You must log in to answer this question.

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