News for hackers. Stuff that matters.
Re:Is the C++ preprocessor still needed? by jordigh on Tuesday May 09, 2017 @08:20PM (#14304994)
I have to comment on this, even though it's almost completely irrelevant to the blog post. I saw "do_sth" so I wanted to check where the writer was from. Germany. Aha. :-)

I love how reliably abbreviating "something" (e.g. "sth", "smth" or "sthg") indicates that the person isn't from an English-speaking country. I wonder why this abbreviation has never caught on in English-speaking countries. I think the abbreviations got popularised in non-English-speaking countries by English dictionaries.

I think the more common idiomatic "abbreviation" would be "do_stuff" when you don't want to type out or say "something".

Re:Is the C++ preprocessor still needed? by kobeya on Tuesday May 09, 2017 @11:02PM (#14305625)
Because as you point out yourself, there really is no need for that abbreviation. You could say "do_stuff" and it would have approximately the same meaning, but not be an undecipherable, ambiguous abbreviation.
Re:Is the C++ preprocessor still needed? by stingraycharles on Wednesday May 10, 2017 @02:11AM (#14306235)
Yes, but it's not the only occasion it's being used. "That must be a bug or sth" is another possibility, for example.
Re:Is the C++ preprocessor still needed? by kobeya on Wednesday May 10, 2017 @05:55AM (#14307071)
That "or sth" seems entirely superfluous.
Re:Is the C++ preprocessor still needed? by gjm11 on Wednesday May 10, 2017 @06:41AM (#14307216)
"That must be a bug, or the result of hardware failure, or an erroneous report from the user, or maybe there's some other possibility I haven't thought of."
Re:Is the C++ preprocessor still needed? by kobeya on Wednesday May 10, 2017 @08:07AM (#14307531)
That would be "something else." The else is important.
Re:Is the C++ preprocessor still needed? by gjm11 on Thursday May 11, 2017 @10:59AM (#14316475)
And implicit when someone ends a sentence with "or something".
Re:Is the C++ preprocessor still needed? by gjm11 on Wednesday May 10, 2017 @06:40AM (#14307212)
I'm a native anglophone living in the UK. I abbreviate "something" as "sthg" sometimes. I wouldn't do it in a function/variable/method/class/... name, but then I don't think I'd use "something" as part of such a name in the first place in anything I wasn't very confident would only ever be throwaway code.
Re:Is the C++ preprocessor still needed? by jordigh on Wednesday May 10, 2017 @07:19AM (#14307348)
Given the timestamps of the two English respondents in favour of "sth", I am tempted to amend my hypothesis to say it's a European thing, and more predominant in continental Europe.
Re:Is the C++ preprocessor still needed? by nscalf on Tuesday May 09, 2017 @08:31PM (#14305054)
I'm sure it's not valid across the board, but most of the internet shortenings that we use in english are acronyms---lol, stfu, wtf, rofl, hbu, asl, etc. I'm actually having a hard time thinking of some common abbreviations. I guess "func" short for "function" is a common example.
Re:Is the C++ preprocessor still needed? by dyarosla on Tuesday May 09, 2017 @08:46PM (#14305100)
Programming has plenty of common abbreviations: obj, str, char, btn
Re:Is the C++ preprocessor still needed? by Jach on Tuesday May 09, 2017 @09:29PM (#14305271)
Plus old programmers had to pay a heavy vowel tax so many, even unnecessary, abbreviations stick with us. I worked with an older guy on a game once, "extern struct CollisionManager g_clisn_mngr" is an example of the sort of things we did...
Re:Is the C++ preprocessor still needed? by japano1se on Wednesday May 10, 2017 @03:09AM (#14306398)
Funny you should say that. I'm from an English-speaking country and I use "sth" a lot.
Re:Is the C++ preprocessor still needed? by tannhaeuser on Wednesday May 10, 2017 @01:29AM (#14306102)
Similarly OT, a pet peeve of mine is how Germans and others consistently pronounce (the eg. SQL datatype) VARCHAR as var-CHAIR or sometimes var-CZAR (war czar, warczaw) when they pronounce CHAR/CHR correctly.
Re:Is the C++ preprocessor still needed? by anonymouz on Wednesday May 10, 2017 @02:54AM (#14306357)
Out of interest, what do you consider to be the correct pronunciation of CHAR? There seems to be considerable variation in how people pronounce it (see e.g. [1,2]). Personally I have always used the '/tʃɑr/' one, and similar for VARCHAR.

[1] https://english.stackexchange.com/questions/60154/how-to-pro... [2] http://www.stroustrup.com/bs_faq2.html#char

Re:Is the C++ preprocessor still needed? by tannhaeuser on Wednesday May 10, 2017 @07:06AM (#14307288)
As in "character" for which CHAR and VARCHAR are abbreviations?

Disclaimer: not an English native speaker

Re:Is the C++ preprocessor still needed? by bastih on Wednesday May 10, 2017 @03:20AM (#14306440)
That's because the English language is a mess with respect as to how something is pronounced.
Re:Is the C++ preprocessor still needed? by w8rbt on Wednesday May 10, 2017 @07:41AM (#14307426)
Great point! The words... their, mare, hair, where... all rhyme in English. This drives Spanish speakers crazy.
Re:Is the C++ preprocessor still needed? by tmsldd on Wednesday May 10, 2017 @08:35AM (#14307659)
Or because it behaves just like a pidgin..
Re:Is the C++ preprocessor still needed? by jsolson on Wednesday May 10, 2017 @03:03AM (#14306381)
We're going with VAR-care and care as correct pronunciations of both, right? Asked as a native US English speaker.
Re:Is the C++ preprocessor still needed? by w8rbt on Wednesday May 10, 2017 @07:45AM (#14307448)
I've never heard it pronounced that way, although 'care' is how the first syllable in the word 'character' is pronounced.

I've always heard it pronounced var char (the parts rhyme). Char is pronounced like when you burn/blacken a steak. "Char-grilled food is cooked over or under direct heat so that its surface becomes slightly black"

Re:Is the C++ preprocessor still needed? by Keyframe on Wednesday May 10, 2017 @09:55AM (#14308178)
Logic dictates it should be pronounced as char-acter, but my brain brings out char-coal always.
Re:Is the C++ preprocessor still needed? by gpvos on Wednesday May 10, 2017 @03:33AM (#14306490)
I'm Dutch, so I pronounce it with a hard ch as in loch, even when speaking English.
Re:Is the C++ preprocessor still needed? by tgb on Wednesday May 10, 2017 @09:35AM (#14308018)
If I'm understanding you correctly, then most English speakers would call that correct. It's short for "character" so is pronounced as the first syllable of that (with a hard 'ch') not like the word "char" is pronounced. I think I personally would swap between the two fairly randomly, probably due to learning to code from text-based sources and not hearing it pronounced till much later.
Re:Is the C++ preprocessor still needed? by gpvos on Wednesday May 10, 2017 @07:29PM (#14312669)
To be clear: I do not mean the /k/ sound, but the /x/ or /χ/ (voiceless velar/uvular fricative), which is seldom used in English, except when properly pronouncing the names of Scottish lochs, or the name of J.S. Bach. Maybe it's not even used at all in English, but only in Scottish, but we're getting off-topic already.

If I were consciously trying to pronounce "char" as an English speaker would, I would probably say /tʃɑr/.

Re:Is the C++ preprocessor still needed? by tgb on Wednesday May 10, 2017 @07:57PM (#14312824)
Interesting; I pronounce "loch" as "lock" and Merriam-Webster seems to agree. https://www.merriam-webster.com/dictionary/loch I guess you're referring to the UK pronounciation listed here instead? http://dictionary.cambridge.org/us/pronunciation/english/loc...
Re:Is the C++ preprocessor still needed? by gpvos on Wednesday May 10, 2017 @08:10PM (#14312886)
I thought the use of the specific word "loch" would have been clear enough, but apparently the pronunciation of that word I thought I'd heard a lot on the BBC is not known as widely as I thought. Maybe I'm misremembering. None of the pronunciations you linked to is what I intended. See https://en.wikipedia.org/wiki/Voiceless_velar_fricative or https://en.wikipedia.org/wiki/Voiceless_uvular_fricative , as well as https://en.wikipedia.org/wiki/Scottish_English#Phonology .
Re:Is the C++ preprocessor still needed? by santaclaus on Tuesday May 09, 2017 @11:26PM (#14305700)
I'm partial to usw