Main Content

Preserve unused fields and properties

Preserve unused class properties or structure fields in the generated C/C++ code

Since R2022a

Description

App Configuration Pane: Memory

Configuration Objects: coder.EmbeddedCodeConfig

Preserve unused class properties or structure fields in the generated C/C++ code.

See Preserve Unused Class Properties in Generated C/C++ Code (Embedded Coder).

Settings

Off

This value is the default value.

The code generator produces the C/C++ code by removing the unused properties and fields in the generated code.

On

The code generator produces the C/C++ code by preserving the unused properties and fields in the generated code.

Programmatic Use

Property: PreserveUnusedStructFields
Values: false | true
Default: false

Version History

Introduced in R2022a