Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 23 Next »

A feature might be in either the 'Needs validation', 'Allowed' or 'Disallowed' state. The significance of these states are as follows:

  1. Needs validation
    1. The feasibility of using the feature in CRYENGINE's code base is yet to be validated by the CRYENGINE Technical Council.
  2. Allowed
    1. The feature doesn't introduce 'show-blocking' issues.
    2. The feature improves, or at least doesn't harm, code runtime and compile time performance.
    3. The feature improves, or at least doesn't harm, code readability or debugability. 
    4. The feature is supported by all the compilers that the CRYENGINE code base is compiled against.
  3. Disallowed
    1. The feature introduces a 'show-blocking' issue.
    2. The feature has a negative impact on runtime and compile time performance.
    3. The feature has a negative impact on code readability and debugability.
    4. The feature generally doesn't contribute to the overall quality and performance of the CRYENGINE code base.
    5. The feature is not supported by a CRYENGINE code base compiler.

C++17 Language Features

Template argument deduction for class templatesNeeds validation-
Declaring non-type template parameters with autoNeeds validation-
Folding expressionsNeeds validation-
New rules for auto deduction from braced-init-listNeeds validation-
Constexpr lambdaNeeds validation-
Lambda capture this by valueNeeds validation-
Inline variablesNeeds validation-
Nested namespacesAllowedThis feature is considered light weight and doesn’t negatively impact code quality or run-time/compile-time performance. It is one of the first C++17 features adopted by compiler vendors, and has therefore been made available even on older tool-chains such as vc140. It is more of a cosmetic feature, since it helps improve readability in nested namespace scenarios.
Structured bindingsNeeds validation-
Selection statements with initializerNeeds validation-
Constexpr ifNeeds validationThe feature greatly simplifies compile-time branching that was only possible through overloading or specialization / SFINAE. It improves compile-time and readability. The feature is available on all platforms and compilers (VS2017.3)
Utf-8 character literalsNeeds validation-
Direct-list-initialization of enumsNeeds validation-
New standard attributesNeeds validation-
Terse static_assertNeeds validation

The terse form of static_assert is useful when the evaluated expression contains enough information that an additional message feels redundant.

Supported by all compilers. (VS2017.0)


static_assert(std::is_default_constructible_v<T>) is equally readable than static_assert(std::is_default_constructible_v<T>, "Must be default constructible")

C++17 Library Features

std::variantDisallowedNot supported on PS4 as of SDK 6.5.
std::optionalNeeds validation-
std::anyNeeds validation-
std::string_viewNeeds validation-
std::invokeNeeds validation-
std::applyNeeds validation-
std::filesystemNeeds validation-
std::byteNeeds validation-
Splicing for maps and setsNeeds validation-
Parallel algorithmsNeeds validation-

C++14 Language Features

Binary literalsNeeds validation-
Generic lambda expressionsNeeds validation

Taking parameters by auto type makes lambda on-par with template functions. It is a great improvements to callbacks and generic algorithms that would be otherwise unnecessarily verbose. It also enables designs such as generic visitor pattern which wasn't possible without the feature.

The feature is supported by all compilers.

Lambda capture initializersNeeds validation-
Return type deductionNeeds validation-
Decltype(auto)Needs validation-
Relaxing constraints on constexpr functionsNeeds validation

The feature allows constexpr function to be written in almost identical style as normal run-time functions, improving readability and compile time.

Supported by all compilers.

Variable templatesNeeds validation-
[[deprecated]] attributeNeeds validation-

C++14 Library Features

User-defined literals for standard library typesNeeds validation-
Compile-time integer sequencesNeeds validation-
std::make_uniqueNeeds validation-

On This Page

  • No labels