Array container type
Model Configuration Pane: Code Generation / Code Style
Description
Specify the container type for arrays in the generated code. Choose either C-style array or std::array
.
Dependencies
To enable this parameter, set Language to
C++
and set Code interface packaging
to C++ class
.
Settings
C-style array
(default) | std::array
Default: C-style array
C-style array
The code generator generates array containers by using C-style arrays.
std::array
std::array
is a template class that represents fixed-size arrays. If you choose this option, the code generator generates array containers by usingstd::array
.
Examples
Recommended Settings
Application | Setting |
---|---|
Debugging | No impact |
Traceability | No impact |
Efficiency | No impact |
Safety precaution | No recommendation |
Programmatic Use
Parameter: ArrayContainerType |
Type: character vector |
Value: 'C-style array' |'std::array' |
Default: 'C-style array' |
Version History
Introduced in R2020a