
C++ Status at the end of 2015 - ingve
http://www.bfilipek.com/2015/12/c-status-at-end-of-2015.html
======
StephanTLavavej
> Atomics in signal handlers - N2547 - its listed as missing here (at msdn),
> but listed as done here at vc blog

That was me being cautious, see
[http://blogs.msdn.com/b/vcblog/archive/2015/04/29/c-11-14-17...](http://blogs.msdn.com/b/vcblog/archive/2015/04/29/c-11-14-17-features-
in-vs-2015-rc.aspx) \- "I previously listed "Atomics in signal handlers" as
No, because despite maintaining <atomic>'s implementation, I didn't know
anything about signal handlers. James McNellis, our CRT maintainer, looked
into this and determined that it has always worked, going back to our original
implementation of <atomic> in 2012."

~~~
joebaf
Good catch, thanks!

------
Aleman360
Can't wait for modules. Header files are the worst.

Also really excited for co-routines. I never liked using promises.

Wow, had no idea ranges and contracts are on the table too. With all this
stuff, C# is really losing its appeal.

~~~
_yosefk
C# is memory-safe by default. C++ will forever let you (and your coworkers,
and library code you use/misuse) access memory outside array bounds and
dereference pointers to already-freed objects. This extends to C++'s advanced
features (such as objects captured by reference in anonymous functions.)

This is a big benefit of C# (and every other remotely popular language except
C and C++; how C compares to C++ is a separate question.) Arguably, some
systems cannot afford a garbage-collected language, but your comment kinda
assumes you can choose between C# and C++.

~~~
rhodysurf
Some people (like myself) just prefer C++ to C#.

~~~
paulddraper
That's fine.

And surely you'll agree with the GP that they're not really comparable.

~~~
blub
They are both used for building UI applications on Windows, because there's a
lot of existing C++ code, .NET used to be (not sure now) a major PITA to
deploy and was slower to boot. It also allows one to expand to other platforms
and operating system in a way that C# never could, in spite of toolchains like
Mono, and the recent open sourcing of .NET.

I would absolutely not choose C# for building a UI app even today.

~~~
pcwalton
> I would absolutely not choose C# for building a UI app even today.

Even if memory safety is important to you (the point of this subthread)?

~~~
blub
I don't really think about "X safety", but rather about various quality
attributes such as availability and resilience, perhaps also security in this
case. These have to be evaluated and kept in balance with other attributes
such as performance, portability, dev resources etc.

I would personally prefer to use various engineering practices such as static
and dynamic analysis, unit tests, etc rather than change programming
languages.

There's also the other side of this argument: my last project was Java. C++
would have allowed us to port more easily to other platforms (a current pain
point) and get better performance in combination with OpenGL (another major
pain point), however, the project constraints would have made it extremely
difficult to bring a C++ project to market with the resources we had.

~~~
paulddraper
There are good reasons to choose an unamanged language, but this part strikes
me as odd.

"my last project was Java. C++ would have allowed us to port more easily to
other platforms"

I'm not saying that you must wrong for your _particular_ situation, but as
soon as you've compile Java, you've essentially ported it to a massive number
of platforms.
[https://en.wikipedia.org/wiki/List_of_Java_virtual_machines](https://en.wikipedia.org/wiki/List_of_Java_virtual_machines)

If anything a dependency on OpenGL would limit your choices.

~~~
blub
Unfortunately, in our case the platforms were Android and iOS :) Likewise,
OpenGL is a pretty standard tool for mobile.

~~~
Sindisil
RoboVM might have been an option, in that case.

Not ideal, but perhaps workable.

------
kabdib
C++17:

> Single-quotation-mark as a digit separator

I have to admit to utter befuddlement about why you would ever want that.
(Presumably they will also require scanf to honor this as well . . . that'll
be fun).

Just when I thought the C++ committees were getting their heads screwed on
straight. Am I missing something, or is this another trigraph disaster?

