Mikroelektronika MIKROE-742 데이터 시트

다운로드
페이지 532
Accessing Fields
You can access the fields of a record by means of dot (
.
) as a direct field selector.
If we have declared variables 
circle1
and 
circle2
of previously defined type
TCircle
:
var circle1, circle2 : TCircle;
we could access their individual fields like this:
circle1.radius := 3.7;
circle1.center.x := 0;
circle1.center.y := 0;
You can also commit assignments between complex variables, if they are of the
same type:
circle2 := circle1; // This will copy values of all fields
152
MIKROELEKTRONIKA
- SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Language Reference
mikroPASCAL PRO for AVR
CHAPTER 5