X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=includes%2FInfoTables.h;h=67bd97bc8f762b3d27e675daa2b2f98c96624b4c;hb=d914b83e6b1baafc8d830eff1aedbe55d25d84cc;hp=8fa699a0970c0bcdb3cb40dd8ec304340b0af75c;hpb=0065d5ab628975892cea1ec7303f968c3338cbe1;p=ghc-hetmet.git diff --git a/includes/InfoTables.h b/includes/InfoTables.h index 8fa699a..67bd97b 100644 --- a/includes/InfoTables.h +++ b/includes/InfoTables.h @@ -353,7 +353,6 @@ typedef struct { #else StgInfoTable i; StgSRT *srt; /* pointer to the SRT table */ - StgFunPtr vector[FLEXIBLE_ARRAY]; #endif } StgRetInfoTable; @@ -380,6 +379,23 @@ typedef struct _StgThunkInfoTable { #endif } StgThunkInfoTable; +/* ----------------------------------------------------------------------------- + Constructor info tables + -------------------------------------------------------------------------- */ + +typedef struct _StgConInfoTable { +#if !defined(TABLES_NEXT_TO_CODE) + StgInfoTable i; +#endif + + OFFSET_FIELD(con_desc) // the name of the data constructor + // as: Package:Module.Name + +#if defined(TABLES_NEXT_TO_CODE) + StgInfoTable i; +#endif +} StgConInfoTable; + /* ----------------------------------------------------------------------------- Accessor macros for fields that might be offsets (C version) @@ -396,6 +412,16 @@ typedef struct _StgThunkInfoTable { #endif /* + * GET_CON_DESC(info) + * info must be a StgConInfoTable*. + */ +#ifdef TABLES_NEXT_TO_CODE +#define GET_CON_DESC(info) ((char *)((StgWord)((info)+1) + (info->con_desc))) +#else +#define GET_CON_DESC(info) ((info)->con_desc) +#endif + +/* * GET_FUN_SRT(info) * info must be a StgFunInfoTable* */