Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. are these developments making things easier for the developer?

are these developments making things easier for the developer?

Scheduled Pinned Locked Moved The Lounge
c++questioncsharpvisual-studiocom
24 Posts 20 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Lost User

    A question in the C++ forum today led me to C++ conformance improvements in Visual Studio 2019 | Microsoft Docs[^]. It seems to me that C++ is getting more and more complex and only a select few (some of whom are regulars here) will understand and be able to use these features. So I have to wonder who benefits from them, apart from the compiler writers who will definitely keep their jobs.

    P Offline
    P Offline
    PIEBALDconsult
    wrote on last edited by
    #5

    We need "the next big thing".

    W 1 Reply Last reply
    0
    • P PIEBALDconsult

      We need "the next big thing".

      W Offline
      W Offline
      W Balboos GHB
      wrote on last edited by
      #6

      "C" - oh, wait, the next BIG THING:

      C

      Ravings en masse^

      "The difference between genius and stupidity is that genius has its limits." - Albert Einstein

      "If you are searching for perfection in others, then you seek disappointment. If you seek perfection in yourself, then you will find failure." - Balboos HaGadol Mar 2010

      F 1 Reply Last reply
      0
      • L Lost User

        A question in the C++ forum today led me to C++ conformance improvements in Visual Studio 2019 | Microsoft Docs[^]. It seems to me that C++ is getting more and more complex and only a select few (some of whom are regulars here) will understand and be able to use these features. So I have to wonder who benefits from them, apart from the compiler writers who will definitely keep their jobs.

        D Offline
        D Offline
        David ONeil
        wrote on last edited by
        #7

        They are probably applicable to less than 5% of developers? But you still have to search for things like JPEG and PNG encoders and decoders, which will affect far more than that 5%. This perplexes me, even though I heard their reasons for it long ago... C# kicks its butt because of items like that. Fortunately, you don't have to use the new constructs.

        The Science of King David's Court | Object Oriented Programming with C++

        1 Reply Last reply
        0
        • C Chris Maunder

          Same thing is happening with C#. What was once the one of the cleanest languages is accruing debris.

          cheers Chris Maunder

          L Offline
          L Offline
          Lost User
          wrote on last edited by
          #8

          Yes ... I've stopped reading "What's New". The alternative is: "MS is killing C#!!"

          It was only in wine that he laid down no limit for himself, but he did not allow himself to be confused by it. ― Confucian Analects: Rules of Confucius about his food

          1 Reply Last reply
          0
          • W W Balboos GHB

            "C" - oh, wait, the next BIG THING:

            C

            Ravings en masse^

            "The difference between genius and stupidity is that genius has its limits." - Albert Einstein

            "If you are searching for perfection in others, then you seek disappointment. If you seek perfection in yourself, then you will find failure." - Balboos HaGadol Mar 2010

            F Offline
            F Offline
            fd9750
            wrote on last edited by
            #9

            Yes, it will keep on trucking for a long time. I have seen way too many attempts at using C++ for embedded applications that only use a subset of what C++ can do. And when you objectively ( pun indented ) it just makes you wonder what the point was of using C++ instead of C. Managers of any kind are a very bad idea to begin with.

            S 1 Reply Last reply
            0
            • C Chris Maunder

              Same thing is happening with C#. What was once the one of the cleanest languages is accruing debris.

              cheers Chris Maunder

              M Offline
              M Offline
              Maximilien
              wrote on last edited by
              #10

              this. I don't know much C# and getting into an existing C# project is hell difficult to understand.

              I'd rather be phishing!

              1 Reply Last reply
              0
              • L Lost User

                A question in the C++ forum today led me to C++ conformance improvements in Visual Studio 2019 | Microsoft Docs[^]. It seems to me that C++ is getting more and more complex and only a select few (some of whom are regulars here) will understand and be able to use these features. So I have to wonder who benefits from them, apart from the compiler writers who will definitely keep their jobs.

                R Offline
                R Offline
                Rick York
                wrote on last edited by
                #11

                Personally, I find a lot of new things being introduced to be counter-productive so I don't bother using them and I generally avoid code that does. That's because it defeats the purpose as far as I'm concerned. Herb keeps saying they are making the language more concise but I really couldn't care less about that because I see no advantages to that. If I have to stop and think about what some new construct does that is not helpful. I'll take the old, verbose ways that are simple and easy to understand. Of newer things, I have found only one from C++17 that I use frequently: inline static initializers. That's one of the most useful things I have found in quite a while. This may be an "old dog-new tricks" thing with me but I am not asking for any new tricks because the old ones are working pretty well as far as I'm concerned.

                "They have a consciousness, they have a life, they have a soul! Damn you! Let the rabbits wear glasses! Save our brothers! Can I get an amen?"

                N 1 Reply Last reply
                0
                • R Rick York

                  Personally, I find a lot of new things being introduced to be counter-productive so I don't bother using them and I generally avoid code that does. That's because it defeats the purpose as far as I'm concerned. Herb keeps saying they are making the language more concise but I really couldn't care less about that because I see no advantages to that. If I have to stop and think about what some new construct does that is not helpful. I'll take the old, verbose ways that are simple and easy to understand. Of newer things, I have found only one from C++17 that I use frequently: inline static initializers. That's one of the most useful things I have found in quite a while. This may be an "old dog-new tricks" thing with me but I am not asking for any new tricks because the old ones are working pretty well as far as I'm concerned.

                  "They have a consciousness, they have a life, they have a soul! Damn you! Let the rabbits wear glasses! Save our brothers! Can I get an amen?"

                  N Offline
                  N Offline
                  Nelek
                  wrote on last edited by
                  #12

                  Rick York wrote:

                  If I have to stop and think about what some new construct does that is not helpful. I'll take the old, verbose ways that are simple and easy to understand.

                  Thank god that you and @GregUtas are saying that... I now feel less dumb :-D :-D :rolleyes:

                  M.D.V. ;) If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about? Help me to understand what I'm saying, and I'll explain it better to you Rating helpful answers is nice, but saying thanks can be even nicer.

                  1 Reply Last reply
                  0
                  • C Chris Maunder

                    Same thing is happening with C#. What was once the one of the cleanest languages is accruing debris.

                    cheers Chris Maunder

                    Sander RosselS Offline
                    Sander RosselS Offline
                    Sander Rossel
                    wrote on last edited by
                    #13

                    One of the "improvements" I find really complicated is the range operator.

                    string name;
                    name = "My name is Sander Rossel".Substring(11);
                    name = "My name is Sander Rossel"[11..];

                    Now tell me, which line of code better conveys my purpose? :~ Pattern matching is nice, but should be rarely needed in proper OOP.

                    Exception ex = new Exception();
                    switch (ex)
                    {
                    case InvalidCastException:
                    break;
                    case InvalidOperationException:
                    break;
                    case NullReferenceException:
                    break;
                    default:
                    break;
                    }

                    // The alternative is, of course, an if-else statement.
                    var exType = ex.GetType();
                    if (exType == typeof(InvalidCastException))
                    { }
                    else if (exType == typeof(InvalidOperationException))
                    { }
                    else
                    { }

                    There's probably an advantage to the pattern matching, but it doesn't do much for readability. I love named tuples though.

                    public (string firstName, string lastName) GetNameParts(string name) { }
                    // Usage...
                    (var firstName, var lastName) = GetNameParts("Sander Rossel");
                    // Or...
                    var tuple = GetNameParts("Sander Rossel");
                    Console.WriteLine(tuple.firstName);

                    And of course string interpolation, which greatly improves readability and decreases change of bugs.

                    Console.WriteLine($"Hi {firstName} {lastName}, welcome to {appName}!");
                    // vs.
                    Console.WriteLine(string.Format("Hi {0} {1}, welcome to {2}!", firstName, lastName, appName);

                    If I could keep only one language improvement from about the last ten years it would be string interpolation!

                    Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                    B C 2 Replies Last reply
                    0
                    • Sander RosselS Sander Rossel

                      One of the "improvements" I find really complicated is the range operator.

                      string name;
                      name = "My name is Sander Rossel".Substring(11);
                      name = "My name is Sander Rossel"[11..];

                      Now tell me, which line of code better conveys my purpose? :~ Pattern matching is nice, but should be rarely needed in proper OOP.

                      Exception ex = new Exception();
                      switch (ex)
                      {
                      case InvalidCastException:
                      break;
                      case InvalidOperationException:
                      break;
                      case NullReferenceException:
                      break;
                      default:
                      break;
                      }

                      // The alternative is, of course, an if-else statement.
                      var exType = ex.GetType();
                      if (exType == typeof(InvalidCastException))
                      { }
                      else if (exType == typeof(InvalidOperationException))
                      { }
                      else
                      { }

                      There's probably an advantage to the pattern matching, but it doesn't do much for readability. I love named tuples though.

                      public (string firstName, string lastName) GetNameParts(string name) { }
                      // Usage...
                      (var firstName, var lastName) = GetNameParts("Sander Rossel");
                      // Or...
                      var tuple = GetNameParts("Sander Rossel");
                      Console.WriteLine(tuple.firstName);

                      And of course string interpolation, which greatly improves readability and decreases change of bugs.

                      Console.WriteLine($"Hi {firstName} {lastName}, welcome to {appName}!");
                      // vs.
                      Console.WriteLine(string.Format("Hi {0} {1}, welcome to {2}!", firstName, lastName, appName);

                      If I could keep only one language improvement from about the last ten years it would be string interpolation!

                      Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                      B Offline
                      B Offline
                      Bob Beechey
                      wrote on last edited by
                      #14

                      Which code better conveys your purpose? The second. Using ranges in Python for the last five million yeasrs, it is a joy to see them in C#. The only thing to remember, as in most languages that use slices and ranges, in [start..end] is that "end" is a stop and is not included in the range.

                      Console.WriteLine("Hello World!"[1..5]);

                      Console.WriteLine("Hello World!"[..5]);

                      Both give us "Hello" rom [0] to [4] stopping at [5].

                      K 1 Reply Last reply
                      0
                      • L Lost User

                        A question in the C++ forum today led me to C++ conformance improvements in Visual Studio 2019 | Microsoft Docs[^]. It seems to me that C++ is getting more and more complex and only a select few (some of whom are regulars here) will understand and be able to use these features. So I have to wonder who benefits from them, apart from the compiler writers who will definitely keep their jobs.

                        M Offline
                        M Offline
                        Michael Breeden
                        wrote on last edited by
                        #15

                        I believe code should read like a story. It makes for maintainability which is my primary concern. Very often the C# developers seem to believe that minimum typing is the objective of the language and add things that remove from the story. Choose what your priority is. I hate these stupid new features that hide what the story is saying. It's like a conversation with an idiot. You have no idea what they are saying.

                        1 Reply Last reply
                        0
                        • L Lost User

                          A question in the C++ forum today led me to C++ conformance improvements in Visual Studio 2019 | Microsoft Docs[^]. It seems to me that C++ is getting more and more complex and only a select few (some of whom are regulars here) will understand and be able to use these features. So I have to wonder who benefits from them, apart from the compiler writers who will definitely keep their jobs.

                          S Offline
                          S Offline
                          SeattleC
                          wrote on last edited by
                          #16

                          When you look at a list of C++ changes in isolation, and without any motivating commentary they look hopelessly esoteric and unimportant. My experience with modern C++ features is that one day you will be looking for a way to solve a problem, and suddenly it will hit you, "Ah ha! That's what < feature X> is for." C++ is becoming a very complex language. But the things added to C++ are put there by a bunch of really smart people who are experienced developers. It all has a purpose.

                          L 1 Reply Last reply
                          0
                          • S SeattleC

                            When you look at a list of C++ changes in isolation, and without any motivating commentary they look hopelessly esoteric and unimportant. My experience with modern C++ features is that one day you will be looking for a way to solve a problem, and suddenly it will hit you, "Ah ha! That's what < feature X> is for." C++ is becoming a very complex language. But the things added to C++ are put there by a bunch of really smart people who are experienced developers. It all has a purpose.

                            L Offline
                            L Offline
                            Lost User
                            wrote on last edited by
                            #17

                            SeattleC++ wrote:

                            It all has a purpose.

                            Yes, to confuse poor old sods like me. :((

                            1 Reply Last reply
                            0
                            • L Lost User

                              A question in the C++ forum today led me to C++ conformance improvements in Visual Studio 2019 | Microsoft Docs[^]. It seems to me that C++ is getting more and more complex and only a select few (some of whom are regulars here) will understand and be able to use these features. So I have to wonder who benefits from them, apart from the compiler writers who will definitely keep their jobs.

                              J Offline
                              J Offline
                              JP Reyes
                              wrote on last edited by
                              #18

                              I actually haven't learned anything new since C++ 2003 I still look at C++ as C with objects, so for me it hasn't needed updating since it's standardization in the 90's. I never used the dreaded Templates (memory hoggers) but I've heard that they have improved since 2003. So if you're like me that still codes in C++ as if it were C, then it's like "Why fix what ain't broken? There's always assembler"

                              1 Reply Last reply
                              0
                              • B Bob Beechey

                                Which code better conveys your purpose? The second. Using ranges in Python for the last five million yeasrs, it is a joy to see them in C#. The only thing to remember, as in most languages that use slices and ranges, in [start..end] is that "end" is a stop and is not included in the range.

                                Console.WriteLine("Hello World!"[1..5]);

                                Console.WriteLine("Hello World!"[..5]);

                                Both give us "Hello" rom [0] to [4] stopping at [5].

                                K Offline
                                K Offline
                                kholsinger
                                wrote on last edited by
                                #19

                                I think your opinion comes from the "....Using ranges in Python for the last five million years..." If you're used to ranges, then the second version is more obvious. If you're not, it's pretty mysterious.

                                1 Reply Last reply
                                0
                                • C Chris Maunder

                                  Same thing is happening with C#. What was once the one of the cleanest languages is accruing debris.

                                  cheers Chris Maunder

                                  P Offline
                                  P Offline
                                  Peter Shaw
                                  wrote on last edited by
                                  #20

                                  You beat me to it chris, I was just about to say exactly the same thing. Myself and a colleague, where talking about this the other day, and basically came to the conclusion that all languages now have to take this approach, simply to appease the 15 minute attention span of the instant feedback generation.

                                  1 Reply Last reply
                                  0
                                  • Sander RosselS Sander Rossel

                                    One of the "improvements" I find really complicated is the range operator.

                                    string name;
                                    name = "My name is Sander Rossel".Substring(11);
                                    name = "My name is Sander Rossel"[11..];

                                    Now tell me, which line of code better conveys my purpose? :~ Pattern matching is nice, but should be rarely needed in proper OOP.

                                    Exception ex = new Exception();
                                    switch (ex)
                                    {
                                    case InvalidCastException:
                                    break;
                                    case InvalidOperationException:
                                    break;
                                    case NullReferenceException:
                                    break;
                                    default:
                                    break;
                                    }

                                    // The alternative is, of course, an if-else statement.
                                    var exType = ex.GetType();
                                    if (exType == typeof(InvalidCastException))
                                    { }
                                    else if (exType == typeof(InvalidOperationException))
                                    { }
                                    else
                                    { }

                                    There's probably an advantage to the pattern matching, but it doesn't do much for readability. I love named tuples though.

                                    public (string firstName, string lastName) GetNameParts(string name) { }
                                    // Usage...
                                    (var firstName, var lastName) = GetNameParts("Sander Rossel");
                                    // Or...
                                    var tuple = GetNameParts("Sander Rossel");
                                    Console.WriteLine(tuple.firstName);

                                    And of course string interpolation, which greatly improves readability and decreases change of bugs.

                                    Console.WriteLine($"Hi {firstName} {lastName}, welcome to {appName}!");
                                    // vs.
                                    Console.WriteLine(string.Format("Hi {0} {1}, welcome to {2}!", firstName, lastName, appName);

                                    If I could keep only one language improvement from about the last ten years it would be string interpolation!

                                    Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                    C Offline
                                    C Offline
                                    Chris Maunder
                                    wrote on last edited by
                                    #21

                                    Named tuples and interpolated strings are awesome, as is the ?? operator and the ?. operator. Those stay.

                                    cheers Chris Maunder

                                    Sander RosselS 1 Reply Last reply
                                    0
                                    • F fd9750

                                      Yes, it will keep on trucking for a long time. I have seen way too many attempts at using C++ for embedded applications that only use a subset of what C++ can do. And when you objectively ( pun indented ) it just makes you wonder what the point was of using C++ instead of C. Managers of any kind are a very bad idea to begin with.

                                      S Offline
                                      S Offline
                                      sasadler
                                      wrote on last edited by
                                      #22

                                      Hm, as an embedded system designer/programmer (now retired), I used C++ for most of my programing in the last 15 years of my career. Using templates for things like FIFOs, queues, digital oscillators, filter parts, etc made my code cleaner and easier to write. I did stay away from dynamic object creation/destruction and I didn't use C++ exceptions.

                                      1 Reply Last reply
                                      0
                                      • C Chris Maunder

                                        Named tuples and interpolated strings are awesome, as is the ?? operator and the ?. operator. Those stay.

                                        cheers Chris Maunder

                                        Sander RosselS Offline
                                        Sander RosselS Offline
                                        Sander Rossel
                                        wrote on last edited by
                                        #23

                                        I've been using ? and ?? so much I don't even consider them new anymore! So completely agreed :laugh:

                                        Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                        1 Reply Last reply
                                        0
                                        • L Lost User

                                          A question in the C++ forum today led me to C++ conformance improvements in Visual Studio 2019 | Microsoft Docs[^]. It seems to me that C++ is getting more and more complex and only a select few (some of whom are regulars here) will understand and be able to use these features. So I have to wonder who benefits from them, apart from the compiler writers who will definitely keep their jobs.

                                          M Offline
                                          M Offline
                                          Martin ISDN
                                          wrote on last edited by
                                          #24

                                          i always believed that a large part of it was about "keeping their jobs". i'm not talking only about VS2019 or C++. Windows grows because of it and you see the same buttons with the same functionality changing places in the same Form of say, System Properties. then the UP one directory button disappears in Vista and 7, but then it's coming back in 8. they move the GUI to a heavily 3D multicolored look and then back to 8 colors and win3.11 looks. it's progress alright, but i don't know if it's in the right direction. the chances to start a C++ project that lasts for 5 years and at the end of the project to claim you know modern C++ are getting close to zero, much less to claim you know some other rapidly evolving language. "if this frameworks are so great and helpful why do we need another one? why didn't the last 27 frameworks solve the problem? they didn't so you need the 28th framework, right?" - Jonathan Blow

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups