fix some tests
[calc.git] / program.h
index 3d459d631c318aeac1ed05311aa5d5e2916f37a3..f3f5369981795ba5e49c87e607c960c92d2a44d8 100644 (file)
--- a/program.h
+++ b/program.h
@@ -3,32 +3,16 @@
 
 #include "element.h"
 #include "tabular.h"
+#include "workspace.h"
 
 /* global variables */
 
-extern int argument_size;
-extern double *argument;
-
-/* workspace type */
-
-typedef struct _workspace_t {
-    int id;
-    double answer;
-    tab_t *storage;
-    double *argument;
-    int argument_size;
-    element_t *root;
-    tab_t *stack;
-    char *string;
-} workspace_t;
-
-extern workspace_t *programs;
+extern workspace_t **programs;
 extern int nb_programs;
 
 /* program function */
 
 void prog (int id, element_t *root);
-double arg (int id);
 double call (int id, int nbargs, element_t **args);
 void list ();
 void edit (int id);