From: sewardj Date: Thu, 23 Mar 2000 10:53:26 +0000 (+0000) Subject: [project @ 2000-03-23 10:53:26 by sewardj] X-Git-Tag: Approximately_9120_patches~4922 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=b14d8a684988b94d4061862d738b19e91af1e0d6;p=ghc-hetmet.git [project @ 2000-03-23 10:53:26 by sewardj] storage.h needs to see a machine-dependant file-timestamp type for use in Module symbol table entries -- hence this file. --- diff --git a/ghc/interpreter/machdep_time.h b/ghc/interpreter/machdep_time.h new file mode 100644 index 0000000..63f9bb5 --- /dev/null +++ b/ghc/interpreter/machdep_time.h @@ -0,0 +1,22 @@ + +#ifndef MACHDEP_TIME_INCLUDED +#define MACHDEP_TIME_INCLUDED + +#ifdef HAVE_TIME_H +# include +#endif + +#if RISCOS +typedef struct { unsigned hi, lo; } Time; +#define timeChanged(now,thn) (now.hi!=thn.hi || now.lo!=thn.lo) +#define timeSet(var,tm) var.hi = tm.hi; var.lo = tm.lo +#error firstTimeIsLater, whicheverIsLater needs implementing +#else +typedef time_t Time; +#define timeChanged(now,thn) (now!=thn) +#define timeSet(var,tm) var = tm +#define firstTimeIsLater(t1,t2) ((t1)>(t2)) +#define whicheverIsLater(t1,t2) (((t1)>(t2)) ? (t1) : (t2)) +#endif + +#endif