Structures
MATLAB® Coder™ supports code generation for structures with a set of restrictions on the operations, the properties of values of scalar structures, and the structure arrays. You can generate code for scalar structures as well as structure arrays. Adhere to restrictions for indexing and assigning values to substructures and fields. Structure arguments are passed by reference or by value in generated code.
함수
coder.cstructname | Name C structure type in generated code |
도움말 항목
- 코드 생성을 위한 구조체 정의
코드 생성을 위한 MATLAB 코드에 구조체를 사용합니다.
- 코드 생성을 위해 허용되는 구조체 작업
코드 생성에 지원되는 구조체 작업을 사용합니다.
- Define Scalar Structures for Code Generation
Adhere to code generation restrictions for scalar structures.
- 코드 생성을 위한 구조체 배열 정의하기
구조체 배열에 대한 코드 생성 제한 사항을 따릅니다.
- Index Substructures and Fields
Adhere to code generation restrictions for indexing substructures and fields.
- Assign Values to Structures and Fields
Adhere to code generation restrictions for assigning values to structures and fields.
- Pass Structure Arguments by Reference or by Value in Generated Code
Control whether structure arguments are passed by reference or by value.
- Name the C Structure Type to Use with a Global Structure Variable
Use
coder.cstructname
to define a type object for a global structure.