laitimes

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

author:Not bald programmer
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

Earlier this month, C++ officially announced the launch of its annual global survey of C++ developers. Over the course of a week, 1,200+ developers from around the world participated in the survey. After statistical analysis of the survey data, C++ has officially released the results of the survey, the 2024 C++ Developer Annual Survey "Lite", and has submitted the results to the C++ Standards Committee to help guide the development of C++.

At the time of the report, C++ officials added that "after the survey went live, we found that SurveyMonkey, an online survey tool, rejected feedback from certain countries. They didn't inform us that this was happening, so we didn't receive a survey this year from some of the countries that were included in previous years. We're committed to fixing this over the next year, because we really want to hear from all C++ programmers around the globe. ”

1. Where do you use C++? (please select all that apply)

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

In this question, the majority of developers (91.05%) said that they would use C++ at work, reflecting the widespread use of C++ in business and professional environments. In addition, the flexibility and performance of C++ can be used in a variety of fields, including game development, robotics, algorithm implementation, etc., so a significant number of developers (67.59%) use C++ in their personal time for hobby projects or to try new things.

2. How many years of C++ programming experience do you have?

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

According to the survey results, 33.68% of respondents have 10-20 years of C++ programming experience, followed by developers with more than 20 years of experience (26.55%). This shows that more than six out of ten developers in the survey have more than 10 years of C++ programming experience, and they may have been working on C++-related work or projects for a long time, and have a lot of experience and skills.

In comparison, only 5.15% have 1-2 years of C++ programming experience, which may be novice programmers or people who are relatively new to C++ and have only recently started learning and using the language.

3. How many years of programming experience do you have in total (all languages)?

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

If not limited to C++, nearly four out of ten developers (39.04%) have more than 20 years of programming experience. These developers may have been involved in programming early and have continued to gain experience, which may also include long-term C++ programming.

4. What types of projects do you work on?(Please select all that apply)

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

As a powerful programming language, C++ is widely used in a variety of fields, including but not limited to system software development, embedded systems, game development, and more.

According to the data, 31.51% of the respondents work in the engineering field, covering such as avionics, power management, etc., which often requires high performance and reliability. This is followed by hardware/IoT projects with 29.92%. This may involve the development of embedded systems, sensor technology, IoT devices, etc., and the superior performance and underlying control capabilities of C++ are very suitable for such scenarios that require efficient handling of hardware interactions. In addition, development tools and game development also accounted for a large proportion, with 27.38% and 20.87%, respectively. In these projects, C++ is the language of choice for some developers.

5. What platforms are you developing for?(Please select all that apply)

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

The highest percentage of respondents (60.56%) develop for the Windows desktop platform, indicating that C++ dominates Windows desktop development. This is followed by Linux desktop platform and Linux server platform, which are 56.75% and 57.30% respectively, that is, the wide application of C++ on Linux systems, covering not only desktop applications, but also server-side development, such as system software, network services, etc. In addition, embedded systems are also a major development area for C++, accounting for 32.22%.

6. What are some of the biggest problems in C++ development?

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

For 45.43% of respondents, managing the libraries that applications depend on is their main headache in C++ development, followed by build time (42.86%), and 30% of developers believe that building a continuous integration pipeline (automated builds, tests) from scratch is the main headache for them in C++ development...... and managing the CMake project is also an issue that cannot be overlooked.

Compared to the above problems, nearly half of developers (49.24%) pointed out that debugging bugs in the code, although also difficult, is not a major pain point.

7. How do you manage your C++ first and third-party libraries? (please select all that apply)

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

Developers take a variety of approaches when managing C++ first and third-party libraries, with the most common approach being to include the library source code in their projects and compile them with the project (68.54%). The advantages of this approach are clear: it ensures project portability and stability, while also allowing the library to be customized and modified to meet the specific needs of the project.

The second is to compile the library separately with the description of the library, which accounts for 48.48%, which can separate the compilation process of the library from the project, and can also improve the reusability and maintainability of the code. In addition, 37.80% of respondents use system package managers, such as apt, brew, etc., to simplify the management of dependencies and make it easier to update and upgrade libraries.

8. What build tools do you use? (please select all that apply)

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

According to the survey results, CMake, which is widely used to manage and build C++ projects, is the most popular build tool, and its cross-platform nature and rich functionality make it a mainstream choice—more than 1,000 out of 1,200+ respondents chose CMake, accounting for 83.24%. This is followed by Ninja at 45.41%, which is often used in conjunction with CMake to speed up the build process of a project, and is favored in some large projects or scenarios that require frequent builds. Make/nmake is another common build tool, with 36.31% of developers using it.

9. Which version of C++ is allowed in your current project (work or study)?

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

Of all C++ releases, C++11 is currently the most widely used, with 90.81% of developers saying that almost all of C++11's features are available. In the latest version of C++23, 61.17% of people said that their environment is not supportable.

10. In the next 12 months, do you plan to start allowing more of the newer C++ standard features in your current project?

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

In response to this question, 53.92% of developers plan to use more of the newer C++ standard features in the next 12 months, reflecting the need and trend to adopt the latest C++ standard and take advantage of these new features to stay competitive in a competitive market.

On the other hand, 21.12% of respondents said they did not have such a plan. This may be due to things like the stability and security of the project, or it may be due to the large code base in the project, which can introduce some unnecessary risk and complexity with the introduction of new C++ standard features.

11. Key features specifically for C++20/23: Does your current project plan to allow these features in production code in the next 12 months?

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

For the main features of C++20/23, developers plan to allow them to be used in production code over the next 12 months differently, focusing on Concepts, Coroutines, and Modules.

Concepts is an important feature introduced in C++20 to constrain the type parameters of a template, improving the clarity and readability of your code. This is also the main feature that attracted the most attention among the respondents, accounting for 60.45%. This is followed by Coroutines (co_await, etc.), which can be used to write asynchronous code to improve code concurrency and responsiveness, with 34.13% of developers planning to use the feature in production code in the next 12 months. Modules chosen by 29.25% of respondents are another important feature introduced in C++20 to improve code organization and build efficiency.

12. What other programming languages/environments do you use on your current and recent projects besides C++? (please select all that apply)

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

In addition to C++, Python is popular for its concise syntax, rich standard library, and wide range of applications, and is the most used programming language among respondents, accounting for 72.82%. The second most used is C, which is commonly used to write operating systems, embedded systems, game engines, etc., and the third is JavaScript (27.43%). This was followed by C# (23.76%) and Rust (18.37%), with the former being used for application development on the Windows platform, and the latter being favored by major manufacturers in recent years due to its security.

13. What development environments (IDEs) or editors do you use for C++ development?

C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report
C++ 11 is the most widely accepted!The 2024 C++ Developer Annual Survey is the latest report

When developing in C++, respondents use development environments (IDEs) or editors that include Visual Studio, Visual Studio Code, CLion, Vim, Emacs, etc.

Among them, Visual Studio is the most used development environment (62.03%) among respondents, and is widely used for C++ development on the Windows platform. This is followed by Visual Studio Code (VS Code for short) at 50.27%, which supports multiple programming languages and extends its functionality through plug-ins, making it one of the tools of choice for many developers.

CLion, an integrated development environment for C++ development by JetBrains, was also popular with 45.32% of developers, while Vim and Emacs also accounted for 36.96% and 38.79% respectively.

The full report can be found here: https://isocpp.org/files/papers/CppDevSurvey-2024-summary.pdf

Read on