DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦789b9b88f⟧ Ada Source

    Length: 3072 (0xc00)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Pair_Ball_And_Boxes_Rule, seg_02a456, separate Bbr_General_Bundle

Derivation

└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
    └─ ⟦5a81ac88f⟧ »Space Info Vol 1« 
        └─⟦this⟧ 

E3 Source Code



separate (Bbr_General_Bundle)
package body Pair_Ball_And_Boxes_Rule is

    function Premiss return Join_Descriptor is
    begin
        return (Balls.Exist ((Size   => Say_It_Is (S),
                              Colour => Say_It_Is (C),
                              Place  => Is_Equal (On_Heap))),

                Boxes.Exist ((Colour => Is_Equal (C),
                              Size   => Say_It_Is (T) and Is_Greater (S),
                              State  => Is_Equal (Free))),

                Boxes.Absent ((Colour => Is_Equal (C),
                               Size   => Is_Less (T) and Is_Greater (S),
                               State  => Is_Equal (Free))));
    end Premiss;

    procedure Action (The_Pair : Fact.Collection) is
        The_Ball : Fact.Name renames The_Pair (1);
        The_Box  : Fact.Name renames The_Pair (2);
    begin

        Text_Io.Put_Line ("Ball            : " & Balls.Image (The_Ball));
        Text_Io.Put_Line ("Paired with box : " & Boxes.Image (The_Box));

        Balls.Change (The_Ball, Place, To_Value => In_Box);
        Boxes.Change (The_Box, State, To_Value => Busy);

    end Action;

end Pair_Ball_And_Boxes_Rule;



E3 Meta Data

    nblk1=2
    nid=0
    hdr6=4
        [0x00] rec0=1a rec1=00 rec2=01 rec3=03a
        [0x01] rec0=0b rec1=00 rec2=02 rec3=001
    tail 0x21723af6c83e26b6cde1d 0x42a00088462063c03