Hello,
I want to break some unit circularity definitions with access types as for instance with record:
type R1;
type AR1 is access R1;
type R1 is record
Data : Natural;
Next : AR1;
end record;
In my case, I have a unit:
package test_20240113_modr is
type R2 is record
Data : Natural;
end record;
type AR2 is access R2;
end test_20240113_modr;
"limited withed" in:
limited with test_20240113_modr;
package test_20240113_mods is
procedure PS1 (V : test_20240113_modr.R2);
procedure PS2 (V : test_20240113_modr.AR2);
end;
Let's imagine the circularity, thus PS1 and PS2 definition are legal.
Of course the following isn't legal:
type AS1 is array (1..2) of test_20240113_modr.R2; -- illegal
However why not with access type:
type AS2 is array (1..2) of test_20240113_modr.AR2; -- illegal
Well, I could make some code transferts from unit to another or access conversions, that's I actually do but at heavy cost.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 399 |
Nodes: | 16 (2 / 14) |
Uptime: | 65:06:48 |
Calls: | 8,355 |
Calls today: | 15 |
Files: | 13,159 |
Messages: | 5,893,953 |
Posted today: | 1 |