X-Git-Url: https://deadsoftware.ru/gitweb?a=blobdiff_plain;f=Test.obn;h=fa347cddf19074ac48f9ac84d99c4993074f5aef;hb=ba8ed2cfa675b23cb19cba538f719a07a79ffb7f;hp=98ac0e23e370819a8b9e96db5387e7f64d97eb65;hpb=a0ff807fe0e69c50469e506836467da32f23f754;p=dsw-obn.git diff --git a/Test.obn b/Test.obn index 98ac0e2..fa347cd 100644 --- a/Test.obn +++ b/Test.obn @@ -1,12 +1,21 @@ MODULE Test; +IMPORT Files, Out; + VAR - a : POINTER TO RECORD END; - b : POINTER TO ARRAY OF INTEGER; - c : PROCEDURE; + f : Files.File; + r : Files.Rider; + len : LONGINT; + x : POINTER TO ARRAY OF CHAR; BEGIN - a := NIL; - b := NIL; - c := NIL; + f := Files.Old("Test.obn"); + ASSERT(f # NIL); + Files.Set(r, f, 0); + + len := Files.Length(f); + NEW(x, len + 1); + + Files.ReadBytes(r, x, len); + Out.String(x^); Out.Ln; END Test.