Fix REPOSITION-FILE, HISTORY, locked file handle and other problems.
[pforth] / csrc / pf_guts.h
index 806ff84..acb92a6 100644 (file)
@@ -23,7 +23,7 @@
 ** PFORTH_VERSION changes when PForth is modified and released.\r
 ** See README file for version info.\r
 */\r
 ** PFORTH_VERSION changes when PForth is modified and released.\r
 ** See README file for version info.\r
 */\r
-#define PFORTH_VERSION "26"\r
+#define PFORTH_VERSION "27"\r
 \r
 /*\r
 ** PFORTH_FILE_VERSION changes when incompatible changes are made\r
 \r
 /*\r
 ** PFORTH_FILE_VERSION changes when incompatible changes are made\r
@@ -279,6 +279,8 @@ enum cforth_primitive_ids
        /* Added to support 64 bit operation. */\r
        ID_CELL,\r
        ID_CELLS,\r
        /* Added to support 64 bit operation. */\r
        ID_CELL,\r
        ID_CELLS,\r
+       /* DELETE-FILE */\r
+       ID_FILE_DELETE,\r
 /* If you add a word here, take away one reserved word below. */\r
 #ifdef PF_SUPPORT_FP\r
 /* Only reserve space if we are adding FP so that we can detect\r
 /* If you add a word here, take away one reserved word below. */\r
 #ifdef PF_SUPPORT_FP\r
 /* Only reserve space if we are adding FP so that we can detect\r
@@ -297,7 +299,6 @@ enum cforth_primitive_ids
        ID_RESERVED11,\r
        ID_RESERVED12,\r
        ID_RESERVED13,\r
        ID_RESERVED11,\r
        ID_RESERVED12,\r
        ID_RESERVED13,\r
-       ID_RESERVED14,\r
        ID_FP_D_TO_F,\r
        ID_FP_FSTORE,\r
        ID_FP_FTIMES,\r
        ID_FP_D_TO_F,\r
        ID_FP_FSTORE,\r
        ID_FP_FTIMES,\r
@@ -422,26 +423,22 @@ typedef struct pfDictionary_s
        ucell_t  dic_Flags;\r
 /* Headers contain pointers to names and dictionary. */\r
 \r
        ucell_t  dic_Flags;\r
 /* Headers contain pointers to names and dictionary. */\r
 \r
-       uint8_t *dic_HeaderBaseUnaligned;\r
+       ucell_t dic_HeaderBaseUnaligned;\r
 \r
 \r
-       uint8_t *dic_HeaderBase;\r
-       union\r
-       {\r
-               cell_t  *Cell;\r
-               uint8_t *Byte;\r
-       } dic_HeaderPtr;\r
-       uint8_t *dic_HeaderLimit;\r
+       ucell_t dic_HeaderBase;\r
+       ucell_t dic_HeaderPtr;\r
+       ucell_t dic_HeaderLimit;\r
 /* Code segment contains tokenized code and data. */\r
 \r
 /* Code segment contains tokenized code and data. */\r
 \r
-       uint8_t *dic_CodeBaseUnaligned;\r
+       ucell_t dic_CodeBaseUnaligned;\r
 \r
 \r
-       uint8_t *dic_CodeBase;\r
+       ucell_t dic_CodeBase;\r
        union\r
        {\r
                cell_t  *Cell;\r
                uint8_t *Byte;\r
        } dic_CodePtr;\r
        union\r
        {\r
                cell_t  *Cell;\r
                uint8_t *Byte;\r
        } dic_CodePtr;\r
-       uint8_t *dic_CodeLimit;\r
+       ucell_t dic_CodeLimit;\r
 } pfDictionary_t;\r
 \r
 /* Save state of include when nesting files. */\r
 } pfDictionary_t;\r
 \r
 /* Save state of include when nesting files. */\r
@@ -487,7 +484,7 @@ extern ExecToken     gAcceptP_XT;         /* XT of ACCEPT */
 extern cell_t         gDepthAtColon;\r
 \r
 /* Global variables. */\r
 extern cell_t         gDepthAtColon;\r
 \r
 /* Global variables. */\r
-extern char         *gVarContext;    /* Points to last name field. */\r
+extern cell_t        gVarContext;    /* Points to last name field. */\r
 extern cell_t        gVarState;      /* 1 if compiling. */\r
 extern cell_t        gVarBase;       /* Numeric Base. */\r
 extern cell_t        gVarEcho;       /* Echo input from file. */\r
 extern cell_t        gVarState;      /* 1 if compiling. */\r
 extern cell_t        gVarBase;       /* Numeric Base. */\r
 extern cell_t        gVarEcho;       /* Echo input from file. */\r