February 23, 2017
On 22/02/17 13:26, Ola Fosheim Grøstad wrote:
> On Wednesday, 22 February 2017 at 09:09:45 UTC, Russel Winder wrote:
>> Learning C++, then D, then Rust for example will have benefit because
>> there are new things there even though the core computational model is
>> effectively the same – they have differences that matter.
>
> Maybe. I think "modern" C++ is a in class of it's own at this point. It
> is now quite detached from it's root: C with classes.

I feel slightly bad for sending you to read through the whole of http://lbrandy.com/blog/2010/03/never-trust-a-programmer-who-says-he-knows-c/ before getting to the punchline on the last sentence, but on the plus side, it is very short.

On a slightly different note, "C with classes" is the name of C++'s predecessor, which was a preprocessor. Strastrup draws a very distinct line between that and the first C++ compiler (cfront).

> the computational model as for all the patterns you ought to follow and
> not nearly enough constraints from the compiler on what you should not
> do.

That is a matter of perspective. I, for one, feel other languages put too much constraints on, making me work quite hard to get what I want expressed in the language, often blocking me from the most efficient implementation altogether.

D is better in that regard than many, but still weights on me on occasion.

> With modern C++ you either have to go for being proficient or end up
> feeling miserable. Which is quite different from most imperative
> languages I think.

Which is precisely why it is not a good language to start with unless you intend to stick with it. This is not a language mastered quickly, and superficial knowledge of it really is a dangerous thing. There is no point in aiming to learn it superficially.

Shachar
February 23, 2017
On Thursday, 23 February 2017 at 07:36:11 UTC, Shachar Shemesh wrote:
> That is a matter of perspective. I, for one, feel other languages put too much constraints on, making me work quite hard to get what I want expressed in the language, often blocking me from the most efficient implementation altogether.

What I meant was that what was things along the line of: best-practice in the past for meta-programming is no longer the best way to go about it today, yet C++ remains backwards compatible so... as a result you end up having N ways of expressing the same thing. Which makes C++ harder to read than it should be.

It is not so much about being able to express something as it is about having N different convoluted ways to express the same thing.

> Which is precisely why it is not a good language to start with unless you intend to stick with it.

At this point C++ is a very poor choice for education at any level.

Ola.
February 23, 2017
On 02/23/2017 09:24 AM, Ola Fosheim Grøstad wrote:
>
> It is not so much about being able to express something as it is about
> having N different convoluted ways to express the same thing.

And most of those ways being "wrong" or dangerous. And, as you mentioned, certain "right" ways becoming "wrong" seemingly every few years.

February 23, 2017
On Thursday, 23 February 2017 at 17:23:11 UTC, Nick Sabalausky (Abscissa) wrote:
> And most of those ways being "wrong" or dangerous. And, as you mentioned, certain "right" ways becoming "wrong" seemingly every few years.

Not necessarily wrong, but either limited to specific scenarios or unnecessarily verbose compared to what can be done in the latest version of the language.

When you have overlapping mechanisms it becomes more difficult to read the code as there are too many ways for people to express the same thing. For a wide spread and  continuously developing language like C++ it gets worse because developers keep using whatever was "right" when they learned about that feature.

1 2
Next ›   Last »