HP SunSoft Pascal 4.0 Manual de usuario Pagina 175

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 333
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 174
The C++–Pascal Interface 151
7
Simple Types without the -xl Option
Without the -xl option, simple types match, as in the following example:
The Pascal procedure,
SimVal.p
procedure SimVal(
t, f: boolean;
c: char;
si:integer16;
i: integer;
sr:shortreal;
r: real;
var Reply: integer);
begin
Reply := 0;
if t then
Reply := Reply + 1;
if not f then
Reply := Reply + 8
if c='z' then
Reply := Reply + 64;
if si=9 then
Reply := Reply + 512;
if i=9 then
Reply := Reply + 4096;
if sr=shortreal(9.9) then
Reply := Reply + 32768;
if r=9.9 then
Reply := Reply + 262144;
end;
Vista de pagina 174
1 2 ... 170 171 172 173 174 175 176 177 178 179 180 ... 332 333

Comentarios a estos manuales

Sin comentarios