~~~
theseoafs
What number is this?

100000000000000

~~~
gamegoblin
I actually really like the Java way of doing this:

    
    
        100_000_000_000_000

~~~
tzs
That also works in Perl, Ruby, C#, ADA, D, and Julia.

According to Wikipedia [1] underscore was proposed for C++ but rejected
because it conflicts with user-defined literals.

Is there any reason they could not have used space? Offhand, I can't think of
anyplace where a space in a literal number would not currently be illegal, so
adding that as a separator should not introduce any problems, but C++ has
grown massively in complexity since I last seriously used it so I could easily
have overlooked something.

[1]
[https://en.m.wikipedia.org/wiki/Integer_literal#Digit_separa...](https://en.m.wikipedia.org/wiki/Integer_literal#Digit_separators)

~~~
pklausler
A space could not be allowed in numeric values in runtime input (fscanf, <<).

------
santaclaus
It's not a language feature, but a defacto standard package manager would be a
huge boon for C++ development.

~~~
McP
Agreed. biicode ([https://www.biicode.com/](https://www.biicode.com/)) might
have potential.

------
bsaul
C++ has changed so much i barely recognize anything ( i used to code in c++ a
bit like c with classes). Which makes me wonder : do we have any idea on the
market share 20xx c++ versions represent ? I mean, how much c++ code produced
today is "modern c++" ?

------
BudVVeezer
The author may be a bit confused as to what C++17 will be. Modules will be in
a TS, most likely. Transactional memory, concepts, ranges, and filesystem are
already in published TSes (not planned for the IS in this round). Out of the
list presented, only fold expressions and __has_include are actually already
voted in for C++17 itself. The rest are in various stages of standardization
(mostly TSes) and are not guaranteed to ever become part of the IS (though
hopefully many will).

~~~
StephanTLavavej
That's incorrect - the Ranges TS was just started, and certainly hasn't been
published yet (not even as a PDTS). Filesystem was the first published TS.

~~~
BudVVeezer
Ah, that's right, ranges was a new work item planned for TS (but still not
planned for IS in C++17).

------
nulltype
My favorite quote from the C++17 specs
([https://isocpp.org/files/papers/D4492.pdf](https://isocpp.org/files/papers/D4492.pdf)):

"""

The note was written for committee members, but “escaped into the wild.” Here
are a few comments from the web:

•
[http://www.reddit.com/r/programming/comments/33us7z/what_wil...](http://www.reddit.com/r/programming/comments/33us7z/what_will_c17_be_bjarne_stroustr)
up_on_c17_goals/

•
[http://forums.theregister.co.uk/forum/1/2015/04/27/c_daddy_b...](http://forums.theregister.co.uk/forum/1/2015/04/27/c_daddy_bjarne_stroustrup_outlines_dir)
ections_for_v17/#c_2500733

•
[https://news.ycombinator.com/item?id=9441245](https://news.ycombinator.com/item?id=9441245)

As you see, people outside the committee also have strong opinions. Those
opinions can depart radically from the ones I hear in the committee and from
reality.

"""

------
biaxident
What's the best way to learn C++ nowadays?

~~~
svaha1728
That's a difficult question to answer without knowing your current skillset.

I'd definitely recommend CPPCast ([http://cppcast.com/](http://cppcast.com/))
for learning about the C++ community.

Pluralsight has some decent videos as well.

~~~
jgh
Clicked the link going "Please don't be a website that looks like a C++ dev
made it".

It's a website that looks like a C++ dev made it.

------
pkd
This is an honest question. In what areas of the industry does C++ dominate
the language landscape except hardware drives? I used to think this was true
for games but I've seen most studios move to C# as the community has matured
around it. All other major spaces seem like they've moved on to more managed
languages.

~~~
Aleman360
AAA games, embedded, operating systems (err, Windows shell at least), web
servers, core libraries, etc.

Still big in medical devices too, embedded or not.

