Dynamic array container type
Model Configuration Pane: Code Generation / Code Style
Description
Specify a container type for dynamic arrays in the generated code. Choose either
coder::array
or std::vector
.
Dependencies
To enable this parameter, set the Language model configuration parameter to
C++
.
Settings
std::vector
(default) | coder::array
Default:
std::vector
std::vector
The code generator generates
std::vector
containers to represent dynamic arrays.coder::array
The code generator generates
coder::array
containers to represent dynamic arrays. If you open a model that was created before R2024b, the model defaults to this setting.
Examples
Recommended Settings
Application | Setting |
---|---|
Debugging | No impact |
Traceability | No impact |
Efficiency | No impact |
Safety precaution | No recommendation |
Programmatic Use
Parameter:
DynamicArrayContainerType
|
Type:
character vector |
Values:
'std::vector' |'coder::array' |
Default:
'std::vector' |
Version History
Introduced in R2024b