# HG changeset patch # User jwe # Date 773505543 0 # Node ID 101e1d4f2395ff9ceaa28ed4efc65281403a2ef6 # Parent 89ed09321d1621ffeefe492d8d6cedf26e888b76 [project @ 1994-07-06 14:38:19 by jwe] diff --git a/src/variables.cc b/src/variables.cc --- a/src/variables.cc +++ b/src/variables.cc @@ -79,8 +79,8 @@ if (sr != (symbol_record *) NULL) { - tree *ans = sr->def (); - if (ans != NULL_TREE) + tree_fvc *ans = sr->def (); + if (ans != (tree_fvc *) NULL) { char *ff = ans->fcn_file_name (); if (! (ff == (char *) NULL @@ -277,9 +277,9 @@ char *retval = (char *) NULL; - tree *defn = sr->def (); + tree_fvc *defn = sr->def (); - if (defn != NULL_TREE) + if (defn != (tree_fvc *) NULL) { tree_constant val = defn->eval (0); @@ -309,9 +309,9 @@ assert (sr != (symbol_record *) NULL); - tree *defn = sr->def (); + tree_fvc *defn = sr->def (); - if (defn != NULL_TREE) + if (defn != (tree_fvc *) NULL) { tree_constant val = defn->eval (0); @@ -631,10 +631,10 @@ /* * Is this tree_constant a valid function? */ -tree * +tree_fvc * is_valid_function (tree_constant& arg, char *warn_for, int warn = 0) { - tree *ans = NULL_TREE; + tree_fvc *ans = (tree_fvc *) NULL; if (! arg.is_string_type ()) { @@ -659,12 +659,12 @@ } ans = sr->def (); - if (ans == NULL_TREE || ! sr->is_function ()) + if (ans == (tree_fvc *) NULL || ! sr->is_function ()) { if (warn) error ("%s: the symbol `%s' is not valid as a function", warn_for, fcn_name); - ans = NULL_TREE; + ans = (tree_fvc *) NULL; } return ans; @@ -674,7 +674,7 @@ * Does this function take the right number of arguments? */ int -takes_correct_nargs (tree *fcn, int expected_nargin, char *warn_for, +takes_correct_nargs (tree_fvc *fcn, int expected_nargin, char *warn_for, int warn = 0) { int nargs = fcn->max_expected_args () - 1; diff --git a/src/variables.h b/src/variables.h --- a/src/variables.h +++ b/src/variables.h @@ -28,6 +28,7 @@ class symbol_record; class symbol_table; class tree; +class tree_fvc; class tree_constant; struct builtin_mapper_functions; @@ -87,8 +88,8 @@ extern int valid_identifier (char *); extern int identifier_exists (char *); extern int is_builtin_variable (const char *name); -extern tree *is_valid_function (tree_constant&, char *, int warn = 0); -extern int takes_correct_nargs (tree *, int, char *, int warn = 0); +extern tree_fvc *is_valid_function (tree_constant&, char *, int warn = 0); +extern int takes_correct_nargs (tree_fvc *, int, char *, int warn = 0); extern char **make_name_list (void); // Symbol table for symbols at the top level.