|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - download
Length: 1858 (0x742) Types: TextFile Notes: R1k Text-file segment
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000 └─ ⟦5a81ac88f⟧ »Space Info Vol 1« └─⟦251ae465d⟧ └─⟦this⟧
with Text_Io, Dynamic_Value; procedure Test_Value is V1, V2, V3: Dynamic_Value.Object; I : Integer; Ok : Boolean; begin Text_Io.Put ("je rentre dans le programme de test "); Text_Io.New_Line; Dynamic_Value.Set_Value (V1, 10); Dynamic_Value.Set_Value (V2, 25); Text_Io.Put (Dynamic_Value.Kinds'Image (Dynamic_Value.Get_Kind (V1))); Text_Io.New_Line; Text_Io.Put (Dynamic_Value.Kinds'Image (Dynamic_Value.Get_Kind (V2))); Text_Io.New_Line; declare begin Text_Io.Put ("je lis le nombre entier V1"); Text_Io.New_Line; I := Dynamic_Value.Get_Value (V1); Text_Io.Put ("lecture reussie ,l'entier vaut "&Integer'image(I)); Text_Io.New_Line; exception when Dynamic_Value.Bad_Kind => Text_Io.Put ("exception levee !"); Text_Io.New_Line; end; declare begin Ok := Dynamic_Value.Are_Equal (V1, V2); if (Ok) then Text_Io.Put ("v1 = v2"); Text_Io.New_Line; else Text_Io.Put ("v1 different de v2"); Text_Io.New_Line; end if; exception when Dynamic_Value.Bad_Kind => Text_Io.Put ("exception levee !"); Text_Io.New_Line; end; declare begin Dynamic_Value.Change_Sign(Obj => V2, result => V2); text_io.put("V2 = -V2 = "&integer'image(dynamic_Value.Get_Value(V2))); exception when Dynamic_Value.Bad_Kind => text_io.put("exception levee !");text_io.new_line; end; declare begin Dynamic_Value.Add (left => V1, right => V2, result => V3); text_io.put("V1+V2 = "&integer'image(dynamic_Value.Get_Value(V3))); text_io.new_Line; exception when Dynamic_Value.Bad_Kind => text_io.put("exception levee !");text_io.new_line; end; end Test_Value