EasyManuals Logo

Texas Instruments TI-89 Software Guide

Texas Instruments TI-89
334 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #214 background imageLoading...
Page #214 background image
202
Section 3: Assembler
TI
-
89 / TI
-
92 Plus Sierra C Assembler Reference Manual
Not for Distribution
Beta Version February 2, 2001
.struct — Begin a Structure Template Section
Syntax
.struct [
label
]
Description
label
Specifies a label that is used for documentation purposes. It is not
entered in the symbol table.
The
.struct
directive begins a structure template section. This type of section is
used in conjunction with the
.space
and
.align
directives to define labels suitable
for structure field references. These labels are not included in the object file’s
symbol table.
Structure template sections begin at absolute address zero. Since they are
dummy sections, they cannot contain any object code. Also, they cannot be
nested; however, fields of a nested structure can be treated as part of the
enclosing structure. The
.ends
directive is used to end a structure template
section and resume the previously active section.
Example
.struct node ; struct node {
visited: .space 1 ; char visited;
.align 2 ; struct position {
pos.x: .space 2 ; short int x;
pos.y: .space 2 ; short int y;
.align 4 ; } pos;
left: .space 4 ; struct node *left;
right: .space 4 ; struct node *right;
.ends ; };
move.b #1,_n+visited ; n.visited = 1;
movea.l _p,a0 ; p
−
>right = NULL;
clr.l (right,a0) ;
This example illustrates how the
.struct
and
.ends
directives are used to define
a set of structure field labels. The
.space
and
.align
directives are used to
allocate space and maintain proper alignment, respectively.

Table of Contents

Other manuals for Texas Instruments TI-89

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TI-89 and is the answer not in the manual?

Texas Instruments TI-89 Specifications

General IconGeneral
Display size (HxV)100 x 160 mm
Memory type639K FLASH ROM, 188K bytes RAM
Compatible operating systemsOperating System 2.09
Battery typeAAA

Related product manuals