Is The C Programming Language Declining In Popularity? (dice.com) 286
An anonymous reader writes:
Java overtook C as the most popular language in mid-2015 on the TIOBE Programming Community index. But now over the last 13 months, they show C's popularity consistently dropping more and more. C's score had hovered between 15% and 20% for over 15 years but as 2016 ended, the language's popularity is now down to 8.7%. "There is no clear way back to the top," reports the site, asking what happened to C? "It is not a language that you think of while writing programs for popular fields such as mobile apps or websites, it is not evolving that much and there is no big company promoting the language."
But the Insights blog at Dice.com counters that TIOBE "has hammered on C for quite some time. Earlier this year, it again emphasized how C is 'hardly suitable for the booming fields of web and mobile app development.' That being said, job postings on Dice (as well as rankings compiled by other organizations) suggest there's still widespread demand for C, which can be used in everything from operating systems to data-intensive applications, and serves many programmers well as an intermediate language."
i-programmer suggests this could just be an artifact of the way TIOBE calculates language popularity (by totaling search engine queries). Noting that Assembly language rose into TIOBE's top 10 this year, their editor wrote, "Perhaps it is something to do with the poor state of assembly language documentation that spurs on increasingly desperate searches for more information." Maybe C programmers are just referring to their K&R book instead of searching for solutions online?
But the Insights blog at Dice.com counters that TIOBE "has hammered on C for quite some time. Earlier this year, it again emphasized how C is 'hardly suitable for the booming fields of web and mobile app development.' That being said, job postings on Dice (as well as rankings compiled by other organizations) suggest there's still widespread demand for C, which can be used in everything from operating systems to data-intensive applications, and serves many programmers well as an intermediate language."
i-programmer suggests this could just be an artifact of the way TIOBE calculates language popularity (by totaling search engine queries). Noting that Assembly language rose into TIOBE's top 10 this year, their editor wrote, "Perhaps it is something to do with the poor state of assembly language documentation that spurs on increasingly desperate searches for more information." Maybe C programmers are just referring to their K&R book instead of searching for solutions online?
In Korea ... (Score:2, Funny)
Re: (Score:2)
Oh good, that means the pay for old programmers will go up again, like it was when the old people were doing the COBOL for the banks and the kids were using C.
The last website I made, it was in C. Welcome to the IoT. Java is too fat to fit on a microcontroller, after all.
I'm using C more and more all the time. I guess I'm getting old.
Actually, when I search for stuff about C, I have to use other search terms, like the library I'm using, because "C" isn't a very unique substring. ;) Sometimes I even have to
Re: (Score:2)
You don't need to use C for IoT. Probably the most interesting IoT SoC vendor around right now (Electric Imp) is using an interpreted language (Squirrel) to enable some pretty low level programming, and make it trivial to develop IoT apps.
We're all programming in Machine Code (Score:4, Insightful)
Re: (Score:2, Interesting)
Your compiler is programming in machine code. You just feed it hints.
Feed your compiler some good hints and it might even write code to use the full width of those vector registers your processor has but you were ignoring.
Re:We're all programming in Machine Code (Score:5, Insightful)
Re: (Score:2)
Re: (Score:2, Redundant)
It is modded-up because it is both correct, and insightful.
...so C++ is technically written in C...
No, it is not "technically written in C." At best you could say "in the past it was written in C." But that statement applies to almost everything, and misses the key point. The key point is that compiler writers have moved from C to C++, even for writing C compilers. That is an important indicator of C's popularity and future.
Re: (Score:2)
I would imagine assemblers are written in C++ as well. Why not?
Re: (Score:2)
I would imagine assemblers are written in C++ as well. Why not?
I'm working my way through an old book to create a Pascal compiler in C. I went with the C edition since it was easier to translate the MS-DOS era code into a modern variant of C than the C++ edition. I'm also learning C to write Python C extensions. Once I'm done with the book, I'll get back to my BASIC compiler in Python.
Re:We're all programming in Machine Code (Score:5, Informative)
C was conceived as a portable shorthand for assembly language. It has evolved into its own beast over the decades - especially when you include C++.
It makes no sense to include C++, just because C++ shares certain elements with C. The design philosophy is completely different. C is a minimalist language. It has acquired more features over the years, like unicode support, but based on demonstrable need. C++ is more prescriptive in its philosophy: these are the features you should be using if you want to be doing object oriented programming.
Re: (Score:2)
The fun thing about C++ is that you can write virtually straight C in it (or, port existing C into it) and it works, well - with tiny adjustments here and there.
Re:We're all programming in Machine Code (Score:5, Informative)
I'm well aware of this, but it doesn't change the fact that C++ is a different language with a fundamentally different philosophy. Adding features to a language is not some kind of neutral operation; it can affect users that have no intention of using those features.
Were it not for operation overloading the argument that C++ is simply C with classes would be a lot stronger. Then if you came across the expression "a + b", you would know it means exactly what "a + b" means in C: either integer addition, floating point addition, possibly with an implicit typecast on one of the operands. In C++ the "+" might be something else altogether; it might even have side effects.
This is neither good nor bad, but it's unquestionably different.
Oh, and by the way, moderators: troll? Really?
Re: (Score:2)
This is neither good nor bad, but it's unquestionably different.
I beg to differ: it IS bad. Because when you read a+b, you have NO idea what may be happening. And this applies to ALL the operators. And the effect of the overloading can be completely different for various types. If participating in the underhanded C contest [underhanded-c.org] is not too hard, there's no need for an underhanded C++ contest because it'd be beating a dead horse.
Re: (Score:3)
I see it as a mixed bag. If you are extending the addition operation to non-built-in types like matrices or complex numbers it's a good thing, although you can obviously screw it up. If you're implementing some kind of Abelian group or algebraic ring it's a good thing. Even if you're just using operator overloading in some way that makes intuitive sense, like string concatenation ("a" + "b" == "ab") or repetition ("a" * 3 == "aaa") or comparison ("a" "b" == true), I see it as a good thing.
But operato
Re:We're all programming in Machine Code (Score:4, Insightful)
I beg to differ: it IS bad. Because when you read a+b, you have NO idea what may be happening
I beg to differ with you!
If you see the function add(a, b), you have NO idea what may be happening. And this applies to ALL the functions. In C++ a+b simply means operator+(a,b) IOW it's a function with a funny syntax just like any other.
And the effect of the overloading can be completely different for various types.
Well of course, adding two floating point numbers is a very different operation to adding two integers. Totally different instructions. The former can even generate a floating point exception and crash your code if you've set the exception flags. And then there's adding two signed inegers. You can always safely add unsigned types. If you add signed ones, overflow invokes nasal demons.
Re: (Score:2)
Adding features to a language is not some kind of neutral operation; it can affect users that have no intention of using those features.
Having had to debug someone's FORTRAN code which just happened to be written in C++[1] I can assure you that some people are quite impervious to language features.
[1] It's the old quote, you can write FORTRAN in any language. Old school numerics types of any age do this.
Re: programming tosh (Score:2)
Rubbish.
Toggled in the binary code for any bootloaders recently? Addressed any registers lately in C? Dealt with any vectorising and prefetching in C in the past week? Inserted an NOP's in C recently to keep nasty timing stuff from hapening?
No? Then you're clearly talking nonsense. The C virtual machine is way different from the processor it targets.
Just as driving a car is different from deali
Re: (Score:2)
No?
Yes.
Re: (Score:2)
A lot of people don't realize it, but even emacs is written in C. That's why it has such a great LISP interpreter!
On microcontrollers it is fairly normal to write the C, and then hand-tune the ASM that gcc outputs.
Re: (Score:3)
This statistic might just mirror my thinking on the "popularity" of C. Are we talking market share, or number of users?
I'd guess that the number of users is remaining constant, or slowly growing. The market for users of programming languages continues to expand rather quickly, so it's entirely possible that C's market share declines while its number of users continues to grow.
Then you have the college grad resume effect: every language they ever wrote two lines of code in ends up on the resume... what doe
Re: We're all programming in Machine Code (Score:5, Insightful)
It's worse than that. Since they base this on Internet searches, which is a metric only an idiot could think is good, you end up in a situation where dumbed down languages used by dumbed down people who are too stupid to even use those without handholding pump up search volume for those very same languages.
Re:Delphi #11's written in Object Pascal (Score:5, Funny)
Calling out MSVC as the reference C compiler for execution speed is like calling out a parade float as the performance reference for internal combustion powered vehicles.
Re: (Score:2)
Oh gosh (Score:2, Insightful)
Not again.
Search engine? (Score:5, Insightful)
Everybody that work recently with C IDE knows that you don't need search the web to find information !
Re: (Score:3, Insightful)
Even without an IDE.
C is simple enough not to need a lot of searching to find out how to do things - unlike nearly all the OO languages.
Assembly got searched for more due to the shift from Intel to ARM. Also searches for Intel assembly grow due to all the crap intel has had to add to a poor instruction design to maintain "compatibility". If the RISC underpinnings of the X86 (both 32 and 64 bit lines) were accessible the speed would increase by 10-15%.
Re: (Score:3)
If C developers aren't searching for C info, they ought to be. People may think that C is simple, but it's full of hidden gotchas.
For example, strncpy() doesn't actually do what any reasonable person would assume it does. Using it in the wrong "obvious" way can result in bugs that won't easily be found during testing. There are hundreds more land mines like that sprinkled throughout the C ecosystem, and they all need to be reviewed repeatedly before one can be considered an experienced developer.
Re: (Score:2)
eh, strncpy() doesn't do what the strncpy(3) man page says it does?
I usually don't need a search engine since I have man pages for common C functions
Re: (Score:3)
That's nice that you have the optional local documentation installed for the C libraries, so you can find out that strncpy() doesn't do what any reasonable person would assume it does without searching the web. (Do you have the POSIX versions installed as well? Sometimes it conflicts with the Linux version, and both can be extremely vague. For those entries, you might have to start searching the web.)
Not to mention that many if not most of the gotchas are in the core language, and man pages won't help you m
Re: (Score:2)
Re: (Score:2)
Well, if you consider the man pages to be vague, maybe C just isn't for you? Maybe you should leave it to the old people, whose understand all that gobblygook.
Also, if you're hitting C language gotchas, rather than library gotchas, you should probably just believe yourself to be less clever, and you'll stop doing it. Clever C code is also known as a bug. Let the compiler do the clever parts unless you're on a microcontroller and then you write the clever parts in ASM.
Re: (Score:2)
For example, strncpy() doesn't actually do what any reasonable person would assume it does. Using it in the wrong "obvious" way can result in bugs that won't easily be found during testing. There are hundreds more land mines like that sprinkled throughout the C ecosystem, and they all need to be reviewed repeatedly before one can be considered an experienced developer.
Knowing the prototype of "char * strncpy(char * dst, const char * src, size_t len);", my assumption would be that strncpy() would copy up to 'len' bytes of data from the 'src' pointer to the 'dst' pointer which probably does not include a NULL terminator if the 'src' string is longer than 'len'. As such, as a programmer I should pass 'dst_len - 1' as 'len' so I can ensure the 'dst' string is NULL terminated by calling "dst[dst_len-1] = '\0';" immediately after calling strncpy().
If this is an unreasonable a
Re: (Score:2)
For any competent coder that understands how the machine actually works, this is a very reasonable assumption. And, in addition, it is documented in the second sentence describing srtncpy in the man-page under Linux, for example. How this can be called "hidden" or even a "gotcha" is beyond me. Of course there is this one large class of incompetents where it is always somebody else's fault.
Re: (Score:2)
"man strncpy" explains the gotchas:
" Warning: If there is no null byte among the first n bytes of src, the string placed in dest will not be null-terminated."
If you think they are "hidden", then you seem to have some problem with reading comprehension. So really, to strncpy one byte longer and zero the last one. If that is beyond your skills, please stay away from C.
Re: (Score:2)
Oh, I do plenty of searching when using C, but I wouldn't be searching for "C" I'd be searching for strncpy examples directly, without talking about C, and most of the results I'd be looking at would be code repos not paste sites.
Also, lot of C questions will actually be questions about make or autoconf.
Re: (Score:2)
"IDE"? What is that? Is that like some poor-man's version of Emacs with man-pages integrated?
Bullshit metrics (Score:5, Insightful)
I don't use much straight C these days (mostly C++ with bits of Python, lua, PHP and other stuff for glue, and occasional C#), but the metric is bullshit. It's a measure of which languages are most suited to passing roadblocks using search queries including the language name. This tends to select for how much a language is used by inexperienced developers.
I'm a pretty experienced C++ developer, so I'm unlikely to be putting C++ in search engine queries. I know the language and library pretty well. If I want to get reference for a particular standard library feature, I'll use a query like, "codecvt site:en.cppreference.com". If I want docs for a Linux feature (e.g. routing sockets or the capabilities API), I'll pull up a man page. If I want to know what some ioctl does and the docs are lacking, I'll look at the Linux kernel source. I'm not typing C++ into google when I'm doing my day job or open source work [github.com]. Same applies for other programming languages I'm competent with. I do bits of assembly language, but I'm not typing that into Google. I have user mode architecture manuals for the processors I need to deal with, and ABI manuals for the operating systems.
On the other hand, I'm far more likely to put the name of a language I'm less familiar with and only use occasionally into a search query when I'm trying to find the conventional way to do something. Something like "C# confirm close modified document window", "python open subprocess stderr", or "php openssl rsa". I'm a clueless goon when it comes to available libraries and best practices for these languages, so I boost their TIOBE rankings on the occasions when I have to use them, while my bread-and-butter C++, assembly language and C don't show up, despite working in C++ for the bulk of my programming time.
actually a good metric (Score:5, Insightful)
Alt: "C doesn't require as much study as others" (Score:2)
A language is thriving or dying by the number of inexperienced developper trying to learn it. If no inexperienced cev learn it... it is dying.
But your thesis ("[web searches for help on a language is] actually a good metric [for language viability]") doesn't follow from that assumption.
Other possible explanations include:
"The C language is easy enough to understand, compared to others such as java, that references to documentation and searches for arcane knowledge about it, even by noobies, are rarer."
"The
Re:Bullshit metrics (Score:5, Interesting)
OTOH when I was writing stuff in Perl or PHP, I was googling stuff constantly because the documentation is online and the sites' search feature sucks.
Re:Bullshit metrics (Score:5, Interesting)
Search engine metrics are also flawed in another way; the worst examples of things often generate a lot of searches, but that doesn't mean they're popular. This metric would tell us that the most popular financial company is Wells Fargo [google.com]. They're at the top because of the news that they created millions of fraudulent accounts, however, and not because they're popular.
Re: (Score:2)
Straight language queries are rare for experienced developers - more telling would be queries for APIs. Even after 10 years using an API, I still google search for how some of the functions work, what's the order of the arguments, what are the available enum options. The API you query often gives away the language you are using.
Re: (Score:2)
If my later query isn't being connected to C++ then the typically more experienced programmers aren't being prop
C is dying... (Score:4, Funny)
Re: (Score:2)
I'll wait for the microfiche at midnight.
Yup, the economy is good. (Score:2)
When the economy crashes again everyone will run back to the old tried and true, because they need to get work done.
This is about the fourth or fifth time I've seen this happen during my career.
Although IMO it would be nice to see something come along that could replace C for, e.g., kernels.
Re: (Score:2)
Thank you Captain Obvious.
You neglected to tell us that C is portable, and assembly is not. One of the big points of the Unix and Linux kernels is that there is very nearly no assembly.
Also I don't really buy your statement that OO languages lack predictability in execution. While I would probably not suggest C++ for a kernel, my use of it – for storage software – did not not exhibit any unpredictability. To be sure, we used a very limited set of C++ features, and perhaps there are features we
I'm seeing a resurgence in C (Score:5, Interesting)
I'm seeing a resurgence in C. It seems to be coming from several different directions.
The first is from people like Mike Acton:
CppCon 2014: Data Oriented Design
https://www.youtube.com/watch?... [youtube.com]
The second is from all the new languages like Go, Rust, Swift. All these new languages need libraries so they all built in good C interoperability so they could be useful immediately without requiring ground up new implementations of everything. So I'm seeing more new pure C libraries being created now than I've seen in a very long time. Library developers know that their libraries will be usable from every language if they write it in pure C.
The third is from IoT. Embedded developers never left C. Now with IoT growing, C lives on.
In all of these cases, they might fly under TIOBE's radar. Most of these people probably don't need to search for C. They already know it and are too busy working on their projects.
Re: (Score:2)
Library developers know that their libraries will be usable from every language if they write it in pure C.
Library developers know that their libraries will be usable from every language if they write it in Rust too. With the added advantage that the code is liable to be far more stable and reliable.
Re: I'm seeing a resurgence in C (Score:2)
Re: (Score:2)
So I'm seeing more new pure C libraries being created now than I've seen in a very long time. Library developers know that their libraries will be usable from every language if they write it in pure C.
But that still marks a shift away from C in "macro" development. C's a good choice for small, self-contained chunks of code that are likely to be reused frequently, but the bulk of dev work is specialised glue logic for a particular app -- probably a Temple Run clone. Nobody's going to write a Temple Run clone in C.
Re:I'm seeing a resurgence in C (Score:5, Informative)
"New languages"?
Pssht! As if!
Man, there's so many varieties of Object-Oriented C you could jizz your pants without even touching yourself.
C is the Primal Language. Before C we have clicks and whistles.
This isn't even a fucking conversation. I'm not hearing what anybody says except my own opinion, because I know my opinion is right, so this isn't a conversation.
What did that dude say in "Fight Club"? "This. Conversation. Is. Over."? Right? Well man thissuh conuhversationuh isuh nottah happenun.
This is some bullshit. Fuck, there are HLA interpreters that are more popular than JAVA -- WITH PEOPLE WHO KNOW HOW TO CODE.
Man this is so much bullshit. I can't believe there's no viewpoint, no slant, no perspective, no synonym of whatsoever with this article.
That's the new owners of Slashdot. This site is dead. If you can diss C because some homie of yours called you up and needed some help raising interest in some particular market, towards a hopeful stock point, maybe on some IPO to come, maybe on something pre-existing, then fuck it, it ain't news any more, man, and it ain't for anybody but the "business school" {nested: "nerds"}.
When you say things like "This isn't even a fucking conversation. I'm not hearing what anybody says except my own opinion, because I know my opinion is right, so this isn't a conversation" and "What did that dude say in 'Fight Club'? 'This. Conversation. Is. Over.'? Right? Well man thissuh conuhversationuh isuh nottah happenun.", It becomes blindingly obvious you are either high on drugs, drunk with some shots I would pay to learn the composition of, or suffer an untreated case of a narcissistic personality disorder combined with the temperament of a three year old, because this is a public. forum, not your personal soapbox. You want to rant on about how unfair a major index has ranked a language you imply you know very little about, without any rational debate, feel free to take it to your Twitter page.
Oh. And uh, while I personally believe it's unethical to provoke those who are (at least at present) mentally incapacitated, I thought I should show you a little what the previous owners of Slashdot, Dice, ran a few years ago. [dice.com] I can sense the sound of your head exploding, eh?
Re:I'm seeing a resurgence in C (Score:5, Informative)
C is the Primal Language. Before C we have clicks and whistles.
Before C we had B, and APL, PL/1, Cobol, and Fortran, just to name a few.
Come up for air sometime, it really helps clear your head.
Re: I'm seeing a resurgence in C (Score:3)
And lisp, don't forget that.
Re: (Score:2)
Before C we had B
Are you Brian Kernighan?
No
Re: (Score:3)
Before C we had B
Are you Brian Kernighan?
No
Brian has a beard. I don't.
My problems programming in C aren't C related. (Score:4, Interesting)
They're much more like: "Why does processor X on board Y rev1 have I2C on those pins, but on rev2 accessing those causes a reboot. Who thought that was a good idea? Can I LART them? And how can I detect board version in software?"
Re: (Score:3)
And how can I detect board version in software?
Try accessing the I2C pins. If you get a reboot then you know you're on rev 2.
The problem with the metric (Score:4, Informative)
"i-programmer suggests this could just be an artifact of the way TIOBE calculates language popularity (by totaling search engine queries). "
The TIOBE index is not based on the number of queires (see http://www.tiobe.com/tiobe-ind... [tiobe.com]).
It is based on the number of results on the query " programming" in multiple search engines.
So the TIOBE index is "how much has been written online about "
Does it really matter? (Score:2)
C isn't really used / chosen any more to participate in the international dick-waving contest. I hope in many ways C is falling out of favour with people just trying to "be cool" or using it for tasks that it's ill suited for.
Regardless of C falling in popularity (if legitimate) it's unlikely to be buried any time in the next 50 years given its use in the core of everything from OSs to 1K microcontroller firmware.
Re: (Score:2)
Regardless of C falling in popularity (if legitimate) it's unlikely to be buried any time in the next 50 years given its use in the core of everything from OSs to 1K microcontroller firmware.
Just like COBOL, although I still think that COBOL programs will decline in percentage of business computing as time passes. As a sidenote, I find it sad that C is used in 1K microcontroller firmware. Where would it payoff in either space efficiency or developer "friendliness"?
Re: (Score:3)
C for modern microcontrollers is a good mix. Easy to access bit-level operations (port control, bit bashing etc) but providing structured programming framework with easier debugging (libraries, function calls, interrupts, even portability to other architectures).
I code ASM for quite a few when needed (ie things like the Attiny5/10 due to stack limitations ) but realistically doing it in C makes the end-to-end development process a lot smoother.
The compiler will out optimise the human in almost all cases, a
Re: (Score:2)
I look at computer languages as a designed tool to best express what the programmer wants accomplished. If the programmer has to conform to the tool, or recreate the wheel every time they program something, or have to relearn how to do things in the language in order to do something useful, then its not a good tool/language. C has the ability to interface with assembly, and it has some higher level abstractions which makes programming easier than assembly. But for a 1K chip, you probably have to discard
Submitter is clueless - 99.9% of web sites run on (Score:5, Insightful)
Quoting TFS, "t is not a language that you think of while writing programs for popular fields such as mobile apps or websites". Submitter clearly doesn't have much idea how web sites work. For web sites, your browser (a C or C++ program) sends a request through routers running Cisco iOS (a C program) to a web server such as Apache (a C program), which may run a module such as mod_php (a C program) which in turn probably runs a library such as ImageMagick (a C program) which generates the content. The content is fed back through the web server (still C) to your browser. For larger sites, there is often a proxy in the middle, such as Squid (written in C) or mod_proxy (more C).
Re: (Score:2)
Languages that do come to mind in these fields are Objective-C, Swift, C# or Java for mobile apps, or Javascript, Java, PHP, Ruby or C# for w
Betteridge's law (Score:4, Insightful)
Betteridge's law of headlines. Answer is no. HELL no. Hell no, you royal asshole. Discussion terminated. OK?
Reasons: standards, size and man pages (Score:2)
C is a very small language with a modest standard library. The language itself has ANSI and ISO certifications. The standard C library is largely defined by POSIX. I con't have to hold much in my head by way of language constructs or reserved words, etc. and any other programming languages derived their syntax from C, so it will get reenforced often (except the weird ways to use pointers).
If I have a question about a standard libc function, the man pages will be there on my systems whether it is FreeBSD,
Re: (Score:2)
Indeed. And maybe the one most important thing about C plus Unix is that the number of special things you need to learn and understand is limited.
Sure, once you tackle, say, socket programming for the first time, it is tricky and obscure. But once you have it, it will stay the same forever, and you do not need to re-learn it all the time because every more abstract language hides features, translates behavior and adds its own things. So far I have not found any abstraction of such concepts that did not make
Re: (Score:2)
You're right, but given that I was typing with my thumbs first thing in the morning before coffee, you get the point I was making none the less.
Maybe. But what's the point of your question? (Score:2)
C is still basically the most widely used assembler 2.0 and just about everything we use is built with C.
Yes, there is C++ and entire stacks built on that, but I'm not talking about Windows. In the global context, Windows is somewhat of an exception.
The C familly of languages is alive and well and the C-fans building our systems we work on still seem to think it's the best tool for the job.
Until someone replaces the entire toolchain with a new language like Go or Rust and people from the format like Linus T
Re: (Score:2)
Rust and Go cannot cut it. When you really need full control, they are just as unsafe as C, but they are not as clean or clear.
Re: (Score:2)
Re: (Score:2)
It is the "Silver Bullet" mindset. Its proponents think that if they just had the right magic tool, all problems would go away. Well, Brooks published "No Silver Bullet" in 1986, and these people are not only clueless and incompetent, they are unaware of history. This is just as true today as it was back then. There is no silver bullet, no magic language or tool that will ever make a wannabe a competent engineer. On the other hand, competent engineers can be slowed down by sub-optimal tools, but that is abo
Not again (Score:2)
TIOBE index ist not significant for the popularity (what ever that may be) of programming languages.
Sure it is (Score:2)
Ehh... (Score:2)
Bah... C is still king baby (Score:3)
C is not dying. Most of the libraries that are used behind the scenes to support Swift, Objective-C, Java, Python, Perl, LINUX, C#, and New Embedded Platforms like PI, are all written in C/C++.
C scales as well as any other language as long as you use C++ and objectify everything so it can fire it up in containers. You can't use global variables anymore and everything needs to be encapsulated into an object. It pains me to do this, but with the shift to the cloud there is no choice (please prove me wrong).
C is the bed-rock of all that is digital. If anything needs to die it is Java. The new owner of Java doesn't seem to be taking care of it like Sun Microsystems used to. Yeah, I am looking at your Oracle.
Consider how many C libraries this Slashdot page passed through just to get to your eyeballs.
Re: (Score:2)
If anything needs to die it is Java.
If Java dies, it will be replaced by C#. So not much change.
Re: (Score:2)
Inevitable decline in popularity... (Score:3)
...since D was released.
Re: (Score:2)
There's F# if you want to take your mojo up to 11.
https://en.wikipedia.org/wiki/F_Sharp_(programming_language) [wikipedia.org]
C is only dying in the buzz department (Score:4, Insightful)
Re: (Score:2)
Unlike languages targeted at barely competent programmers (like Java), C demands insight and understanding or things break very fast. That will always limit its popularity. On the other hand, those few that have the skills will continue to use it, because nothing else gives you remotely the same power and simplicity. Sure, glue-code where performance does not matter is better written in a scripting language like Python, but for the actual work nothing beats C written by somebody that knows what they are doi
C is slowly being replaced by C++ (Score:5, Insightful)
Re: (Score:2)
C++ is actually a barely usable monster. It adds nothing real except complexity, also because its OO model is fundamentally broken and inefficient. Sure, C can benefit from some libraries like safe string handling, but that is it. So, no, C is not "morphing" into C++ at all.
Re:C is slowly being replaced by C++ (Score:4, Insightful)
The real problem with C++ is not slowness, but being too complex and unpredictable. I think that what will happen is that C will get the few good features from C++, and the rest will die.
You're correct that C++ is typically no slower than C, but it seems very unlikely to disappear anytime soon. There are probably billions of lines of C++ out in the real world. It will never be the most popular language, but it's a very significant one, and will be for quite some time. C++ is used when you need the performance of a to-the-metal compiled language like C, but need better abstraction models for large, complex systems. But unlike some other languages, you typically pay little to nothing extra for these abstractions, as the burden is shifted to the compiler. There are many times when performance really does matter, and you can't simply afford to throw more hardware at a problem, such as a very complex application on a single client PC, a videogame console, or at massive scales like in mega data centers.
If you think C++ is "unpredictable" then you just don't know the language all that well. I'm not trying to sound arrogant or condescending, as it's absolutely a difficult language to learn and especially difficult to master (hell, probably near impossible to master it *all*), but "unpredictable" is how you describe managed memory, not C++. Yes, C++ has a lot of sharp edges as a language. It's ugly, clunky, bloated (aka "feature-rich"), slow to compile, and difficult to master. But it also has a large, mature ecosystem (thanks to its C-based heritage), and damn near every significant CPU or platform has a C++ compiler that supports it, probably topped only by C.
So really, it's reasonably safe to say that neither C nor C++ are going anywhere anytime soon, thanks partially due to sheer inertia caused their pervasiveness through our critical infrastructure. This fact alone dictates that compiler support will remain a priority among major software companies (Microsoft, Intel, Apple) or projects (Clang, CGG). Add to that the enormous codebases that companies have invested in with both languages, and C/C++'s longevity is even more likely.
As with all headlines that pose a question... (Score:2)
No.
If the fuckwit who wrote this shitpost can't be bothered to do enough research into either the topic or have the journalistic integrity to posit a theory, and instead needs to shitpost a question...
Then as always, the answer to the headline is no.
Re: (Score:2)
Also, why does it matter? Tools are not a popularity contest. Pick the right tool for the job. Haskell has found a niche in MQ and async communication. Okay then. The only discussion on this topic that is relevant is about the applicability of a tool.
For example, NodeJS is crap. The crap though has nothing to do with the language "Javascript" but the server-side implementation of NodeJS.
Or PHP. PHP's security model has always been suspect more than that of other languages and yet is a one of the most widely
Jobs ads always seem to ask for C/C++ (Score:2)
That is what I seen. I can't remember the last time I saw a job ad for just C.
I'm calling Betteridge on this one (Score:2)
That's to say: no, it isn't.
More to the world than the Web (Score:2)
hardly suitable for the booming fields of web and mobile app development.
Perhaps this is so. But embedded apps are largely written in C.
Some years ago, I ran across a statistic. I'm not sure if its still accurate but: Take all the processors used in personal computing devices (PCs, tablets, phones) and web servers as a subset of all processors, micro-controllers, etc. and calculated that as a percentage. Rounded to the nearest whole percentage point, that number would be zero.
some stats (Score:2)
C: 1440
C++: 474
Python: 762
Ruby: 336
Java: 1113
I suspect the results for "C" are inflated due to the difficulty of isolating only positions looking for the "C" programming language. Same exercise at Stack Overflow jobs:
C: 2
C++: 2
Python: 10
Ruby: 7
Java: 14
"popularity" is irrelevant (Score:2)
There are quite a few things that cannot be reasonably done in any other language. Also, because it is closest to the machine without being assembler, any real IT expert will have C-skills. It makes a world of difference.
Certain languages attract assholes (Score:2)
Just to make C people feel a little better, they are saints compared to anyone who claims to be a CSS programmer (are they seriously claiming to be programmers) or the worst
Re:Fuck You New Slashdot Owners, Fuck You (Score:5, Insightful)
You're so busy fucking yourselves, maybe all you need is a good hearty fuck you to shut your stupid ass the fuck up.
Really contributes to the discussion, a fantastic way to convince someone you are a reasonable person with a well thought out position.
Why don't you go ask mother fucking ANSI what they think about C's popularity?
I'm not sure what ANSI is supposed to help us, all they do is set standards. May as well as IEEE what they think of TCP's popularity.
Why don't you go around and check to see what code is compiling and executing?
This is so vague as to being entirely meaningless, but alright. Javascript is considered the world's #1 compiled language. Java bytecode comes after. Maybe Shell scripting or Python after that. Aside from how asinine and useless those measures are, since they tell you nothing about its popularity with developers, it seems awfully strange to pick a fight with a language that is only ever compiled once and never formally executed in its original form.
Why don't you fucking just learn a tiny little bit about the history of programming languages and their derivatives
I'm not sure what the history of programming languages is supposed to do about what today's measures are, given that how it scored in the past has little bearing on how useful it is today. I'm completely confused as to what you even mean by that, or why you even put it in here. Perhaps, because like the rest of your post, it was entirely devoid of any rational point or argument?
your stupid caking piehole about shit that you shouldn't even be propagandizing about, stop dumbing people the fuck down, and just to reiterate, the the fucking holy hell up?
You state things much more bluntly then I would like, but at its core, perhaps yes. If you have nothing to contribute, take your meds, knock yourself out, and stop vomiting yourself all over this page.
Re: (Score:2)
If I had mod points, you would get them ALL! Yes, go learn Python or Ruby on Rails or Visual Studio or Swift.
Re: (Score:2)
Hahaha, joke is on you! I use Python with embedded C modules for most things I do these days. Yes, if you are really skillful, you can have the best of both worlds.
Re: (Score:2)
Well, the whole Internet of Shit depends on C programmed Linux enabled ARM processors, so one could wish for it to be dying, but it is very unlikely.
Are we sure that's true? These Linux-enabled ARM processors are more powerful than the PC I was programming in interpreted languages at the turn of the century, and most of them are doing very simple things like turning heaters or lights on and off, which isn't computationally expensive. Small indy "things" are often built around the Raspberry Pi, because that's what the prototype was built on... and probably in Python. If I was building a garage door opener out of a computer with enough grunt to run four s
Re: (Score:2)
C is responsible for the vast majority of stray pointer and buffer overrun vulnerabilities. Together with SQL injection and macros, it's making computing unsafe. C++ ameliorates the problem but does not eliminate it.
That is unmitigated bullshit. The language is not the reason for these problems, the coders are. Only a completely clueless person would blame a hammer for its ability to break things.
C/C++ are low-level languages used to implement everything else. There is no direct replacement. We desperately need one. What's the holdup, folks?
There is no "holdup". It cannot be done any other way. Either you have the power of C and then you also have the destructive power, or you don't, and then you cannot do the things C can do.
I had a look at Rust and could only ask: why isn't this twenty years further along by now? Oh, and... what's with that huge embedded runtime?
Simple: Rust is far less useful than its proponents claim. When you actually need its full power, you have to go to an "unsafe" model, and