Browse Source

Time: Added procedure Timestamp, returns Unix timestamp

Arthur Yefimov 11 months ago
parent
commit
3e7d8b5143
1 changed files with 5 additions and 0 deletions
  1. 5 0
      src/Time.Mod

+ 5 - 0
src/Time.Mod

@@ -1,6 +1,11 @@
 MODULE Time;
 IMPORT Platform, Int;
 
+TYPE Time* = INTEGER;
+
+PROCEDURE Timestamp*(): Time;
+RETURN Platform.Time() END Timestamp;
+
 PROCEDURE GetClock*(VAR time, date: INTEGER);
 BEGIN
   Platform.GetClock(time, date)