Hello, Habr!
JetBrains has started a new release year: all our desktop products have been updated or will be updated in the very near future. Today we want to talk about CLion 2021.1, the latest version of our cross-platform IDE for C and C ++ development.
:
Clazy
MISRA
Makefile
(CMake, Makefile, Qt)
C C++
IntelliJ
30 . CLion All Products Pack, 2021.1. , .
2021.1 .
โ , , . (dangling pointer), (null dereferencing), , (, , , , โ , ) .
โ . (DFA) CLion , 2020 Clang . 2021 , . ?
. CLion 2020.3 .
(TU), . , CLion 2021.1.
, :
:
:
โ , .
โ , .
โ , .
, Lifetime-. -, , !
Clazy
Qt-. , QML :( Clang Clazy โ Qt. CLion :
Settings/Preferences | Editor | Inspections | C/C++ | General | Clazy. level โ Clazy. CLion 2021.1 CLazy 1.8.
MISRA
CLion MISRA C 2012 MISRA C++ 2008. , , .
MISRA AUTOSAR.
- :
Makefile
CLion 2021.1 Makefile. , Settings/Preferences | Build, Execution, Deployment | Makefile .
IDE , , Google Sanitizers, Valgrind Memcheck . , , ( ).
, CLion :
(Line coverage) โ , GCC/gcov. , ,
return 0; int c;
100%.
(Statement coverage) โ , LLVM/llvm-cov. , , , 100% .
(Branch coverage) โ GCC/gcov, LLVM/llvm-cov 12.0.0. , GCC/gcov , , LLVM/llvm-cov โ . gcov 100% ยซโ ยปโ, , , - .
- ( ). , CLion ssh- . , ( , IDE ). . Tools | Open Remote Host Terminal . , โ , .
Code With Me โ . , . :
CLion , . !
(CMake, Makefile, Qt)
Makefile Clazy Qt. CLion 2021.1 .
CMake
CMake 3.19 (, , Apple Silicon โ M1. CMake 3.20 โ CLion 2021.1, CMake CLion.
CMake, IDE, VCS. Share Settings/Preferences | Build, Execution, Deployment | CMake, cmake.xml . : CMake Presets , (CPP-22906).
Makefile
Makefile โ . , CLion Makefile Language, . make
, , Find Usages , Makefile.
Qt
Clazy, Qt- โ Qt UI Class:
.
QtCreator.
:
C C++
C C++ (UFCS)? ! C C++ . , :
:
, . Settings/Preferences | Editor | General | Postfix Completion.
, :
:
sysroot. , .
LLDB , , ( ). GDB, LLDB.
Set Execution Point C/C++, :
. , .
IntelliJ
ยซยป CLion IntelliJ. , , :
,
Git-
Save to Shelf .
CLion Rust-. IntelliJ Rust โ . , Change Signature , Find Usages Cargo.
Swift. : โ CLion, AppCode!?โ , AppCode Mac, Swift Ubuntu, Windows. Swift Windows โ , . AppCode. , Swift Windows, Appcode.
. , CLion, .
! , โ , , !
CLion
The Drive to Develop