[HN Gopher] C++ Dev Ecosystem 2021
       ___________________________________________________________________
        
       C++ Dev Ecosystem 2021
        
       Author : luu
       Score  : 79 points
       Date   : 2021-07-19 19:47 UTC (3 hours ago)
        
 (HTM) web link (www.jetbrains.com)
 (TXT) w3m dump (www.jetbrains.com)
        
       | Shadonototro wrote:
       | and yet they don't even support C++20.. not even modules
       | 
       | jetbrains used to be ahead of the competition, they are now
       | lagging behind
       | 
       | > Is your current project planning to use any of these C++20
       | features in the next 12 months?
       | 
       | modules with 48%
       | 
       | jetbrains you better hurry up
        
         | infamouscow wrote:
         | Only MSVC has complete C++20 support. GCC and Clang are not all
         | the way there yet.
        
           | scatters wrote:
           | MSVC _claims_ complete C++20 support, but their concepts
           | implementation is lacking support for requires-expressions.
           | This is a pretty huge oversight, imo.
        
           | aninteger wrote:
           | Depends on the definition of complete: https://old.reddit.com
           | /r/cpp/comments/old0t6/why_does_msvc_b...
        
         | slezyr wrote:
         | > and yet they don't even support C++20.. not EVEN MODULES
         | 
         | Can you name a build system that supports them?
        
           | pjmlp wrote:
           | MSBuild.
        
           | gravypod wrote:
           | Someone made a rule set for bazel: https://github.com/rnburn/
           | rules_cc_module/tree/main/example/...
        
         | rightbyte wrote:
         | And 46% said they will use concepts. I guess people are
         | overestimating a lot or the panel was C++ aficionados.
        
           | bluGill wrote:
           | 46% seems way too high. Most C++ programmers just use
           | templates without writing them, so concepts are of no use as
           | the compiler can figure out from the simple types what is
           | wrong with the code and give a good error message. Until you
           | have to write generic code concepts don't have much use, and
           | that seems to be around 10% of C++ programmers.
           | 
           | Unless you mean as in use them to diagnose an error in your
           | use of generic code that you use. Then if you are using a
           | high enough C++ you will use them - though probably without
           | even knowing it.
        
         | nemetroid wrote:
         | Does CMake meaningfully support modules yet? From what I can
         | tell, the latest activity on this topic[1] is that it's in an
         | experimental state, and requires that you use a bundled version
         | of ninja[2]. I wouldn't expect CLion to support modules before
         | CMake does.
         | 
         | 1: https://gitlab.kitware.com/cmake/cmake/-/issues/18355
         | 
         | 2: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/5562
        
           | Shadonototro wrote:
           | It doesn't matter, they could provide a cmake fork that
           | supports modules
           | 
           | I am a customer, i need module support because we want to
           | embrace C++20 early, i look at what's available and i see
           | Visual Studio supporting modules, the choice is easy to make
           | 
           | Visual Studio has module support since few months already
        
         | jbluepolarbear wrote:
         | I don't use raw C++ anymore, but Rider with Unreal is next
         | level. I primarily use Rider with C# and it's always up to date
         | with the newest features.
        
       | ok2938 wrote:
       | Surprised that vim clocks in at only 6%.
        
         | uncomputation wrote:
         | I'm wondering the percentage for C developers.
        
           | tored wrote:
           | Vi/Vim 9%
           | 
           | https://www.jetbrains.com/lp/devecosystem-2021/c/
        
             | tored wrote:
             | _To invite potential respondents to complete the survey, we
             | used Twitter ads, Facebook ads, Instagram, Quora, VK, and
             | JetBrains' own communication channels. We also posted links
             | to some user groups and tech community channels, and we
             | asked our respondents to share the link to the survey with
             | their peers._
             | 
             | Probably not where you would look for vim & emacs users.
             | 
             | https://www.jetbrains.com/lp/devecosystem-2021/methodology/
        
       | stanislavb wrote:
       | The C++ trending projects on LibHunt also give a nice overview of
       | the current open-source dev ecosystem
       | https://www.libhunt.com/l/cpp/trending (disclosure: I've built
       | LibHunt)
        
       | ternaryoperator wrote:
       | _One third_ of C++ devs in this survey don 't write unit tests at
       | all? That's insane in this day and age.
        
         | p0nce wrote:
         | Also half of Javascript and C developers, from the same set of
         | Jetbrains studies.
        
         | NavinF wrote:
         | Is it really? Most unit tests I've encountered are garbage.
         | They only test for bugs that are incredibly unlikely to happen.
         | 
         | Integration tests and fuzz testing is where it's at. Anyone can
         | add or improve an integration test within an hour and find
         | several bugs that real users would encounter.
        
           | Jtsummers wrote:
           | > They only test for bugs that are incredibly unlikely to
           | happen.
           | 
           | Well, that might be the problem. Testing "for bugs" isn't a
           | terribly helpful activity. Testing for behavior is much more
           | helpful, and unit tests can definitely be applied to that
           | aspect of the system. Of course, it requires you to properly
           | decompose the system into subsystems (modules) with loose
           | coupling that can be individually (or in small sets) loaded
           | into test harnesses for testing.
        
           | ddlutz wrote:
           | Maybe you are not working on the right projects or with the
           | right people, because good unit tests are extremely valuable.
           | At a minimum, ensuring that making a change to some existing
           | code doesn't break existing behavior is valuable.
        
           | ternaryoperator wrote:
           | All that could be true and it still would not suggest that no
           | unit tests _at all_ is a valid choice.
        
         | iainctduncan wrote:
         | These kind of survey's have terrible sampling biases. One of
         | those is always going to be ability level, with more beginner,
         | early career, or hobbyist folks interested in doing it.
         | 
         | Case in point: I'm a hobby C++ hacker, and I read this. I'm a
         | long time pro Python hacker and would not have opened something
         | similar for Python! I'm like "the last thing I need to read
         | about in my leisure time is what other people are doing with
         | Python, that's WORK." haha.
        
         | munk-a wrote:
         | C++ not having a "default" unit testing framework that pretty
         | much ships with all the IDEs hurts it a lot - the other factor
         | is changing culture, I think. Even fifteen years ago unit tests
         | were a pretty alien thing to most folks and a lot of software
         | in C++ has a _very_ long lifespan. It 's really hard to build
         | momentum in an organization to actually set aside the time to
         | write unit test coverage over existing code.
        
       | sharikous wrote:
       | What surprises me is that VSCode is used more than VS for C++. I
       | would have guessed people would go for the "full fledged IDE" for
       | the kind of projects that require C++.
       | 
       | Overnight VSCode has become the one size fit all for everything.
        
         | exdsq wrote:
         | I would use VS if I was on Windows, but I'm on Linux
         | (specifically a Ubuntu distro on a chromebook) where I need
         | something lightweight (and cross-platform).
        
         | frabert wrote:
         | In my experience, VSCode + clangd works better than full VS for
         | most projects
        
         | ant6n wrote:
         | VSCode is kind of nice, but those keybindings are very
         | confusing and opiniated. And if you install an extension to get
         | the bindings you're used to (vim/emacs), it gets even more
         | confusing as the extension and VSCode start digging each other.
        
         | Jtsummers wrote:
         | VSCode is multiplatform. It runs on Linux and macOS as well as
         | Windows which expands its applicability and availability
         | greatly compared to Visual Studio proper.
        
       | daenz wrote:
       | Which c++ standards do you regularly use? 11% - I'm not sure.
       | 
       | That is extremely amusing and also extremely understandable.
        
       | ape4 wrote:
       | What about the dev's (like me) who never heard about the survey.
        
         | [deleted]
        
       | zabzonk wrote:
       | I would observe that anyone using C++11 in their code is also
       | being compatible with C++17.
       | 
       | And all this idea that modules will solve all compilation
       | problems (such as they are)? No, I don't think so.
        
         | jbluepolarbear wrote:
         | I haven't done an upgrade from 11 to 17, but I did do a few 11
         | to 14 and there were a lot of issues with the boost versions we
         | used. Those upgrades killed any interest I had in ever using
         | C++ again.
        
         | bluGill wrote:
         | Sure and odds are C++98 is compatible with C++17. The problem
         | is the reverse, I try to write the most modern C++ I can, but
         | I'm limited to my compiler (in embedded systems we rarely get
         | updated compilers) which sometimes means I have to write the
         | c++17 library things I need in older styles, and of course I
         | can't touch anything that needs a non-library update.
        
       ___________________________________________________________________
       (page generated 2021-07-19 23:00 UTC)