Code Analysis++quality/analysis? –Code Analysis: CI – https://www.sonarsource.com https://rules.sonarsource.com/cpp • Linter 549 rules • CI/CD integration • Code reviews • PR decorations https://www.jetbrains https://rules.sonarsource.com/cpp/tag/misra-c++2008 (51 rules) ● https://rules.sonarsource.com/cpp/tag/misra-c2004 (14 rules) ● https://rules.sonarsource.com/cpp/tag/misra-c2012 (10 rules) ● PVS-Studio Style ○ Formatting, Naming, Syntax style, …Formatting – ● ClangFormat ○ Formatting standard in C++ nowadays ○ Breaking compatibility ○ Fuzzy parsingNaming – ● Naming ○ camelCase, PascalCase0 码力 | 61 页 | 2.70 MB | 6 月前3
 Back To Basics Functionsmust have a name: The name should describe ‘what’ the function is doing at a minimum Some naming rules: ● Functions names must start with a letter or underscore. ● Note: ‘Usually’ names that begin described by the function name. Local variables declared in the function body follow normal scoping rules. Notes on function body: ● Later on we’ll see that the function body usually is defined in a source better C++ approach is to group functions together in a namespace ○ This makes it easy to avoid naming collisions ■ (Someone else probably wrote an ‘add’ function at some point in a large enough project)0 码力 | 123 页 | 7.26 MB | 6 月前3
 Conan 1.17 DocumentationNote: When writing your own conanfile.py references, please bear in mind that you should follow the rules in conan- file.py 5.1.2 The test_package Folder Note: The test_package differs from the library any PackageA */*@project/*: john # Allow john to access any package from the "project" user The rules are evaluated in order. If the left side of the pattern matches, the rule is applied and it will not those packages that really need to be built, following the --build arguments and the package_id() rules. 114 Chapter 9. Versioning conan Documentation, Release 1.17.2 For more information see Commands0 码力 | 567 页 | 4.53 MB | 1 年前3
 Conan 1.18 DocumentationNote: When writing your own conanfile.py references, please bear in mind that you should follow the rules in conan- file.py 5.1.2 The test_package Folder Note: The test_package differs from the library package from the "project" user 6.5. Running conan_server 71 conan Documentation, Release 1.18.5 The rules are evaluated in order. If the left side of the pattern matches, the rule is applied and it will not those packages that really need to be built, following the --build arguments and the package_id() rules. For more information see Commands 110 Chapter 9. Versioning conan Documentation, Release 1.180 码力 | 584 页 | 4.80 MB | 1 年前3
 Conan 1.19 DocumentationNote: When writing your own conanfile.py references, please bear in mind that you should follow the rules in conan- file.py 5.1.2 The test_package Folder Note: The test_package differs from the library package from the "project" user 6.5. Running conan_server 73 Conan Documentation, Release 1.19.3 The rules are evaluated in order. If the left side of the pattern matches, the rule is applied and it will not those packages that really need to be built, following the --build arguments and the package_id() rules. For more information see Commands 116 Chapter 9. Versioning Conan Documentation, Release 1.190 码力 | 609 页 | 4.88 MB | 1 年前3
 Conan 1.20 DocumentationNote: When writing your own conanfile.py references, please bear in mind that you should follow the rules in conan- file.py 5.1.2 The test_package Folder Note: The test_package differs from the library package from the "project" user 6.5. Running conan_server 73 Conan Documentation, Release 1.20.5 The rules are evaluated in order. If the left side of the pattern matches, the rule is applied and it will not those packages that really need to be built, following the --build arguments and the package_id() rules. For more information see Commands 116 Chapter 9. Versioning Conan Documentation, Release 1.200 码力 | 611 页 | 4.89 MB | 1 年前3
 Conan 1.10 DocumentationNote: When writing your own conanfile.py references, please bear in mind that you should follow the rules in conan- file.py 5.1.2 The test_package Folder Note: The test_package differs from the library any PackageA */*@project/*: john # Allow john to access any package from the "project" user The rules are evaluated in order. If the left side of the pattern matches, the rule is applied and it will not $(CXXFLAGS) $(LDFLAGS) $(LDLIBS) \ -o $(EXE_FILENAME) #---------------------------------------- # Make Rules #---------------------------------------- .PHONY : exe exe : $(EXE_FILENAME) $(EXE_FILENAME) :0 码力 | 479 页 | 3.09 MB | 1 年前3
 Conan 1.11 DocumentationNote: When writing your own conanfile.py references, please bear in mind that you should follow the rules in conan- file.py 5.1.2 The test_package Folder Note: The test_package differs from the library any PackageA */*@project/*: john # Allow john to access any package from the "project" user The rules are evaluated in order. If the left side of the pattern matches, the rule is applied and it will not $(CXXFLAGS) $(LDFLAGS) $(LDLIBS) \ -o $(EXE_FILENAME) #---------------------------------------- # Make Rules #---------------------------------------- .PHONY : exe exe : $(EXE_FILENAME) $(EXE_FILENAME) :0 码力 | 490 页 | 4.05 MB | 1 年前3
 Conan 1.16 DocumentationNote: When writing your own conanfile.py references, please bear in mind that you should follow the rules in conan- file.py 5.1.2 The test_package Folder Note: The test_package differs from the library any PackageA */*@project/*: john # Allow john to access any package from the "project" user The rules are evaluated in order. If the left side of the pattern matches, the rule is applied and it will not $(CXXFLAGS) $(LDFLAGS) $(LDLIBS) \ -o $(EXE_FILENAME) #---------------------------------------- # Make Rules #---------------------------------------- .PHONY : exe exe : $(EXE_FILENAME) $(EXE_FILENAME) :0 码力 | 545 页 | 4.34 MB | 1 年前3
 Expressive Compile-time Parserscommunicates its purpose. Relies on both the syntax of the programming language and the quality of naming conventions.Syntax Evolution C++ 98: C++ 11: static const int arr[] = {1,2,3,4}; vectorv(arr metafunctions::get<_STR("times4")> times4;Boost Metaparse - Grammar Create a parser from grammar rules typedef grammar<_STR("plus_exp")> ::rule<_STR("int ::= ('0'|'1'|'2'|...|'9')+"), int_action>::type As...>) -> list ; auto pop_front(empty_list) -> empty_list;CTRE – LL(1) Parser The grammar rules lookup table is implemented as empty structs and function overloads struct pcre { struct backslash{}; 0 码力 | 134 页 | 1.73 MB | 6 月前3
共 156 条
- 1
 - 2
 - 3
 - 4
 - 5
 - 6
 - 16
 













