16

The tag is used 273 times, but has no usage guidance or tag wiki whatsoever.

The oldest question that has this tag that I can see is a CSS question about shorthand CSS properties from 2009, but the tag has been used many times since on topics varying from C, C#, Flash, Java, PHP, JavaScript, and more.

This indicates that the term "shorthand" is a common theme across programming in general... but is it descriptive enough to cover all of these languages?

Can someone be an expert in programming shorthand in general, or would they necessarily need to be adept at shorthand in a specific language?

While I can't speak to other languages that make use of shorthand, I don't think there is enough specificity or depth to shorthand in CSS that it would call for a tag. However, I think it's reasonable to have a lot of questions about shorthand in various languages...

So, should we simply fill in the tag description for , or should we disambiguate it to various, more specific tags? Or should we burninate it altogether?

7
  • 3
    Could be used to refer to shorthand operators (shorthand assignment operators or assignment operators depending on the language). That would be an on-topic and unambiguous use of the tag.
    – user4639281
    Oct 20, 2017 at 19:36
  • 3
    I've never heard those called "shorthand operators", @Tiny. Is that just a Java thing, I wonder? Not being a Java programmer, the only terms I've ever heard were "augmented assignment" and (more commonly) "compound assignment" operators. Those seem to be the generic computer-science terms, as well. Oct 22, 2017 at 4:39
  • @CodyGray JavaScript actually has 'unofficial shorthands' like rewriting an if/else statement into a ternary operator.
    – roberrrt-s
    Oct 22, 2017 at 5:38
  • 1
    I asked if the name "shorthand operator" was a Java thing. I write C++ code all the time, and have never heard them called "shorthand operators". They are always called "compound assignment operators" or "augmented assignment operators". @msrd0 Oct 22, 2017 at 5:39
  • 2
    @Roberrrt In what way is a conditional operator (which is a type of ternary operator) "unofficial"? It is a first-class feature of the language, and found in plenty of languages other than JavaScript. Oct 22, 2017 at 5:39
  • I'm not familiar with other languages, since I only do web development, and based my comment on this sitepoint.com/shorthand-javascript-techniques
    – roberrrt-s
    Oct 22, 2017 at 5:40
  • 2
    @Roberrrt - All sorts of folks make up idiosyncratic names for things. But terminology only counts as "official" if you find it in a Language Specification, or some other source endorsed by the people as being definitive.
    – Stephen C
    Oct 22, 2017 at 10:53

1 Answer 1

-9

I think the current use is fine as it is. If you have a language specific question, you can also tag it with that. I can imagine a lot of questions from people trying to decipher shorthand code, and usually there isn't much to Google because the shorthand doesn't leave much syntax to search for. Try to search for "?" or ":" or what it means of your margin has two values in css, you just won't get a sensible answer.

5
  • 1
    Hmm, I'm not sure I buy the claim that Googling for shorthand isn't useful: "what is the X operator" returns plenty of useful results. Also "why does my margin have two values" gives stackoverflow.com/questions/819207/… as one of the top results (among other useful links).
    – TylerH
    Oct 22, 2017 at 14:53
  • A question can still contain the word "shorthand" and be found by google - "what is the shorthand for...?", without it being added as a tag. Questions are often (usually?) found by search terms that are not tags Oct 22, 2017 at 23:57
  • A should work if it's the only tag on a question. If it has to be combined with other tags, it's not doing its job properly.
    – CJ Dennis
    Oct 23, 2017 at 0:40
  • Here are two examples of shorthand I have people seen struggling finding the right search terms for: margin: 25px 50px; hasvalue ? openfile() : lognovalue();
    – Leo Muller
    Oct 23, 2017 at 7:12
  • @LeoMuller this still comes back to your definition of shorthand. For example, your second example, a ternary operator, is just a language feature. Your first, the condensed CSS declaration convention for padding, margin and border, also just looks normal to me.
    – Rob Grant
    Oct 23, 2017 at 8:44

You must log in to answer this question.

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